| Flutter Windows Embedder |

host_window_dialog.h
Go to the documentation of this file.
1 // Copyright 2013 The Flutter Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef FLUTTER_SHELL_PLATFORM_WINDOWS_HOST_WINDOW_DIALOG_H_
6 #define FLUTTER_SHELL_PLATFORM_WINDOWS_HOST_WINDOW_DIALOG_H_
7
8 #include "host_window.h"
9
10 namespace flutter {
11 class HostWindowDialog : public HostWindow {
12 public:
13 // Creates a dialog window.
14 //
15 // If |owner_window| is not null, the dialog will be modal to the owner.
16 // This also affects the dialog window's styling.
17 HostWindowDialog(WindowManager* window_manager,
18 FlutterWindowsEngine* engine,
19 const WindowSizeRequest& preferred_size,
20 const BoxConstraints& constraints,
21 LPCWSTR title,
22 std::optional<HWND> const& owner_window);
23
24 void SetFullscreen(bool fullscreen,
25 std::optional<FlutterEngineDisplayId> display_id) override;
26 bool GetFullscreen() const override;
27
28 protected:
29 LRESULT HandleMessage(HWND hwnd,
30 UINT message,
31 WPARAM wparam,
32 LPARAM lparam) override;
33
34 private:
35 // Enforces modal behavior. This favors enabling most recently created
36 // modal window higest up in the window hierarchy.
37 void UpdateModalState();
38
39 static Rect GetInitialRect(FlutterWindowsEngine* engine,
40 const WindowSizeRequest& preferred_size,
41 const BoxConstraints& constraints,
42 std::optional<HWND> const& owner_window);
43 };
44 } // namespace flutter
45
46 #endif // FLUTTER_SHELL_PLATFORM_WINDOWS_HOST_WINDOW_DIALOG_H_
flutter::FlutterWindowsEngine
Definition: flutter_windows_engine.h:92
flutter::HostWindowDialog
Definition: host_window_dialog.h:11
flutter::HostWindowDialog::HostWindowDialog
HostWindowDialog(WindowManager *window_manager, FlutterWindowsEngine *engine, const WindowSizeRequest &preferred_size, const BoxConstraints &constraints, LPCWSTR title, std::optional< HWND > const &owner_window)
Definition: host_window_dialog.cc:35
flutter::HostWindowDialog::GetFullscreen
bool GetFullscreen() const override
Definition: host_window_dialog.cc:139
flutter::HostWindowDialog::SetFullscreen
void SetFullscreen(bool fullscreen, std::optional< FlutterEngineDisplayId > display_id) override
Definition: host_window_dialog.cc:135
flutter::HostWindowDialog::HandleMessage
LRESULT HandleMessage(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam) override
Definition: host_window_dialog.cc:92
flutter::HostWindow
Definition: host_window.h:29
flutter::WindowManager
Definition: window_manager.h:109
host_window.h
message
Win32Message message
Definition: keyboard_unittests.cc:137
flutter
Definition: accessibility_bridge_windows.cc:11
flutter::WindowSizeRequest
Definition: window_manager.h:26