GNOME Bugzilla – Bug 749252
GtkListBox don’t deselect entries if ‘selection-mode’ is GTK_SELECTION_MODE_MULTIPLE
Last modified: 2018-05-02 16:34:58 UTC
If I set the property ‘activate-on-single-click’ to TRUE and ‘selection-mode’ to GTK_SELECTION_MODE_MULTIPLE children can’t be deselected with a click. By clicking on an unselected row the signals ‘row-selected’, ‘selected-row-changed’ and ‘row-activated’ are sent. If you click on a selected row the signal ‘row-activated’ is sent, but the selection isn’t changed. With this properties actually you expect that a click on a row changes the selection to this row only and activates it. If you hold down the Ctrl key no row will be activated but, the selection of the row is enabled/disabled, depending on the current state.
Would be nice to be able deselect a selected row if the property ‘activate-on-single-click’ is TRUE and ‘selection-mode’ is GTK_SELECTION_MODE_MULTIPLE. We use the GtkListBox in gnome-abrt and there is a problem when you select a wrong row in multiple selection mode. You cannot fix the wrong selected row but you have to start to select from the beginning.
We're moving to gitlab! As part of this move, we are moving bugs to NEEDINFO if they haven't seen activity in more than a year. If this issue is still important to you and still relevant with GTK+ 3.22 or master, please reopen it and we will migrate it to gitlab.
This issue is still true with Gtk+ 3.92.1 and can easily be reproduced using gtk4-demo's "List Box" when setting the properties of the GtkListBox (see above) through GtkInspector.
A modification of the test case to show this bug would be useful (so as to avoid going through GtkInspector to reproduce the bug).
Created attachment 368234 [details] A glade file demonstrating the bug The attached glade file is enough for reproducing the bug. Just open it in glade and click on the "Preview" button in glade.
CTRL/SHIFT + Click does also nothing. although because of the bug we can not evaluate if CTRL + Click does something. But Shift + Click should select a range which it does not
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gtk/issues/552.