GNOME Bugzilla – Bug 335873
notebook DND + popup windows
Last modified: 2011-02-04 16:10:27 UTC
When a modal window which is parented to the window containing the notebook pops up, the notebook DND operation in progress should be aborted. What happens right now is that while the dialogue is up, the dragged tab stays whereever it was when the window popped up, even after the popup is gone, until ... not sure what exactly, but tab switching makes the position right again. You can see this problem in Epiphany HEAD with a gecko 1.7 backend (or set browser.xul.error_pages.enabled to false in about:config), and drag a tab when a timeout popup comes up.
Created attachment 61935 [details] testcase as patch for testnotebookdnd.c The patch makes testnotebookdnd popup/hide a modal window regularly. If you drag a tab when the popup comes up, you can see the effect.
I believe this should be fixed by stopping any reordering/drag in gtk_notebook_grab_notify.
I'm working on this
Created attachment 67662 [details] [review] patch to fix this the patch moves the line: priv->pressed_button = -1; inside gtk_notebook_stop_reorder() (it was being always called beside that function anyway) and calls this function inside gtk_notebook_grab_notify()
Looks fine to commit.
Thanks! 2006-06-20 Carlos Garnacho <carlosg@gnome.org> * gtk/gtknotebook.c (gtk_notebook_stop_reorder): unset the pressed button here. (gtk_notebook_grab_notify): stop reorder when the widget becomes shadowed. Fixes bug #335873