|
|
@ -59,6 +59,7 @@ impl Page { |
|
|
|
action_tab_append.clone(), |
|
|
|
action_tab_append.clone(), |
|
|
|
action_page_open.clone(), |
|
|
|
action_page_open.clone(), |
|
|
|
)); |
|
|
|
)); |
|
|
|
|
|
|
|
|
|
|
|
let navigation = Navigation::new_arc( |
|
|
|
let navigation = Navigation::new_arc( |
|
|
|
action_tab_page_navigation_base.clone(), |
|
|
|
action_tab_page_navigation_base.clone(), |
|
|
|
action_tab_page_navigation_history_back.clone(), |
|
|
|
action_tab_page_navigation_history_back.clone(), |
|
|
@ -66,6 +67,7 @@ impl Page { |
|
|
|
action_tab_page_navigation_reload.clone(), |
|
|
|
action_tab_page_navigation_reload.clone(), |
|
|
|
action_update.clone(), |
|
|
|
action_update.clone(), |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
let widget = Widget::new_arc( |
|
|
|
let widget = Widget::new_arc( |
|
|
|
action_page_open.clone(), |
|
|
|
action_page_open.clone(), |
|
|
|
&name, // ID
|
|
|
|
&name, // ID
|
|
|
@ -81,17 +83,15 @@ impl Page { |
|
|
|
let navigation = navigation.clone(); |
|
|
|
let navigation = navigation.clone(); |
|
|
|
let action_tab_page_navigation_reload = action_tab_page_navigation_reload.clone(); |
|
|
|
let action_tab_page_navigation_reload = action_tab_page_navigation_reload.clone(); |
|
|
|
move |_, request| { |
|
|
|
move |_, request| { |
|
|
|
// Convert to GString
|
|
|
|
// Update request
|
|
|
|
let request = GString::from( |
|
|
|
navigation.set_request_text( |
|
|
|
request |
|
|
|
request |
|
|
|
.expect("Parameter required for `page.open` action") |
|
|
|
.expect("Parameter required for `page.open` action") |
|
|
|
.get::<String>() |
|
|
|
.get::<String>() |
|
|
|
.expect("Parameter does not match `String`"), |
|
|
|
.expect("Parameter does not match `String`") |
|
|
|
|
|
|
|
.as_str(), |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
// Update
|
|
|
|
|
|
|
|
navigation.set_request_text(&request); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Reload page
|
|
|
|
// Reload page
|
|
|
|
action_tab_page_navigation_reload.activate(None); |
|
|
|
action_tab_page_navigation_reload.activate(None); |
|
|
|
} |
|
|
|
} |
|
|
|