musicus/data/ui/selector/role.blp

50 lines
990 B
Text

using Gtk 4.0;
using Adw 1;
template $MusicusRoleSelectorPopover: Gtk.Popover {
styles [
"selector",
]
Adw.ToolbarView {
[top]
Gtk.Box {
spacing: 6;
margin-start: 8;
margin-end: 8;
margin-top: 8;
margin-bottom: 6;
Gtk.SearchEntry search_entry {
placeholder-text: _("Search roles…");
hexpand: true;
search-changed => $search_changed() swapped;
activate => $activate() swapped;
stop-search => $stop_search() swapped;
}
Gtk.Button {
icon-name: "edit-clear-symbolic";
tooltip-text: _("Reset to default role");
clicked => $reset_button_clicked() swapped;
styles [
"flat",
]
}
}
Gtk.ScrolledWindow scrolled_window {
height-request: 200;
Gtk.ListBox list_box {
styles [
"selector-list",
]
selection-mode: none;
activate-on-single-click: true;
}
}
}
}