2024-08-10 17:57:15 +03:00
|
|
|
#include "menu.hpp"
|
|
|
|
|
|
|
|
using namespace app::browser::header;
|
|
|
|
|
|
|
|
Menu::Menu()
|
|
|
|
{
|
2024-08-10 18:47:26 +03:00
|
|
|
// Init defaults
|
2024-08-10 17:57:15 +03:00
|
|
|
set_tooltip_text(
|
|
|
|
TOOLTIP
|
|
|
|
);
|
|
|
|
|
|
|
|
// Build tab submenu
|
|
|
|
auto tab = Gio::Menu::create();
|
|
|
|
|
|
|
|
tab->append(
|
2024-08-11 22:04:34 +03:00
|
|
|
_("New tab.."),
|
|
|
|
"win.tab"
|
2024-08-10 17:57:15 +03:00
|
|
|
);
|
|
|
|
|
|
|
|
// Build tool submenu
|
|
|
|
auto tool = Gio::Menu::create();
|
|
|
|
|
|
|
|
tool->append(
|
|
|
|
_("Debug"),
|
2024-08-11 09:55:10 +03:00
|
|
|
"win.debug"
|
2024-08-10 17:57:15 +03:00
|
|
|
);
|
|
|
|
|
|
|
|
// Build main menu
|
|
|
|
auto main = Gio::Menu::create();
|
|
|
|
|
|
|
|
main->append_submenu(
|
|
|
|
_("Tab"),
|
|
|
|
tab
|
|
|
|
);
|
|
|
|
|
|
|
|
main->append_submenu(
|
|
|
|
_("Tool"),
|
|
|
|
tool
|
|
|
|
);
|
|
|
|
|
|
|
|
main->append(
|
|
|
|
_("Quit"),
|
2024-08-11 09:55:10 +03:00
|
|
|
"app.quit"
|
2024-08-10 17:57:15 +03:00
|
|
|
);
|
|
|
|
|
|
|
|
set_menu_model(
|
|
|
|
main
|
|
|
|
);
|
|
|
|
}
|