HaikuPorts
  • Login
  • Preferences
  • Help/Guide
  • Wiki
  • Timeline
  • Roadmap
  • View Tickets
  • Search
  • Port Log
  • Blog

Context Navigation

  • ← Previous Ticket
  • Back to Query
  • Next Ticket →

Ticket #161 (closed enhancement: fixed)

Opened 6 years ago

Last modified 7 months ago

Finish implementation of native Drag And Drop

Reported by: mmadia Owned by: mmadia
Priority: normal Milestone: Unscheduled
Component: www-client/mozilla-firefox Version:
Severity: normal Keywords:
Cc:

Description

 https://bugzilla.mozilla.org/show_bug.cgi?id=343736

Too much to summarize...

Note: A proper Drag and Drop implementation in Firefox would greatly help to increase its integration into Haiku

Change History

comment:1 Changed 6 years ago by mmadia

This has been suggested as the current state of Drag and Drop:

Taken from :  http://community.livejournal.com/bezilla/100141.html

tqh ([info]tqh) wrote in [info]bezilla,
@ 2005-06-19 16:35:00

Drag'n'Drop status
After talking to Sergei, and then going of in a completly different direction1, the backbone for all types of DnD is done. Every nsWindow (or the BView in it) now starts the dragsession on a MOUSE_ENTER, and ends it on a MOUSE_EXIT, but only when we have a dragmessage.

The thing left to do is getting and setting the appropriate data for all but Mozilla to Mozilla DnD's.

This isn't really how it's supposed to be done, but it's the best way Sergei or I have come up with so far. This ensures that the dragsession starts when you drag something in from outside or when you drag something out from the inside, which is good. The bad is that we keep some data longer than it should, and some shorter than we should.

  • the dragged data stays until another drag is started (ie a new internal drag, or a drag message from the outside).
  • the frame and node where an internal drag is started is lost on the first MOUSE_EXIT. We could probably save it, but it's not completly simple. Holding on to it for to long and you lock the UI, and we can't determine exactly when to release it because of our asynchronous DnD. Cloning a frame and a node, on the other hand, probably a takes a lot of memory.

1 Which Sergei and I discussed earlier and I said couldn't be done, due to some faulty test I had done. The solution which I was supposed to take, ending it on MouseUp?, was hard to do because it occured before the drop was done. It could only be done when dropping outside of Mozilla, which is hard to detect. When the drop was inside it wouldn't register as the DnD had already ended.

comment:2 Changed 6 years ago by mmadia

Taken from :  http://community.livejournal.com/bezilla/128922.html

tqh ([info]tqh) wrote in [info]bezilla,
@ 2005-10-14 22:31:00

My turn?
Fyysik has been doing so many changes to nsWindow I can't keep my patches up to date. Frankly I've had it! In a good way that is, so I've decided to make sure that Drag'n'Drop gets checked in this weekend, before fyysik manages to do another impressive change to nsWindow. It's almost finished, and has been for quite some time. It's just that I find the DND-negotiation message, and converting between Mozilla formats and Be's own, completly boring and uninteresting. I might do this in two stages with the working things first and DND to BeOS (with the boring negotiation) later.

Anyway this very long standing bug is here: Bug 104729

Update: I think I'll remove the image-dragging. It's cool and an additional feature compared to other platforms, but it flashes a bit and can be done later if wanted.

Update2: Patches updated to current state.

Update3 Some patches are checked in, some on it's way (there was an error I introduced yesterday). You might want to wait until they are in to start a build..

comment:3 Changed 6 years ago by mmadia

Another update:
First step is to implement TransmitData? here:
 http://mxr.mozilla.org/mozilla1.8/source/widget/src/beos/nsDragService.cpp#713

It is called when you drop something from Mozilla, as you can see the
output when you try. All that is needed is to finish the negotiation
with the other app. Reading up on DnD negotiation in Bebook is
recommended.

You can see it called from here:
 http://mxr.mozilla.org/mozilla1.8/source/widget/src/beos/nsWindow.cpp#3251

For drops from the outside you will end up here:
 http://mxr.mozilla.org/mozilla1.8/source/widget/src/beos/nsDragService.cpp#481
in nsDragService::GetData?. It is also a negotiation that needs to be
done. The comments outline the steps.

comment:4 Changed 6 years ago by mmadia

another two notes from tqh:

you might want to read up on DnD negotiation in BeBook?, then implement  http://mxr.mozilla.org/mozilla1.8/source/widget/src/beos/nsDragService.cpp#713 to be able to drag FROM Mozilla.

comment:5 Changed 7 months ago by pulkomandy

  • Resolution set to fixed
  • Status changed from new to closed

Moved to bugzilla github page.

Note: See TracTickets for help on using tickets.

Download in other formats:

  • Comma-delimited Text
  • Tab-delimited Text
  • RSS Feed

Trac Powered

Powered by Trac 0.13dev-r10686
By Edgewall Software.

Visit the Trac open source project at
http://trac.edgewall.org/