Open Bug 1922592 Opened 1 year ago Updated 1 year ago

Dragging a tab (for drag-and-drop) randomly fails as of Firefox 131, possibly confused by the new tooltips / hover preview

Categories

(Firefox :: Tabbed Browser, defect, P3)

Firefox 131
defect

Tracking

()

UNCONFIRMED

People

(Reporter: vincent-moz, Unassigned)

References

(Blocks 1 open bug)

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:131.0) Gecko/20100101 Firefox/131.0

Steps to reproduce:

  1. Open Firefox 131 with tabs in a window.
  2. Put the mouse pointer over a tab.
  3. Once the tooltip (tab title + host) appears (which is almost immediate), try to drag the tab.

Actual results:

Sometimes, nothing happens, as if Firefox did not notice that the left button was pressed. Sometimes, same issue, except that a black rectangle appears. It seems that this black rectangle has about the same dimensions as the preview when a preview appears (I sometimes get a preview, but this is not always the case and I don't know why).

Expected results:

The tab should be dragged.

Note: When the issue occurs, a solution that always seems to work is to drag the tab before the tooltip appears, but this is rather difficult as one needs to be fast.

The Bugbug bot thinks this bug should belong to the 'Firefox::Tabbed Browser' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Tabbed Browser

And sometimes, it is possible to drag a tab, but only in the same tab bar (in particular, not to a tab bar of another Firefox window),

Actually it seems that one can move a tab only toward the right (but this does not work if one tries to move it toward the left first). After the initial move, there does not seem to be any restriction. So, in short, if one wants to move a tab leftward, one first needs to move it a bit toward the right, then backward to the left.

But this does not work for the rightmost tab. So, for this case, one first needs to move the tab at its left to the rightmost position.

(In reply to Vincent Lefevre from comment #3)

But this does not work for the rightmost tab. So, for this case, one first needs to move the tab at its left to the rightmost position.

Well, dragging the rightmost tab seems to work if done when the tooltip is not present, i.e. either before it appears (one needs to be quick enough) or by making it disappear with the Esc key.

I'm not sure, though, because after some time, it seems that the issue no longer appears for a while. There seems to be randomness in the behavior.

Summary: Drag-and-drop of tabs does not always work once the tooltip appears → Dragging a tab (for drag-and-drop) randomly fails as of Firefox 131, possibly confused by the new tooltips / hover preview

The severity field is not set for this bug.
:mconley, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(mconley)

Hey DJ, is there a good metabug to connect this to for tab previews?

Severity: -- → S4
Flags: needinfo?(mconley) → needinfo?(dwalker)
Priority: -- → P3

I just added the tab-preview alias to bug 1848157, we can track bugs there

Blocks: tab-preview
Flags: needinfo?(dwalker)

(In reply to Vincent Lefevre from comment #4)

Well, dragging the rightmost tab seems to work if done when the tooltip is not present, i.e. either before it appears (one needs to be quick enough) or by making it disappear with the Esc key.

I've been seeing what I think is this bug: if I try to drag a tab while the preview popup is displayed, it doesn't start a drag operation. The failed drag does dismiss the popup, for as long as the pointer stays inside the tab; clicking the tab without dragging doesn't do that. Dismissing the popup first (in that way or with the Esc key) or starting the drag quickly enough works. This all seems to be 100% reliably reproducible for me.

This is on Linux, X11, FVWM, focus-follows-mouse. It doesn't reproduce on an Ubuntu VM using GNOME/Wayland. I suspect that this bug belongs in the Widget:Gtk component; there have been issues with popups and input focus before and this might be another one.

(In reply to Vincent Lefevre from comment #3)

After the initial move, there does not seem to be any restriction.

Make sure you aren't dragging tabs from the icon which is known to not work for unloaded tabs (Bug 1930931).

See Also: → 1930931

(In reply to Kestrel from comment #9)

(In reply to Vincent Lefevre from comment #3)

After the initial move, there does not seem to be any restriction.

Make sure you aren't dragging tabs from the icon which is known to not work for unloaded tabs (Bug 1930931).

Once the tooltip has been dismissed, I no longer have any issue to move tabs leftward.

There seems to be 3 ways to dismiss a popup:

  • the Esc key;
  • starting a drag (which fails, but dismisses the popup anyway, as said in comment #8);
  • a click on a tab when the tab is not the current one (for the current tab, a click on it without dragging doesn't dismiss the popup, as said in comment #8).

(In reply to Jed Davis [:jld] ⟨⏰|UTC-8⟩ ⟦he/him⟧ from comment #8)

This is on Linux, X11, FVWM, focus-follows-mouse. It doesn't reproduce on an Ubuntu VM using GNOME/Wayland. I suspect that this bug belongs in the Widget:Gtk component; there have been issues with popups and input focus before and this might be another one.

Yes, bug 1820542 was a bit similar.

Hello! Thank you for submitting this issue I have tried to reproduce the issue on my end but unfortunately I wasn't able to with firefox 137.0a1(2025-02-27), 131.0.3 and 133.0a1(2024-10-03) on Ubuntu 22.04 on Wayland and X11
Could you please answer the following questions in order to further investigate this issue?

  1. Does this issue happen with a new profile? Here is a link on how to create one: https://support.mozilla.org/en-US/kb/profile-manager-create-remove-switch-firefox-profiles
  2. Does this issue happen in the latest nightly? Here is a link from where you can download it: https://www.mozilla.org/en-US/firefox/channel/desktop/
  3. Do you have any addons installed? If yes could you please list them?
Flags: needinfo?(vincent-moz)

In about:config, try changing browser.tabs.hoverPreview.enabled = false and see if it still happens.

Also try changing nglayout.enable_drag_images = false which is known to interfere with tab dragging (Bug 1844373).

See Also: → 1844373

I'm currently using 135.0.1, and I've noticed that the behavior has improved (I don't know when it changed exactly): now, the drag fails only if I want to move the current tab (for this one, there is no preview, probably because the contents are visible in the window). Same behavior with a new profile (thus without addons).

(In reply to Kestrel from comment #13)

In about:config, try changing browser.tabs.hoverPreview.enabled = false and see if it still happens.

If I set this to false, the issue disappears: tab dragging always works. This is strange, because there is no preview on the current tab, even when this preference is set to true.

Also try changing nglayout.enable_drag_images = false which is known to interfere with tab dragging (Bug 1844373).

For this one, this does not change anything: dragging the current tab still fails.

I could try Nightly later, if need be.

Flags: needinfo?(vincent-moz)

(In reply to Negritas Sergiu, Desktop QA from comment #12)

  1. Does this issue happen in the latest nightly?

Yes, it also occurs with 137.0a1 (2025-02-28). Same behavior as with 135.0.1.

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