GNOME Bugzilla – Bug 780498
Use gtk_menu_popup_at_widget and set 'transient-for' in the Photo Dialog
Last modified: 2017-05-03 11:59:31 UTC
The popup menu could be presented in a wrong position in touchscreens under wayland. See https://bugzilla.gnome.org/show_bug.cgi?id=771802
Created attachment 348642 [details] [review] user-accounts: Use gtk_menu_popup_at_widget for user photo popup gtk_menu_popup has been deprecated since version 3.22. The use of gtk_menu_popup lately was causing gtk+ to have to guess the right position to present the widget, causing the menu to eventually appear in a wrong position under Wayland.
Created attachment 348643 [details] [review] user-accounts: Explicitly set photo_popup transient_for window Instead of relying in the underlying machinery for guessing the correct window.
Review of attachment 348642 [details] [review]: Looks ok and fixes the following: Gdk-Message: Window 0x55918c71b000 is a temporary window without parent, application will not be able to position it on screen. Gdk-Message: Window 0x55918c71b000 is a temporary window without parent, application will not be able to position it on screen. (gnome-control-center:23117): Gdk-CRITICAL **: xdg_popup_configure: assertion 'impl->transient_for' failed
Review of attachment 348643 [details] [review]: Why is this needed?
(In reply to Ondrej Holy from comment #4) > Review of attachment 348643 [details] [review] [review]: > > Why is this needed? Because the logic to automatically pick up the right window might change, so we arbitrarily enforce it to avoid unexpected behavior. There was more discussions to it on IRC and on Bug 771802.
Comment on attachment 348642 [details] [review] user-accounts: Use gtk_menu_popup_at_widget for user photo popup This one is ready to go already. Attachment 348642 [details] pushed as 9536dcd - user-accounts: Use gtk_menu_popup_at_widget for user photo popup
Review of attachment 348643 [details] [review]: Should be ok then...
Thanks! Attachment 348643 [details] pushed as 9368992 - user-accounts: Explicitly set photo_popup transient_for window