mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 22:17:44 +00:00
LibGUI+WindowServer: Don't use a WM IPC to initiate own window resize
The WM_* IPC messages are intended for "outsider" window management, not for a client's own windows. Make a separate StartWindowResize message for this. This was the only reason that every IPC client had to know its server side client ID.
This commit is contained in:
parent
c41d340983
commit
a5bbe3280d
6 changed files with 20 additions and 4 deletions
|
@ -106,7 +106,7 @@ void ResizeCorner::paint_event(PaintEvent& event)
|
|||
void ResizeCorner::mousedown_event(MouseEvent& event)
|
||||
{
|
||||
if (event.button() == MouseButton::Left)
|
||||
window()->start_wm_resize();
|
||||
window()->start_interactive_resize();
|
||||
Widget::mousedown_event(event);
|
||||
}
|
||||
|
||||
|
|
|
@ -774,9 +774,9 @@ void Window::apply_icon()
|
|||
WindowServerConnection::the().send_sync<Messages::WindowServer::SetWindowIconBitmap>(m_window_id, m_icon->to_shareable_bitmap());
|
||||
}
|
||||
|
||||
void Window::start_wm_resize()
|
||||
void Window::start_interactive_resize()
|
||||
{
|
||||
WindowServerConnection::the().post_message(Messages::WindowServer::WM_StartWindowResize(WindowServerConnection::the().my_client_id(), m_window_id));
|
||||
WindowServerConnection::the().post_message(Messages::WindowServer::StartWindowResize(m_window_id));
|
||||
}
|
||||
|
||||
Vector<Widget*> Window::focusable_widgets(FocusSource source) const
|
||||
|
|
|
@ -126,7 +126,7 @@ public:
|
|||
virtual void close();
|
||||
void move_to_front();
|
||||
|
||||
void start_wm_resize();
|
||||
void start_interactive_resize();
|
||||
|
||||
Widget* main_widget() { return m_main_widget; }
|
||||
const Widget* main_widget() const { return m_main_widget; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue