[wayland] Various window operations break and unbreak D&D
Categories
(Core :: Widget: Gtk, defect, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr78 | --- | unaffected |
firefox87 | --- | unaffected |
firefox88 | --- | unaffected |
firefox89 | --- | fixed |
firefox90 | --- | fixed |
People
(Reporter: heftig, Assigned: stransky)
References
(Blocks 1 open bug, Regression)
Details
(Keywords: regression)
Dropping toggles between normal and broken when certain things are done. So far I've discovered this happens when:
- A Firefox window is moved
- A Firefox window is resized
- Focus switches to another application
- The GNOME Shell overview is toggled
In the broken state, drops are not accepted. Dragging doesn't seem to break.
Firefox Nightly, GNOME 40, Arch Linux.
Reporter | ||
Comment 1•4 years ago
|
||
Last good revision: ffe826ff89b9de9c535516bec5bbfc1ec017e428
First bad revision: 003fab04d7ccda540d62c4ee6937e689c6c4d3b6
Pushlog: https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=ffe826ff89b9de9c535516bec5bbfc1ec017e428&tochange=003fab04d7ccda540d62c4ee6937e689c6c4d3b6
Regressed by bug 1703490.
Updated•4 years ago
|
Comment 2•4 years ago
|
||
Can reproduce on Mutter, Weston and Sway, even though those two appear to toggle less often for me.
Martin, NIing you in case it's not yet on your radar.
Assignee | ||
Comment 3•4 years ago
|
||
Which exact D&D operation is broken? Window tab D&D or content D&D?
Comment 4•4 years ago
|
||
(In reply to Martin Stránský [:stransky] (ni? me) from comment #3)
Which exact D&D operation is broken? Window tab D&D or content D&D?
From what I can see both. Note: only dropping is affected, not dragging. I.e. when trying to drop something on an affected window, the drop indicator doesn't show a plus or arrow next to the hand and dropping has no effect.
Assignee | ||
Comment 5•4 years ago
|
||
And the drop comes from different application than Firefox or is that firefox -> firefox only?
Comment 6•4 years ago
|
||
(In reply to Martin Stránský [:stransky] (ni? me) from comment #5)
And the drop comes from different application than Firefox or is that firefox -> firefox only?
Both. Just reproduced when trying to drop text from gedit
. Wild guess is that we somehow don't properly get/handle some activation request.
Comment 7•4 years ago
|
||
Set release status flags based on info from the regressing bug 1703490
Updated•4 years ago
|
Assignee | ||
Comment 8•4 years ago
|
||
I think the bug 1703490 (duplicated handlers) was actually hiding the underlying bug when the handlers were doubled so it was better chance to get the drop event. From my experience the drop always works for chrome process (i.e. URL bar) but fails for content process.
Assignee | ||
Comment 9•4 years ago
|
||
Can you please attach a log from Firefox running with
MOZ_LOG="WidgetDrag:5, nsDragService:5"
env variables?
From my testing there are two cases when D&D fails:
- D&D events are not fired, usually when Firefox app does not have focus.
- When D&D events are processed D&D is not finished after mouse up.
Reporter | ||
Comment 10•4 years ago
|
||
When it works:
Started, opened second tab, then dragged to reorder the tabs:
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::nsDragService
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::InvokeDragSession
[Parent 70316: Main Thread]: D/WidgetDrag adding target application/x-moz-tabbrowser-tab
[Parent 70316: Main Thread]: D/WidgetDrag adding target text/x-moz-text-internal
[Parent 70316: Main Thread]: D/WidgetDrag invisibleSourceDragBegin
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragMotionHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::SetCanDrop 1
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::ReplyToDragMotion 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragLeaveHandler()
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragLeaveHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragDropHandler nsWindow 7f85df286400
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::EndDragSession 1
[Parent 70316: Main Thread]: D/WidgetDrag WindowDragLeaveHandler()
[Parent 70316: Main Thread]: D/WidgetDrag Failed - GetMostRecentDestWindow()!
[Parent 70316: Main Thread]: D/WidgetDrag invisibleSourceDragEnd
[Parent 70316: Main Thread]: D/WidgetDrag SourceEndDragSession result 0
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::Observe("quit-application")
###!!! [Parent][RunMessage] Error: Channel closing: too late to send/recv, messages will be lost
[Parent 70316: Main Thread]: D/WidgetDrag nsDragService::~nsDragService
When it's broken:
Started, moved window, opened second tab, then attempted to drag to reorder tabs, which caused the tab to be detached.
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::nsDragService
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::InvokeDragSession
[Parent 71162: Main Thread]: D/WidgetDrag adding target application/x-moz-tabbrowser-tab
[Parent 71162: Main Thread]: D/WidgetDrag adding target text/x-moz-text-internal
[Parent 71162: Main Thread]: D/WidgetDrag invisibleSourceDragBegin
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::StartDragSession
[Parent 71162: Main Thread]: D/WidgetDrag invisibleSourceDragFailed: Wayland tab drop
[Parent 71162: Main Thread]: D/WidgetDrag invisibleSourceDragFailed 1
[Parent 71162: Main Thread]: D/WidgetDrag SourceEndDragSession result 1
[Parent 71162: Main Thread]: D/WidgetDrag guess drag end point 448 90
[Parent 71162: Main Thread]: D/WidgetDrag invisibleSourceDragEnd
[Parent 71162: Main Thread]: D/WidgetDrag SourceEndDragSession result 0
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::EndDragSession 1
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::Observe("quit-application")
[Parent 71162: Main Thread]: D/WidgetDrag nsDragService::~nsDragService
Assignee | ||
Comment 11•3 years ago
|
||
Guys, can you please test with Bug 1706624 fixed? I see sometimes the D&D events are not send to our data_device but it's much better with Bug 1706624 fixed.
Assignee | ||
Updated•3 years ago
|
Comment 12•3 years ago
|
||
Testing is currently blocked by bug 1706452, here's a try build with it: https://treeherder.mozilla.org/jobs?repo=try&revision=541bbf041e7f3ba0e7e90cb7579d98f311b9ce7b
Comment 13•3 years ago
|
||
Martin, tested it and while DnD in general appears to be more stable, this specific bug is not yet fixed for me. What strikes me is how predictable it is: it toggles, apparently on window activation or so, every time I do one of the action Jan described, I.e. tabbing away and back again. Will also have a look today.
Assignee | ||
Comment 14•3 years ago
|
||
As far as D&D nsDragService handlers are fired it's a Firefox bug and it's not related to bug 1703490. Perhaps we may need more D&D logging to find out why the handler is not accepted.
Comment 15•3 years ago
|
||
So I'm currently looking into focus events (focus_in_event_cb
, focus_out_event_cb
), because they get triggered by all the actions listed above. A first finding:
- when things work, then we have
nsDragService::StartDragSession
->focus_ot_event_cb
->focus_out_event_cb
. - when things don't work, then we have
nsDragService::StartDragSession
->focus_ot_event_cb
.focus_out_event_cb
is only fired after the canceling the DnD operation.
This probably already explains why we don't offer a drop target. So the remaining question likely is: why don't we fire the focus_out_event_cb
in the broken cases?
Assignee | ||
Comment 16•3 years ago
|
||
Do you mean focus_ot_event_cb => focus_in_event_cb ?
Assignee | ||
Comment 17•3 years ago
|
||
You can run firefox as:
WAYLAND_DEBUG=1 MOZ_LOG="Widget:5"
and you'll get wayland events and matching Gtk events from Firefox side.
Comment 18•3 years ago
|
||
I discovered a workaround for the drop failure case before Bug 1706452 broke Wayland, simply resize the window and d&d will start working again.
Comment 19•3 years ago
|
||
(In reply to Kestrel from comment #18)
I discovered a workaround for the drop failure case before Bug 1706452 broke Wayland, simply resize the window and d&d will start working again.
Hehe, yes that's exactly what this bug is about - things toggle between working and broken, see comment 0 :)
One more thing I just noticed: for each broken DnD action, there's message like this at the end:
nsRetrievalContextWayland(): leaked nsDataOffer ...
So it looks like we actually do get the offer somehow.
Comment 20•3 years ago
|
||
Martin, after some more digging, I increasingly believe what we run into here is actually what you described in https://phabricator.services.mozilla.com/D111072#3610528. Will check if this is maybe just a Mutter or Wayland bug.
The reason I do believe so is that both GTK and FF both register a wl_data_device_listener
- however, it looks like only one of them fires. If GTK gets it, things work, if FF gets it, it doesn't - as we now rely on GTK to handle DnD. It toggles just as the bug here, so it's likely that.
Comment 21•3 years ago
•
|
||
Oh my, found the issue.
TL;DR: bug 1703490 and bug 1706624 don't work without changing GTK API.
Long version:
In [1] we call wl_data_device_manager_get_data_device
. According to the Wayland spec[2], there are two important things here:
There is one wl_data_device per seat which can be obtained from the global wl_data_device_manager singleton.
and
wl_data_device_manager::get_data_device: Create a new data device for a given seat.
So if we use the seat form GTK, calling wl_data_device_manager_get_data_device
creates a second device, which according to spec is undefined behaviour - there should only be one, but now there are two. So Mutter weirdly toggles between them, while Weston strictly uses the last created one (arguably the better behaviour), so there DnD is completely broken atm.
There is a GTK API which would give us the GTK data device, so we can add our listeners to it: gdk_wayland_device_get_data_device
[3]. However, it's not public.
So I see a couple of options here:
- ask GTK devs to make
gdk_wayland_device_get_data_device
public, allowing us to have a mix of GTK managed DnD and FF managed clipboard - revert bug 1703490 and bug 1706624 and continue managing everything ourselves.
- investigate whether we can make the FF clipboard non-blocking and go fully GTK. This would be IMO the cleanest solution, letting us drop lots of code. But probably also the hardest one. I somewhere read that something like that is being worked on for JS clipboard functions - maybe by now it's somewhat feasible.
Martin, WDYT?
1: https://searchfox.org/mozilla-central/source/widget/gtk/nsClipboardWayland.cpp#499
2: https://wayland.freedesktop.org/docs/html/apa.html#protocol-spec-wl_data_device_manager
3: https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gdk/wayland/gdkdevice-wayland.c#L5448
Comment 22•3 years ago
•
|
||
Jonas, can I ask you also for an opinion about the above?
Assignee | ||
Comment 23•3 years ago
|
||
Thanks a lot Robert. We can't change Firefox clipboard API - it involves changes in MacOS/Windows backend and also JS side hacking which is complicated. I think we can go with:
- public gdk_wayland_device_get_data_device (use Gtk clipboard device)
- fixed mutter and use our own handlers
Comment 24•3 years ago
|
||
(In reply to Robert Mader [:rmader] from comment #21)
Even though modern clipboard APIs are async, the old web-exposed APIs that are sync are not going away unfortunately, yeah... You can technically fake the sync-ness by using a nested event loop, but that is also terrible for other reasons.
Reporter | ||
Updated•3 years ago
|
Comment 26•3 years ago
•
|
||
(In reply to Martin Stránský [:stransky] (ni? me) from comment #23)
- public gdk_wayland_device_get_data_device (use Gtk clipboard device)
Briefly tried this but it looks to me like a rabbit whole we shouldn't get into.
- fixed mutter and use our own handlers
Looking into this now. I'd hope we can keep bug 1706624 and only revert bug 1703490, but first need to clarify with Wayland folks how the spec should be understood.
Edit: got the bugs the wrong way around.
Comment 27•3 years ago
|
||
Typo: I meant keeping bug 1706624 and reverting bug 1703490
Comment 28•3 years ago
|
||
Martin, I think we should start with reverting bug 1703490. We can most likely keep bug 1706624, which IIUC helps a lot still. I have a Mutter patch cooking for the issue I mentioned above, but from a quick test it's not absolutely necessary.
Assignee | ||
Comment 29•3 years ago
|
||
Okay, requested revert at https://bugzilla.mozilla.org/show_bug.cgi?id=1703490#c4
If that fails we need to update the patch for latest tree.
Updated•3 years ago
|
Assignee | ||
Comment 31•3 years ago
|
||
Bug 1703490 was reverted so closing this one.
Comment 32•3 years ago
|
||
Fixed by backout.
Description
•