|
|
|
@ -24,36 +24,11 @@ Page::Page(
@@ -24,36 +24,11 @@ Page::Page(
|
|
|
|
|
// Init shared actions
|
|
|
|
|
action__update = ACTION__UPDATE; |
|
|
|
|
|
|
|
|
|
// Init widget
|
|
|
|
|
set_orientation( |
|
|
|
|
Gtk::Orientation::VERTICAL |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Init widget components
|
|
|
|
|
pageNavigation = Gtk::make_managed<page::Navigation>( |
|
|
|
|
this->db, |
|
|
|
|
ACTION__HISTORY_BACK, |
|
|
|
|
ACTION__HISTORY_FORWARD, |
|
|
|
|
ACTION__RELOAD, |
|
|
|
|
ACTION__UPDATE |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
append( |
|
|
|
|
* pageNavigation |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
pageContent = Gtk::make_managed<page::Content>(); |
|
|
|
|
// Init additional local action group (for clickable content)
|
|
|
|
|
const auto ACTION_GROUP__PAGE = Gio::SimpleActionGroup::create(); |
|
|
|
|
|
|
|
|
|
append( |
|
|
|
|
* pageContent |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Init widget action group @TODO
|
|
|
|
|
auto GioSimpleActionGroup = Gio::SimpleActionGroup::create(); |
|
|
|
|
|
|
|
|
|
// Define group actions
|
|
|
|
|
GioSimpleActionGroup->add_action_with_parameter( |
|
|
|
|
"open", |
|
|
|
|
const auto ACTION__OPEN_LINK_VARIANT = ACTION_GROUP__PAGE->add_action_with_parameter( |
|
|
|
|
"open_link_variant", |
|
|
|
|
Glib::VARIANT_TYPE_STRING, |
|
|
|
|
[this](const Glib::VariantBase & PARAMETER) |
|
|
|
|
{ |
|
|
|
@ -72,9 +47,35 @@ Page::Page(
@@ -72,9 +47,35 @@ Page::Page(
|
|
|
|
|
} |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Init widget
|
|
|
|
|
insert_action_group( |
|
|
|
|
"page", |
|
|
|
|
GioSimpleActionGroup |
|
|
|
|
ACTION_GROUP__PAGE |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
set_orientation( |
|
|
|
|
Gtk::Orientation::VERTICAL |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Init widget components
|
|
|
|
|
pageNavigation = Gtk::make_managed<page::Navigation>( |
|
|
|
|
this->db, |
|
|
|
|
ACTION__HISTORY_BACK, |
|
|
|
|
ACTION__HISTORY_FORWARD, |
|
|
|
|
ACTION__RELOAD, |
|
|
|
|
ACTION__UPDATE |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
append( |
|
|
|
|
* pageNavigation |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
pageContent = Gtk::make_managed<page::Content>( |
|
|
|
|
ACTION__OPEN_LINK_VARIANT |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
append( |
|
|
|
|
* pageContent |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Connect events
|
|
|
|
|