GNOME Bugzilla – Bug 723031
grilo: Use popover for the source selection
Last modified: 2014-01-28 17:05:34 UTC
.
Created attachment 267237 [details] [review] grilo: Use popover for the source selection
Problems with GtkPopover: - If we don't call gtk_popover_set_position(), nor "gtk_widget_show (self->priv->listbox);" meaning that the popover is empty, we get warnings as GtkPopover is placed on top of the entry: (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' failed (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' failed (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' failed - We never get a row-activated signal from the listbox, the popover pops down before we receive the signal - We'd like to hide the popover when somebody clicks on the tag after it's been opened, but GtkPopover pops it down before we get the click, so we can't pop it down.
(In reply to comment #2) > Problems with GtkPopover: > - If we don't call gtk_popover_set_position(), nor "gtk_widget_show > (self->priv->listbox);" meaning that the popover is empty, we get warnings as > GtkPopover is placed on top of the entry: > (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' > failed > > (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' > failed > > (totem:12066): Gtk-CRITICAL **: gtk_render_frame_gap: assertion 'xy0_gap >= 0' > failed The allocated size was indeed too small, so the gap was calculated out of boundaries, with commit 709fb26587 it should get a minimal size that caters for border-radius too, so the gap fits. > - We never get a row-activated signal from the listbox, the popover pops down > before we receive the signal GtkListBox button press handler was returning FALSE, so the popover would handle and popdown even if the listbox expected a button release... > - We'd like to hide the popover when somebody clicks on the tag after it's been > opened, but GtkPopover pops it down before we get the click, so we can't pop it > down. GtkPopover was unfortunately handling popdown on button press, so the widget below the pointer would get the button release after the grab was gone, and not all widgets track button state. Commit 7b4ef99320 moves that to button release, so that click only dismisses the popover and can't possibly trigger other actions.
Attachment 267237 [details] pushed as a8601ee - grilo: Use popover for the source selection