From: Christian Heller Date: Thu, 12 Sep 2024 18:54:59 +0000 (+0200) Subject: In browser, grab focus on sort orderer when navigating it. X-Git-Url: https://plomlompom.com/repos/%7B%7Bdb.prefix%7D%7D/%7B%7B%20web_path%20%7D%7D/task?a=commitdiff_plain;h=473268f0bf5ffefce3008f4e3fe1ff8436653152;p=stable_plom In browser, grab focus on sort orderer when navigating it. --- diff --git a/browser.py b/browser.py index d95eb10..7b9e389 100755 --- a/browser.py +++ b/browser.py @@ -179,6 +179,10 @@ class MainWindow(Gtk.Window): self.sort_order.reverse() self.sort_store = Gio.ListStore(item_type=SortLabelItem) self.sort_selection = Gtk.SingleSelection.new(self.sort_store) + self.sort_selection.connect( + 'selection-changed', + lambda a, b, c: self.sort_selection.props.selected_item.box + .props.child.get_parent().grab_focus()) factory = Gtk.SignalListItemFactory() def setup_sort_order_item(_, item):