Skip to content

Commit 7dba28f

Browse files
hughdavenportADKaster
authored andcommitted
MasterWord: Add fullscreen option
Required allowing resizing. Perhaps an additional setting to allow fullscreen, but not resizing? Anyhow, the game still plays well if you can resize and works as expected.
1 parent 5f56c94 commit 7dba28f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Userland/Games/MasterWord/main.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
4444
window->set_icon(app_icon.bitmap_for_size(16));
4545
window->set_double_buffering_enabled(false);
4646
window->set_title("MasterWord");
47-
window->set_resizable(false);
47+
window->set_resizable(true);
4848
window->set_auto_shrink(true);
4949

5050
auto main_widget = TRY(MasterWord::MainWidget::try_create());
@@ -127,6 +127,11 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
127127
theme_actions.add_action(system_theme_action);
128128
theme_actions.add_action(wordle_theme_action);
129129

130+
auto view_menu = window->add_menu("&View"_string);
131+
view_menu->add_action(GUI::CommonActions::make_fullscreen_action([&](auto&) {
132+
window->set_fullscreen(!window->is_fullscreen());
133+
}));
134+
130135
auto help_menu = window->add_menu("&Help"_string);
131136
help_menu->add_action(GUI::CommonActions::make_command_palette_action(window));
132137
help_menu->add_action(GUI::CommonActions::make_help_action([](auto&) {

0 commit comments

Comments
 (0)