mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-01 09:05:27 +00:00
create separated mod for widget
This commit is contained in:
parent
7d4cf5c1f3
commit
2b12fe207f
3 changed files with 67 additions and 40 deletions
19
src/app/browser/window/tab/widget.rs
Normal file
19
src/app/browser/window/tab/widget.rs
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
use gtk::Notebook;
|
||||
|
||||
pub struct Widget {
|
||||
gobject: Notebook,
|
||||
}
|
||||
|
||||
impl Widget {
|
||||
// Construct
|
||||
pub fn new() -> Self {
|
||||
let gobject = Notebook::builder().scrollable(true).build();
|
||||
|
||||
Self { gobject }
|
||||
}
|
||||
|
||||
// Getters
|
||||
pub fn gobject(&self) -> &Notebook {
|
||||
&self.gobject
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue