mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-05 16:41:52 +00:00
WindowServer: Rename the two painting phases.
Work now happens in terms of two messages: - WM_ClientWantsToPaint - WM_ClientFinishedPaint This feels fairly obvious compared to the old Paint/Invalidate.
This commit is contained in:
parent
244d5bcce1
commit
9fa8d4e22f
Notes:
sideshowbarker
2024-07-19 15:56:31 +09:00
Author: https://github.com/awesomekling
Commit: 9fa8d4e22f
6 changed files with 39 additions and 39 deletions
|
@ -145,7 +145,7 @@ int Process::gui$invalidate_window(int window_id, const GUI_Rect* a_rect)
|
|||
Rect rect;
|
||||
if (a_rect)
|
||||
rect = *a_rect;
|
||||
WSMessageLoop::the().post_message(&window, make<WSPaintEvent>(rect));
|
||||
WSMessageLoop::the().post_message(&window, make<WSClientWantsToPaintMessage>(rect));
|
||||
WSMessageLoop::the().server_process().request_wakeup();
|
||||
return 0;
|
||||
}
|
||||
|
@ -169,7 +169,7 @@ int Process::gui$notify_paint_finished(int window_id, const GUI_Rect* a_rect)
|
|||
Rect rect;
|
||||
if (a_rect)
|
||||
rect = *a_rect;
|
||||
WSMessageLoop::the().post_message(&window, make<WSWindowInvalidationEvent>(rect));
|
||||
WSMessageLoop::the().post_message(&window, make<WSClientFinishedPaintMessage>(rect));
|
||||
WSMessageLoop::the().server_process().request_wakeup();
|
||||
return 0;
|
||||
}
|
||||
|
@ -207,7 +207,7 @@ int Process::gui$set_window_title(int window_id, const char* title, size_t size)
|
|||
return -EBADWINDOW;
|
||||
auto& window = *(*it).value;
|
||||
String new_title(title, size);
|
||||
WSMessageLoop::the().post_message(&window, make<WSSetWindowTitle>(move(new_title)));
|
||||
WSMessageLoop::the().post_message(&window, make<WSSetWindowTitleMessage>(move(new_title)));
|
||||
WSMessageLoop::the().server_process().request_wakeup();
|
||||
return 0;
|
||||
}
|
||||
|
@ -240,7 +240,7 @@ int Process::gui$set_window_rect(int window_id, const GUI_Rect* rect)
|
|||
return -EBADWINDOW;
|
||||
auto& window = *(*it).value;
|
||||
Rect new_rect = *rect;
|
||||
WSMessageLoop::the().post_message(&window, make<WSSetWindowRect>(new_rect));
|
||||
WSMessageLoop::the().post_message(&window, make<WSSetWindowRectMessage>(new_rect));
|
||||
WSMessageLoop::the().server_process().request_wakeup();
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue