Browse Source

define mod struct

master
yggverse 2 months ago
parent
commit
83040ada79
  1. 17
      src/browser/header/mod.rs

17
src/browser/header/mod.rs

@ -1,12 +1,19 @@
mod subject; mod subject;
mod tray; mod tray;
use std::sync::Arc;
use gtk::HeaderBar; use gtk::HeaderBar;
pub fn new() -> HeaderBar { pub struct Header {
let header = HeaderBar::builder().build(); pub widget: Arc<gtk::HeaderBar>,
}
pub fn new() -> Header {
let widget = Arc::new(HeaderBar::builder().build());
widget.pack_start(&tray::new());
widget.set_title_widget(Some(&subject::new()));
header.pack_start(&tray::new()); Header { widget }
header.set_title_widget(Some(&subject::new()));
header
} }

Loading…
Cancel
Save