mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-22 04:25:13 +00:00
Chess: Add Help menuitem
This commit is contained in:
parent
d5d54da0ea
commit
1ec0f54de1
Notes:
sideshowbarker
2024-07-19 03:29:57 +09:00
Author: https://github.com/selectiveduplicate Commit: https://github.com/SerenityOS/serenity/commit/1ec0f54de1d Pull-request: https://github.com/SerenityOS/serenity/pull/3188
1 changed files with 7 additions and 1 deletions
|
@ -27,6 +27,7 @@
|
|||
#include "ChessWidget.h"
|
||||
#include <LibCore/ConfigFile.h>
|
||||
#include <LibCore/DirIterator.h>
|
||||
#include <LibGUI/AboutDialog.h>
|
||||
#include <LibGUI/ActionGroup.h>
|
||||
#include <LibGUI/Application.h>
|
||||
#include <LibGUI/Menu.h>
|
||||
|
@ -103,7 +104,12 @@ int main(int argc, char** argv)
|
|||
action->set_checked(true);
|
||||
board_theme_menu.add_action(*action);
|
||||
}
|
||||
|
||||
|
||||
auto& help_menu = menubar->add_menu("Help");
|
||||
help_menu.add_action(GUI::Action::create("About", [&](auto&) {
|
||||
GUI::AboutDialog::show("Chess", Gfx::Bitmap::load_from_file("/res/icons/32x32/app-chess.png"), window);
|
||||
}));
|
||||
|
||||
app->set_menubar(move(menubar));
|
||||
|
||||
window->show();
|
||||
|
|
Loading…
Add table
Reference in a new issue