add follow_to_index argument

This commit is contained in:
yggverse 2024-09-30 23:32:21 +03:00
parent 359950540e
commit cefdcdc859
2 changed files with 6 additions and 6 deletions

View File

@ -127,13 +127,13 @@ impl Page {
} }
pub fn navigation_history_back(&self) { pub fn navigation_history_back(&self) {
if let Some(url) = self.navigation.history_back() { if let Some(url) = self.navigation.history_back(true) {
self.action_page_open.activate(Some(&url.to_variant())); self.action_page_open.activate(Some(&url.to_variant()));
} }
} }
pub fn navigation_history_forward(&self) { pub fn navigation_history_forward(&self) {
if let Some(url) = self.navigation.history_forward() { if let Some(url) = self.navigation.history_forward(true) {
self.action_page_open.activate(Some(&url.to_variant())); self.action_page_open.activate(Some(&url.to_variant()));
} }
} }

View File

@ -89,12 +89,12 @@ impl Navigation {
self.history.add(request, true); self.history.add(request, true);
} }
pub fn history_back(&self) -> Option<GString> { pub fn history_back(&self, follow_to_index: bool) -> Option<GString> {
self.history.back(true) self.history.back(follow_to_index)
} }
pub fn history_forward(&self) -> Option<GString> { pub fn history_forward(&self, follow_to_index: bool) -> Option<GString> {
self.history.forward(true) self.history.forward(follow_to_index)
} }
pub fn update(&self, progress_fraction: Option<f64>) { pub fn update(&self, progress_fraction: Option<f64>) {