Add new tab button next to window controls (#89)
This commit is contained in:
parent
ff6ad163d6
commit
6ec3e499cb
1 changed files with 9 additions and 0 deletions
|
|
@ -1403,6 +1403,15 @@ impl Application for App {
|
|||
vec![menu_bar(&self.key_binds).into()]
|
||||
}
|
||||
|
||||
fn header_end(&self) -> Vec<Element<Self::Message>> {
|
||||
let cosmic_theme::Spacing { space_xxs, .. } = self.core().system_theme().cosmic().spacing;
|
||||
vec![widget::button(widget::icon::from_name("list-add-symbolic"))
|
||||
.on_press(Message::TabNew)
|
||||
.padding(space_xxs)
|
||||
.style(style::Button::Icon)
|
||||
.into()]
|
||||
}
|
||||
|
||||
/// Creates a view after each update.
|
||||
fn view(&self) -> Element<Self::Message> {
|
||||
let cosmic_theme::Spacing { space_xxs, .. } = self.core().system_theme().cosmic().spacing;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue