mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 05:48:12 +00:00
LibGUI+WindowServer: Create and broadcast an event when a window moves
LibWeb's Window object will need to know the OS-level position and size of the GUI::Window for e.g. screenX, screenY, outerWidth, outerHeight. It will also need to know about changes to that data.
This commit is contained in:
parent
6b41da0b9e
commit
f7e747b68e
7 changed files with 47 additions and 0 deletions
|
@ -742,6 +742,7 @@ bool WindowManager::process_ongoing_window_move(MouseEvent& event)
|
|||
if (!m_move_window->is_tiled())
|
||||
m_move_window->set_floating_rect(m_move_window->rect());
|
||||
|
||||
Core::EventLoop::current().post_event(*m_move_window, make<MoveEvent>(m_move_window->rect()));
|
||||
m_move_window->invalidate(true, true);
|
||||
if (m_move_window->is_resizable()) {
|
||||
process_event_for_doubleclick(*m_move_window, event);
|
||||
|
@ -816,6 +817,7 @@ bool WindowManager::process_ongoing_window_move(MouseEvent& event)
|
|||
m_geometry_overlay->window_rect_changed();
|
||||
}
|
||||
}
|
||||
Core::EventLoop::current().post_event(*m_move_window, make<MoveEvent>(m_move_window->rect()));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue