mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-02 17:45:28 +00:00
26 lines
482 B
Rust
26 lines
482 B
Rust
mod widget;
|
|
|
|
use widget::Widget;
|
|
|
|
use crate::app::browser::window::action::Action as WindowAction;
|
|
use std::rc::Rc;
|
|
|
|
pub struct Bookmark {
|
|
pub widget: Rc<Widget>,
|
|
}
|
|
|
|
impl Bookmark {
|
|
// Constructors
|
|
|
|
/// Build new `Self`
|
|
pub fn build(action: &Rc<WindowAction>) -> Self {
|
|
Self {
|
|
widget: Rc::new(Widget::build(action)),
|
|
}
|
|
}
|
|
|
|
// Actions
|
|
pub fn update(&self, has_bookmark: bool) {
|
|
self.widget.update(has_bookmark);
|
|
}
|
|
}
|