#include <host_window.h>
Classes | |
| struct | HostWindowInitializationParams |
| struct | SavedWindowInfo |
Public Member Functions | |
| virtual | ~HostWindow () |
| HWND | GetWindowHandle () const |
| HWND | GetFlutterViewWindowHandle () const |
| void | SetContentSize (const WindowSizeRequest &size) |
| void | SetConstraints (const WindowConstraints &constraints) |
| virtual void | SetFullscreen (bool fullscreen, std::optional< FlutterEngineDisplayId > display_id) |
| virtual bool | GetFullscreen () const |
| HostWindow * | GetOwnerWindow () const |
| void | UpdateModalStateLayer () |
Static Public Member Functions | |
| static std::unique_ptr< HostWindow > | CreateRegularWindow (WindowManager *window_manager, FlutterWindowsEngine *engine, const WindowSizeRequest &preferred_size, const WindowConstraints &preferred_constraints, LPCWSTR title) |
| static std::unique_ptr< HostWindow > | CreateDialogWindow (WindowManager *window_manager, FlutterWindowsEngine *engine, const WindowSizeRequest &preferred_size, const WindowConstraints &preferred_constraints, LPCWSTR title, HWND parent) |
| static std::unique_ptr< HostWindow > | CreateTooltipWindow (WindowManager *window_manager, FlutterWindowsEngine *engine, const WindowConstraints &preferred_constraints, bool is_sized_to_content, GetWindowPositionCallback get_position_callback, HWND parent) |
| static HostWindow * | GetThisFromHandle (HWND hwnd) |
| static ActualWindowSize | GetWindowContentSize (HWND hwnd) |
Protected Member Functions | |
| void | InitializeFlutterView (HostWindowInitializationParams const ¶ms) |
| HostWindow (WindowManager *window_manager, FlutterWindowsEngine *engine) | |
| virtual LRESULT | HandleMessage (HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam) |
| void | EnableRecursively (bool enable) |
| HostWindow * | FindFirstEnabledDescendant () const |
| std::vector< HostWindow * > | GetOwnedWindows () const |
| void | DisableRecursively () |
| FML_DISALLOW_COPY_AND_ASSIGN (HostWindow) | |
Static Protected Member Functions | |
| static std::optional< Size > | GetWindowSizeForClientSize (WindowsProcTable const &win32, Size const &client_size, std::optional< Size > smallest, std::optional< Size > biggest, DWORD window_style, DWORD extended_window_style, std::optional< HWND > const &owner_hwnd) |
| static void | FocusRootViewOf (HostWindow *window) |
| static LRESULT | WndProc (HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam) |
Protected Attributes | |
| friend | WindowManager |
| WindowManager *const | window_manager_ = nullptr |
| FlutterWindowsEngine * | engine_ |
| std::unique_ptr< FlutterWindowsViewController > | view_controller_ |
| WindowArchetype | archetype_ = WindowArchetype::kRegular |
| HWND | window_handle_ |
| BoxConstraints | box_constraints_ |
| bool | is_being_destroyed_ = false |
| bool | is_fullscreen_ = false |
| SavedWindowInfo | saved_window_info_ |
| Microsoft::WRL::ComPtr< ITaskbarList2 > | task_bar_list_ |
Definition at line 29 of file host_window.h.
|
virtual |
Definition at line 324 of file host_window.cc.
References ERROR_SUCCESS, SetLastError(), and view_controller_.
|
protected |
Definition at line 241 of file host_window.cc.
|
static |
Definition at line 216 of file host_window.cc.
References engine.
Referenced by flutter::WindowManager::CreateDialogWindow().
|
static |
Definition at line 205 of file host_window.cc.
References engine.
Referenced by flutter::WindowManager::CreateRegularWindow().
|
static |
Definition at line 229 of file host_window.cc.
References engine.
Referenced by flutter::WindowManager::CreateTooltipWindow().
|
protected |
Definition at line 836 of file host_window.cc.
References GetOwnedWindows(), and window_handle_.
|
protected |
Definition at line 784 of file host_window.cc.
References GetOwnedWindows(), and window_handle_.
|
protected |
Definition at line 792 of file host_window.cc.
References FindFirstEnabledDescendant(), GetOwnedWindows(), and window_handle_.
Referenced by FindFirstEnabledDescendant(), and flutter::HostWindowDialog::HandleMessage().
|
protected |
|
staticprotected |
Definition at line 358 of file host_window.cc.
References window.
Referenced by HandleMessage(), and flutter::HostWindowDialog::HandleMessage().
| HWND flutter::HostWindow::GetFlutterViewWindowHandle | ( | ) | const |
Definition at line 354 of file host_window.cc.
References GetWindowHandle(), and view_controller_.
|
virtual |
Reimplemented in flutter::HostWindowDialog.
Definition at line 720 of file host_window.cc.
References is_fullscreen_.
Referenced by SetConstraints(), SetContentSize(), and SetFullscreen().
|
protected |
Definition at line 806 of file host_window.cc.
References flutter::data, GetThisFromHandle(), TRUE, window, and window_handle_.
Referenced by DisableRecursively(), EnableRecursively(), FindFirstEnabledDescendant(), and UpdateModalStateLayer().
| HostWindow * flutter::HostWindow::GetOwnerWindow | ( | ) | const |
Definition at line 829 of file host_window.cc.
References GetThisFromHandle(), and GetWindowHandle().
Referenced by flutter::HostWindowDialog::HandleMessage(), and flutter::testing::TEST_F().
|
static |
Definition at line 335 of file host_window.cc.
References FML_LOG.
Referenced by GetOwnedWindows(), GetOwnerWindow(), flutter::WindowManager::HandleMessage(), InternalFlutterWindows_WindowManager_GetFullscreen(), InternalFlutterWindows_WindowManager_OnDestroyWindow(), InternalFlutterWindows_WindowManager_SetFullscreen(), InternalFlutterWindows_WindowManager_SetWindowConstraints(), InternalFlutterWindows_WindowManager_SetWindowSize(), InternalFlutterWindows_WindowManager_UpdateTooltipPosition(), flutter::testing::TEST_F(), and WndProc().
|
static |
Definition at line 724 of file host_window.cc.
References FlutterDesktopGetDpiForHWND(), height, and width.
Referenced by InternalFlutterWindows_WindowManager_GetWindowContentSize(), SetConstraints(), and SetFullscreen().
| HWND flutter::HostWindow::GetWindowHandle | ( | ) | const |
Definition at line 350 of file host_window.cc.
References window_handle_.
Referenced by GetFlutterViewWindowHandle(), GetOwnerWindow(), and flutter::testing::TEST_F().
|
staticprotected |
Definition at line 737 of file host_window.cc.
References flutter::WindowsProcTable::AdjustWindowRectExForDpi(), FML_LOG, flutter::GetDpiForHWND(), height, flutter::Size::height(), width, and flutter::Size::width().
Referenced by SetConstraints(), and SetContentSize().
|
protectedvirtual |
Reimplemented in flutter::HostWindowDialog, and flutter::HostWindowTooltip.
Definition at line 382 of file host_window.cc.
References flutter::BoxConstraints::biggest(), box_constraints_, engine_, FocusRootViewOf(), flutter::GetDpiForHWND(), height, flutter::Size::height(), is_being_destroyed_, message, flutter::WindowProcDelegateManager::OnTopLevelWindowProc(), PostMessage, SendMessage, flutter::BoxConstraints::smallest(), TRUE, view_controller_, width, flutter::Size::width(), window_handle_, and flutter::FlutterWindowsEngine::window_proc_delegate_manager().
Referenced by flutter::HostWindowDialog::HandleMessage(), and flutter::HostWindowTooltip::HandleMessage().
|
protected |
Definition at line 245 of file host_window.cc.
References flutter::FlutterWindowsEngine::CreateView(), flutter::FlutterWindowsEngine::display_manager(), engine_, FML_CHECK, LoadIcon, params, flutter::FlutterWindowsEngine::running(), flutter::FlutterWindowsEngine::UpdateAccessibilityFeatures(), view, view_controller_, window_handle_, flutter::FlutterWindowsEngine::windows_proc_table(), and WndProc().
Referenced by flutter::HostWindowDialog::HostWindowDialog(), flutter::HostWindowRegular::HostWindowRegular(), and flutter::HostWindowTooltip::HostWindowTooltip().
| void flutter::HostWindow::SetConstraints | ( | const WindowConstraints & | constraints | ) |
Definition at line 533 of file host_window.cc.
References flutter::BoxConstraints::biggest(), box_constraints_, flutter::HostWindow::SavedWindowInfo::client_size, engine_, flutter::HostWindow::SavedWindowInfo::ex_style, GetFullscreen(), GetWindowContentSize(), GetWindowSizeForClientSize(), flutter::ActualWindowSize::height, flutter::HostWindow::SavedWindowInfo::rect, saved_window_info_, flutter::BoxConstraints::smallest(), flutter::HostWindow::SavedWindowInfo::style, flutter::ActualWindowSize::width, window_handle_, and flutter::FlutterWindowsEngine::windows_proc_table().
| void flutter::HostWindow::SetContentSize | ( | const WindowSizeRequest & | size | ) |
Definition at line 491 of file host_window.cc.
References flutter::BoxConstraints::biggest(), box_constraints_, flutter::HostWindow::SavedWindowInfo::client_size, engine_, flutter::HostWindow::SavedWindowInfo::ex_style, GetFullscreen(), GetWindowSizeForClientSize(), flutter::HostWindow::SavedWindowInfo::rect, saved_window_info_, flutter::size, flutter::BoxConstraints::smallest(), flutter::HostWindow::SavedWindowInfo::style, flutter::ActualWindowSize::width, window_handle_, and flutter::FlutterWindowsEngine::windows_proc_table().
|
virtual |
Reimplemented in flutter::HostWindowDialog.
Definition at line 574 of file host_window.cc.
References flutter::AreRectsEqual(), flutter::HostWindow::SavedWindowInfo::client_size, flutter::FlutterWindowsEngine::display_manager(), flutter::HostWindow::SavedWindowInfo::dpi, engine_, flutter::HostWindow::SavedWindowInfo::ex_style, FAILED, FML_LOG, flutter::GetDpiForHWND(), GetFullscreen(), GetWindowContentSize(), height, is_fullscreen_, flutter::HostWindow::SavedWindowInfo::monitor, flutter::HostWindow::SavedWindowInfo::monitor_info, flutter::HostWindow::SavedWindowInfo::rect, flutter::RectHeight(), flutter::RectWidth(), saved_window_info_, flutter::HostWindow::SavedWindowInfo::style, SUCCEEDED, task_bar_list_, width, and window_handle_.
| void flutter::HostWindow::UpdateModalStateLayer | ( | ) |
Definition at line 845 of file host_window.cc.
References GetOwnedWindows(), and window_handle_.
|
staticprotected |
Definition at line 365 of file host_window.cc.
References flutter::WindowsProcTable::EnableNonClientDpiScaling(), GetThisFromHandle(), message, and window.
Referenced by InitializeFlutterView().
|
protected |
Definition at line 220 of file host_window.h.
|
protected |
Definition at line 226 of file host_window.h.
Referenced by HandleMessage(), SetConstraints(), and SetContentSize().
|
protected |
Definition at line 212 of file host_window.h.
Referenced by HandleMessage(), InitializeFlutterView(), SetConstraints(), SetContentSize(), and SetFullscreen().
|
protected |
Definition at line 229 of file host_window.h.
Referenced by HandleMessage(), and flutter::HostWindowDialog::HandleMessage().
|
protected |
Definition at line 232 of file host_window.h.
Referenced by GetFullscreen(), and SetFullscreen().
|
protected |
Definition at line 235 of file host_window.h.
Referenced by SetConstraints(), SetContentSize(), and SetFullscreen().
|
protected |
Definition at line 238 of file host_window.h.
Referenced by SetFullscreen().
|
protected |
Definition at line 217 of file host_window.h.
Referenced by GetFlutterViewWindowHandle(), HandleMessage(), flutter::WindowManager::HandleMessage(), InitializeFlutterView(), flutter::HostWindowTooltip::UpdatePosition(), and ~HostWindow().
|
protected |
Definition at line 223 of file host_window.h.
Referenced by DisableRecursively(), EnableRecursively(), FindFirstEnabledDescendant(), GetOwnedWindows(), GetWindowHandle(), HandleMessage(), flutter::HostWindowDialog::HostWindowDialog(), flutter::HostWindowTooltip::HostWindowTooltip(), InitializeFlutterView(), SetConstraints(), SetContentSize(), SetFullscreen(), UpdateModalStateLayer(), and flutter::HostWindowTooltip::UpdatePosition().
|
protected |
Definition at line 209 of file host_window.h.
|
protected |
Definition at line 139 of file host_window.h.