@ -5,15 +5,15 @@ using namespace app::browser::header;
@@ -5,15 +5,15 @@ using namespace app::browser::header;
Menu : : Menu (
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__DEBUG ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__QUIT ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__CLEAN ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__RESTORE ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__SAVE ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_APPEND ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_CLOSE_ACTIV E ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_CLOSE_ALL ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_PAGE_NAVIGATION_HISTORY_BACK ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_PAGE_NAVIGATION_HISTORY_FORWARD ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__MAIN_ TAB_PAGE_NAVIGATION_RELOAD
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__SESSION_ CLEAN ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__SESSION_ RESTORE ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__SESSION_S AVE ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_APPEND ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_CLOSE ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_CLOSE_ALL ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_PAGE_NAVIGATION_HISTORY_BACK ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_PAGE_NAVIGATION_HISTORY_FORWARD ,
const Glib : : RefPtr < Gio : : SimpleAction > & ACTION__TAB_PAGE_NAVIGATION_RELOAD
) {
// Init widget
set_tooltip_text (
@ -21,144 +21,144 @@ Menu::Menu(
@@ -21,144 +21,144 @@ Menu::Menu(
) ;
// Init components @TODO make builder
const auto MENU__MAIN = Gio : : Menu : : create ( ) ;
const auto MENU = Gio : : Menu : : create ( ) ;
const auto MENU__MAIN_ SESSION = Gio : : Menu : : create ( ) ;
const auto MENU__SESSION = Gio : : Menu : : create ( ) ;
MENU__MAIN_ SESSION - > append (
MENU__SESSION - > append (
_ ( " Clean " ) ,
get_action_detailed_name (
ACTION__CLEAN
ACTION__SESSION_ CLEAN
)
) ;
MENU__MAIN_ SESSION - > append (
MENU__SESSION - > append (
_ ( " Restore " ) ,
get_action_detailed_name (
ACTION__RESTORE
ACTION__SESSION_ RESTORE
)
) ;
MENU__MAIN_ SESSION - > append (
MENU__SESSION - > append (
_ ( " Save " ) ,
get_action_detailed_name (
ACTION__SAVE
ACTION__SESSION_S AVE
)
) ;
MENU__MAIN - > append_submenu (
MENU - > append_submenu (
_ ( " Session " ) ,
MENU__MAIN_ SESSION
MENU__SESSION
) ;
const auto MENU__MAIN_ TAB = Gio : : Menu : : create ( ) ;
const auto MENU__TAB = Gio : : Menu : : create ( ) ;
MENU__MAIN_ TAB - > append (
MENU__TAB - > append (
_ ( " New.. " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_APPEND
ACTION__TAB_APPEND
)
) ;
const auto MENU__MAIN_ TAB_PAGE = Gio : : Menu : : create ( ) ;
const auto MENU__TAB_PAGE = Gio : : Menu : : create ( ) ;
const auto MENU__MAIN_ TAB_PAGE_NAVIGATION = Gio : : Menu : : create ( ) ;
const auto MENU__TAB_PAGE_NAVIGATION = Gio : : Menu : : create ( ) ;
const auto MENU__MAIN_ TAB_PAGE_NAVIGATION_HISTORY = Gio : : Menu : : create ( ) ;
const auto MENU__TAB_PAGE_NAVIGATION_HISTORY = Gio : : Menu : : create ( ) ;
MENU__MAIN_ TAB_PAGE_NAVIGATION_HISTORY - > append (
MENU__TAB_PAGE_NAVIGATION_HISTORY - > append (
_ ( " Back " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_PAGE_NAVIGATION_HISTORY_BACK
ACTION__TAB_PAGE_NAVIGATION_HISTORY_BACK
)
) ;
MENU__MAIN_ TAB_PAGE_NAVIGATION_HISTORY - > append (
MENU__TAB_PAGE_NAVIGATION_HISTORY - > append (
_ ( " Forward " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_PAGE_NAVIGATION_HISTORY_FORWARD
ACTION__TAB_PAGE_NAVIGATION_HISTORY_FORWARD
)
) ;
MENU__MAIN_ TAB_PAGE_NAVIGATION - > append_submenu (
MENU__TAB_PAGE_NAVIGATION - > append_submenu (
_ ( " History " ) ,
MENU__MAIN_ TAB_PAGE_NAVIGATION_HISTORY
MENU__TAB_PAGE_NAVIGATION_HISTORY
) ;
MENU__MAIN_ TAB_PAGE_NAVIGATION - > append (
MENU__TAB_PAGE_NAVIGATION - > append (
_ ( " Reload " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_PAGE_NAVIGATION_RELOAD
ACTION__TAB_PAGE_NAVIGATION_RELOAD
)
) ;
MENU__MAIN_ TAB_PAGE - > append_submenu (
MENU__TAB_PAGE - > append_submenu (
_ ( " Navigation " ) ,
MENU__MAIN_ TAB_PAGE_NAVIGATION
MENU__TAB_PAGE_NAVIGATION
) ;
MENU__MAIN_ TAB - > append_submenu (
MENU__TAB - > append_submenu (
_ ( " Page " ) ,
MENU__MAIN_ TAB_PAGE
MENU__TAB_PAGE
) ;
const auto MENU__MAIN_ TAB_CLOSE = Gio : : Menu : : create ( ) ;
const auto MENU__TAB_CLOSE = Gio : : Menu : : create ( ) ;
MENU__MAIN_ TAB_CLOSE - > append (
MENU__TAB_CLOSE - > append (
_ ( " Active tab " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_CLOSE_ACTIV E
ACTION__TAB_CLOSE
)
) ;
// @TODO
/*
MENU__MAIN_ TAB_CLOSE - > append (
MENU__TAB_CLOSE - > append (
_ ( " All tabs to left " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_CLOSE_LEFT
ACTION__TAB_CLOSE_LEFT
)
) ;
MENU__MAIN_ TAB_CLOSE - > append (
MENU__TAB_CLOSE - > append (
_ ( " All tabs to right " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_CLOSE_RIGHT
ACTION__TAB_CLOSE_RIGHT
)
) ;
*/
MENU__MAIN_ TAB_CLOSE - > append (
MENU__TAB_CLOSE - > append (
_ ( " All tabs " ) ,
get_action_detailed_name (
ACTION__MAIN_ TAB_CLOSE_ALL
ACTION__TAB_CLOSE_ALL
)
) ;
MENU__MAIN_ TAB - > append_submenu (
MENU__TAB - > append_submenu (
_ ( " Close " ) ,
MENU__MAIN_ TAB_CLOSE
MENU__TAB_CLOSE
) ;
MENU__MAIN - > append_submenu (
MENU - > append_submenu (
_ ( " Tab " ) ,
MENU__MAIN_ TAB
MENU__TAB
) ;
const auto MENU__MAIN_ TOOLS = Gio : : Menu : : create ( ) ;
const auto MENU__TOOLS = Gio : : Menu : : create ( ) ;
MENU__MAIN_ TOOLS - > append (
MENU__TOOLS - > append (
_ ( " Debug " ) ,
get_action_detailed_name (
ACTION__DEBUG
)
) ;
MENU__MAIN - > append_submenu (
MENU - > append_submenu (
_ ( " Tools " ) ,
MENU__MAIN_ TOOLS
MENU__TOOLS
) ;
MENU__MAIN - > append (
MENU - > append (
_ ( " Quit " ) ,
get_action_detailed_name (
ACTION__QUIT
@ -166,7 +166,7 @@ Menu::Menu(
@@ -166,7 +166,7 @@ Menu::Menu(
) ;
set_menu_model (
MENU__MAIN
MENU
) ;
}