1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:38:10 +00:00

WindowServer: Let the window switcher render itself as a WSWindow.

Much better than drawing directly into the back buffer.
This commit is contained in:
Andreas Kling 2019-03-06 10:03:10 +01:00
parent f3ff402cf3
commit b85fe0bd07
8 changed files with 89 additions and 59 deletions

View file

@ -69,7 +69,7 @@ WSWindow& WSMenu::ensure_menu_window()
next_item_location.move_by(0, height);
}
auto window = make<WSWindow>(*this);
auto window = make<WSWindow>(*this, WSWindowType::Menu);
window->set_opacity(0.95f);
window->set_rect(0, 0, width(), height());
m_menu_window = move(window);
@ -107,7 +107,7 @@ void WSMenu::draw()
}
}
void WSMenu::on_window_message(WSMessage& message)
void WSMenu::on_message(WSMessage& message)
{
ASSERT(menu_window());
if (message.type() == WSMessage::MouseMove) {