Yoda/src/browser/main/widget.rs
2024-09-22 20:58:23 +03:00

24 lines
399 B
Rust

use gtk::prelude::BoxExt;
pub struct Main {
gtk: gtk::Box,
}
impl Main {
// Construct new object
pub fn new(tab: &gtk::Notebook) -> Main {
let gtk = gtk::Box::builder()
.orientation(gtk::Orientation::Vertical)
.build();
gtk.append(tab);
Self { gtk }
}
// Getters
pub fn gtk(&self) -> &gtk::Box {
&self.gtk
}
}