From f2df495970258d035a1dad978beda472b4750d26 Mon Sep 17 00:00:00 2001 From: Caoimhe Date: Sun, 19 Mar 2023 19:56:11 +0000 Subject: [PATCH] Presenter: Change "Full Screen" action to "Toggle Full Screen" When using its keybind, it didn't really feel right to press Shift+F5 to enter fullscreen, but not to exit it! --- Userland/Applications/Presenter/PresenterWidget.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Userland/Applications/Presenter/PresenterWidget.cpp b/Userland/Applications/Presenter/PresenterWidget.cpp index f81d89c998..0c23b57ff0 100644 --- a/Userland/Applications/Presenter/PresenterWidget.cpp +++ b/Userland/Applications/Presenter/PresenterWidget.cpp @@ -83,8 +83,9 @@ ErrorOr PresenterWidget::initialize_menubar() update_slides_actions(); } }); - m_full_screen_action = GUI::Action::create("&Full Screen", { KeyModifier::Mod_Shift, KeyCode::Key_F5 }, { KeyCode::Key_F11 }, TRY(Gfx::Bitmap::load_from_file("/res/icons/16x16/fullscreen.png"sv)), [this](auto&) { - this->window()->set_fullscreen(true); + m_full_screen_action = GUI::Action::create("Toggle &Full Screen", { KeyModifier::Mod_Shift, KeyCode::Key_F5 }, { KeyCode::Key_F11 }, TRY(Gfx::Bitmap::load_from_file("/res/icons/16x16/fullscreen.png"sv)), [this](auto&) { + auto* window = this->window(); + window->set_fullscreen(!window->is_fullscreen()); }); m_present_from_first_slide_action = GUI::Action::create("Present From First &Slide", { KeyCode::Key_F5 }, TRY(Gfx::Bitmap::load_from_file("/res/icons/16x16/play.png"sv)), [this](auto&) { if (m_current_presentation) {