window: Move Sort & Filter menu to center

This commit is contained in:
kramo
2025-11-30 00:09:34 +01:00
parent 68e663e048
commit 14696a5d2a

View File

@@ -26,34 +26,24 @@ template $Window: Adw.ApplicationWindow {
content: Adw.ToolbarView { content: Adw.ToolbarView {
[top] [top]
Adw.HeaderBar { Adw.HeaderBar {
title-widget: Adw.Clamp { title-widget: Adw.Clamp clamp {
maximum-size: 500; tightening-threshold: bind clamp.maximum-size;
tightening-threshold: 500;
child: SearchEntry search_entry { child: CenterBox {
hexpand: true;
center-widget: SearchEntry search_entry {
hexpand: true; hexpand: true;
placeholder-text: _("Search games"); placeholder-text: _("Search games");
search-started => $_search_started(); search-started => $_search_started();
search-changed => $_search_changed(); search-changed => $_search_changed();
stop-search => $_stop_search(); stop-search => $_stop_search();
}; };
};
[end] end-widget: MenuButton {
MenuButton {
icon-name: "open-menu-symbolic";
tooltip-text: _("Main Menu");
primary: true;
menu-model: menu {
item (_("About Cartridges"), "app.about")
};
}
[end]
MenuButton {
icon-name: "filter-symbolic"; icon-name: "filter-symbolic";
tooltip-text: _("Sort & Filter"); tooltip-text: _("Sort & Filter");
margin-start: 6;
menu-model: menu { menu-model: menu {
section { section {
@@ -94,6 +84,19 @@ template $Window: Adw.ApplicationWindow {
item (_("Show Hidden Games"), "win.show-hidden") item (_("Show Hidden Games"), "win.show-hidden")
} }
}; };
};
};
};
[end]
MenuButton {
icon-name: "open-menu-symbolic";
tooltip-text: _("Main Menu");
primary: true;
menu-model: menu {
item (_("About Cartridges"), "app.about")
};
} }
} }