Last Comment Bug 367203 - gtk2 dnd implementation broken
: gtk2 dnd implementation broken
Status: RESOLVED FIXED
: fixed1.8.0.10, fixed1.8.1.2
Product: Core
Classification: Components
Component: Widget: Gtk (show other bugs)
: Trunk
: x86 Linux
: -- normal with 2 votes (vote)
: ---
Assigned To: Matthias Clasen
:
:
Mentors:
: 355248 367725 367727 368672 370046 370262 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-01-16 18:45 PST by Matthias Clasen
Modified: 2010-09-18 10:26 PDT (History)
20 users (show)
dveditz: blocking1.8.0.10-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch (689 bytes, patch)
2007-01-16 18:48 PST, Matthias Clasen
caillon: review+
roc: superreview+
dveditz: approval1.8.1.2+
dveditz: approval1.8.0.10+
Details | Diff | Splinter Review

Description Matthias Clasen 2007-01-16 18:45:22 PST
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.1) Gecko/20061222 Firefox/2.0.0.1
Build Identifier: version 1.5.0.9 (20061223)

Starting with gtk 2.10.7, drags are canceled when the toolkit-private drag widget
is grab-shadowed by another gtk_grab_add call in the application. This is a 
necessary fix to avoid "stuck drag" situations when a modal dialog pops up while
a drag is in progress.

Unfortunately, the mozilla dnd implementation does just that - it calls gtk_grab_add in the nsDragService::GetTargetDragData method. This causes
drags of mesages from the message list to the folder tree in thunderbird
to fail with gtk 2.10.7.

Fortunately, the gtk_grab_add in nsDragService::GetTargetDragData doesn't
seem to have any real purpose - at least the nsDragService code doesn't 
make any use of the grabbing, and just removing the grab_add/grab_remove
calls in that function makes dnd work again in thunderbird.

Reproducible: Always

Steps to Reproduce:
1.
2.
3.
Comment 1 Matthias Clasen 2007-01-16 18:48:08 PST
Created attachment 251710 [details] [diff] [review]
patch
Comment 2 Thomas Zajic 2007-01-17 03:48:08 PST
This is to confirm that Matthias' patch works fine with thunderbird-1.5.0.9 and gtk+-2.10.8 (see http://bugzilla.gnome.org/show_bug.cgi?id=394525 for my original bug report against GTK+).

Thanks!
Comment 3 Magnus Melin 2007-01-17 07:30:29 PST
I guess you need someone to check this in... ?
Comment 4 Christopher Aillon (sabbatical, not receiving bugmail) 2007-01-19 07:00:27 PST
Checking in nsDragService.cpp;
/cvsroot/mozilla/widget/src/gtk2/nsDragService.cpp,v  <--  nsDragService.cpp
new revision: 1.12; previous revision: 1.11
done
Comment 5 Kai Engert (:kaie) (on vacation) 2007-01-29 11:34:12 PST
Comment on attachment 251710 [details] [diff] [review]
patch

Can we land this fix on the 1.8.1 branch for Thunderbird 2?

And possibly on 1.8.0 branch, too?

Drag and drop is broken on Linux in both branches for me.
Comment 6 Magnus Melin 2007-01-29 12:05:38 PST
Comment on attachment 251710 [details] [diff] [review]
patch

Asking approval per previous comment...
Comment 7 Scott MacGregor 2007-01-29 22:11:03 PST
this seems like a pretty bad linux regression for drag and drop that more users are going to start noticing as they start to use more recent versions of gtk.

Triage team: we could also consider taking this for 1.8.1.3, which will still get it in time for Thunderbird 2.
Comment 8 Magnus Melin 2007-01-29 22:36:51 PST
*** Bug 367725 has been marked as a duplicate of this bug. ***
Comment 9 John Griffiths 2007-01-30 07:53:45 PST
Has this been added to the 1.5.0 branch? Will there be a 1.5.0.X that will contain this patch?
Comment 10 Kai Engert (:kaie) (on vacation) 2007-01-30 08:13:04 PST
(In reply to comment #9)
> Has this been added to the 1.5.0 branch? Will there be a 1.5.0.X that will
> contain this patch?
> 

Not yet, this is why we requested approval1.8.0.10 for the branch where 1.5 lives on.
Comment 11 Christopher Aillon (sabbatical, not receiving bugmail) 2007-01-30 11:27:27 PST
Hm, I thought I requested the flags on this bug when I committed, and I've been away for a week...

Anyway, doing so now.  This is wanted for users of Firefox on new GTK+.  See the original comment from Matthias for a better description as to why we need this.  The fix is very low risk.
Comment 12 Daniel Veditz [:dveditz] 2007-01-30 15:24:29 PST
Comment on attachment 251710 [details] [diff] [review]
patch

approved for 1.8/1.8.0 branches, a=dveditz for drivers
Comment 13 Daniel Veditz [:dveditz] 2007-01-30 15:25:06 PST
We're not going to hold the release for this, so please land ASAP
Comment 14 Christopher Aillon (sabbatical, not receiving bugmail) 2007-01-30 20:32:14 PST
Landed on MOZILLA_1_8_0_BRANCH and MOZILLA_1_8_BRANCH
Comment 15 Paul Black 2007-01-31 15:19:49 PST
*** Bug 368672 has been marked as a duplicate of this bug. ***
Comment 16 Carsten Book [:Tomcat] 2007-02-13 07:43:50 PST
*** Bug 367727 has been marked as a duplicate of this bug. ***
Comment 17 Magnus Melin 2007-02-14 07:57:10 PST
*** Bug 370295 has been marked as a duplicate of this bug. ***
Comment 18 Magnus Melin 2007-02-14 07:58:50 PST
*** Bug 370262 has been marked as a duplicate of this bug. ***
Comment 19 Magnus Melin 2007-02-14 08:03:00 PST
*** Bug 355248 has been marked as a duplicate of this bug. ***
Comment 20 Magnus Melin 2007-02-14 08:05:06 PST
*** Bug 370046 has been marked as a duplicate of this bug. ***
Comment 21 jigar shah 2007-02-16 23:41:36 PST
I have installed FF 2.0.0.1 on Fedora 6. I Cannot drag and drop bookmarks. I don't get anything in Update for fedora 6. Please let me know What i need to do.
Comment 22 jigar shah 2007-02-16 23:44:28 PST
Sorry i forgot to include My configuration.
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.1) Gecko/20061208 Firefox/2.0.0.1

I think its already landed on 1.8.0.10 1 and 1.8.1.2 But not on 1.8.1.1
Comment 23 Magnus Melin 2007-02-17 02:28:22 PST
You will need a release after 2007-01-30 to see the fix.
Comment 24 Geoffrey Buchan 2007-02-28 03:20:16 PST
This fix works for seamonkey 1.5a (version I just built from source):
SeaMonkey 1.5a
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a3pre) Gecko/20070228 SeaMonkey/1.5a

The most recent release of seamonkey, 1.1, has the bug on my system.



Note You need to log in before you can comment on or make changes to this bug.