Merge pull request #38727 from Riteo/tiling-wm-issues-tests
Fixes for windows in X11 tiling WMs
This commit is contained in:
commit
3842e8c465
9 changed files with 36 additions and 12 deletions
|
|
@ -495,13 +495,17 @@ DisplayServer::WindowID DisplayServerWindows::create_sub_window(WindowMode p_mod
|
|||
|
||||
_update_window_style(window_id);
|
||||
|
||||
ShowWindow(wd.hWnd, (p_flags & WINDOW_FLAG_NO_FOCUS_BIT) ? SW_SHOWNOACTIVATE : SW_SHOW); // Show The Window
|
||||
if (!(p_flags & WINDOW_FLAG_NO_FOCUS_BIT)) {
|
||||
return window_id;
|
||||
}
|
||||
|
||||
void DisplayServerWindows::show_window(WindowID p_id) {
|
||||
WindowData &wd = windows[p_id];
|
||||
|
||||
ShowWindow(wd.hWnd, wd.no_focus ? SW_SHOWNOACTIVATE : SW_SHOW); // Show The Window
|
||||
if (!wd.no_focus) {
|
||||
SetForegroundWindow(wd.hWnd); // Slightly Higher Priority
|
||||
SetFocus(wd.hWnd); // Sets Keyboard Focus To
|
||||
}
|
||||
|
||||
return window_id;
|
||||
}
|
||||
|
||||
void DisplayServerWindows::delete_sub_window(WindowID p_window) {
|
||||
|
|
@ -3121,9 +3125,7 @@ DisplayServerWindows::DisplayServerWindows(const String &p_rendering_driver, Win
|
|||
}
|
||||
}
|
||||
|
||||
ShowWindow(windows[MAIN_WINDOW_ID].hWnd, SW_SHOW); // Show The Window
|
||||
SetForegroundWindow(windows[MAIN_WINDOW_ID].hWnd); // Slightly Higher Priority
|
||||
SetFocus(windows[MAIN_WINDOW_ID].hWnd); // Sets Keyboard Focus To
|
||||
show_window(MAIN_WINDOW_ID);
|
||||
|
||||
#if defined(VULKAN_ENABLED)
|
||||
|
||||
|
|
|
|||
|
|
@ -460,6 +460,7 @@ public:
|
|||
virtual Vector<DisplayServer::WindowID> get_window_list() const;
|
||||
|
||||
virtual WindowID create_sub_window(WindowMode p_mode, uint32_t p_flags, const Rect2i &p_rect = Rect2i());
|
||||
virtual void show_window(WindowID p_window);
|
||||
virtual void delete_sub_window(WindowID p_window);
|
||||
|
||||
virtual WindowID get_window_at_screen_position(const Point2i &p_position) const;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue