mirror of
https://github.com/YGGverse/Yoda.git
synced 2025-03-10 12:41:34 +00:00
update tab title on loading indicator inactive
This commit is contained in:
parent
b1f30fbd1e
commit
4759ce4815
@ -159,13 +159,15 @@ impl Tab {
|
|||||||
// Update item components
|
// Update item components
|
||||||
item.update();
|
item.update();
|
||||||
|
|
||||||
// Update tab title
|
// Update tab title on loading indicator inactive
|
||||||
|
if !item.page_is_loading() {
|
||||||
if let Some(title) = item.page_meta_title() {
|
if let Some(title) = item.page_meta_title() {
|
||||||
item.gobject().set_title(title.as_str())
|
item.gobject().set_title(title.as_str())
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
pub fn clean(
|
pub fn clean(
|
||||||
&self,
|
&self,
|
||||||
|
@ -89,7 +89,7 @@ impl Item {
|
|||||||
self.page.update();
|
self.page.update();
|
||||||
|
|
||||||
// Update tab loading indicator
|
// Update tab loading indicator
|
||||||
self.widget.gobject().set_loading(self.page.is_loading());
|
self.widget.gobject().set_loading(self.page_is_loading());
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn clean(
|
pub fn clean(
|
||||||
@ -198,6 +198,10 @@ impl Item {
|
|||||||
self.id.clone()
|
self.id.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn page_is_loading(&self) -> bool {
|
||||||
|
self.page.is_loading()
|
||||||
|
}
|
||||||
|
|
||||||
pub fn page_meta_title(&self) -> Option<GString> {
|
pub fn page_meta_title(&self) -> Option<GString> {
|
||||||
self.page.meta_title()
|
self.page.meta_title()
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user