From 8643f9ba9be4d7b21673b9d0ca03f3f4e46b9add Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marta=20Marczykowska-G=C3=B3recka?= Date: Fri, 3 Jan 2025 15:48:31 +0100 Subject: [PATCH] Don't change combobox on mouse scroll This causes problems and is inconvenient, easy to change something by accident fixes QubesOS/qubes-issues#9675 --- qubes_config/global_config/global_config.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/qubes_config/global_config/global_config.py b/qubes_config/global_config/global_config.py index fb1a1c5..808d74f 100644 --- a/qubes_config/global_config/global_config.py +++ b/qubes_config/global_config/global_config.py @@ -438,6 +438,12 @@ def perform_setup(self): self.builder.get_object('thisdevice_scrolled_window'), ]) + # workaround the uncomfortable behavior with comboboxes: combobox + # should not change item ID on random scrolling around + for obj in self.builder.get_objects(): + if isinstance(obj, (Gtk.ComboBox, Gtk.ComboBoxText)): + obj.connect("scroll-event", lambda *args: True) + self.progress_bar_dialog.update_progress(1) self.progress_bar_dialog.hide() self.progress_bar_dialog.destroy()