Closed Bug 1978847 Opened 1 year ago Closed 1 year ago

Unable to drag/move tabs in horizontal or vertical tab bar

Categories

(Core :: Widget: Gtk, defect)

Firefox 141
defect

Tracking

()

RESOLVED INVALID

People

(Reporter: alexander.kempen, Unassigned)

Details

Attachments

(1 file)

Attached file about_support.txt —

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

Steps to reproduce:

Every time I try to drag a tab to a new position in the horizontal or vertical tab bar, Firefox opens it in a new window instead of repositioning it in the bar.

The issue started with version 140.

Tested this with a completely new profile with firefox -P test and firefox --safe-mode, on 3 different computers, it only happens on a Thinkpad X1 Tablet Gen. 2 (Intel i5-7Y54/HD Graphics 615), dragging tabs works just fine on a Thinkpad T14 Gen. 2 (Intel i5-1145G7) or Fujitsu Lifebook U7412 (Intel i5-1235U). All tested systems have the exact same software/updates installed.

ArchLinux
Wayland/sway 1.11
wlroots 0.19
firefox 140/141.0

I'm happy to help in any way I can.

Actual results:

As soon as I try to move a tab to a new position in the tab bar it instantly gets opened in a new window.

Expected results:

I should be able to drag tabs to a new position in either the horizontal or vertical tab bar.

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

Component: Untriaged → Widget: Gtk
Product: Firefox → Core

Could you attach a log of Firefox with the environment variable MOZ_LOG=WidgetDrag:5?

Flags: needinfo?(alexander.kempen)

(In reply to Thinker Li [:sinker] from comment #2)

Could you attach a log of Firefox with the environment variable MOZ_LOG=WidgetDrag:5?

Here you go. If you have anything I could try to figure out whats happening here, I'm happy to help.

Opened Firefox, tried dragging a tab one time and quit.

% MOZ_LOG=WidgetDrag:5 firefox -P test                                          
MOZ_LOG=WidgetDrag:5 firefox -P test                                                                                                                                                                                                                                            [15:34:54]
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::nsDragSession()
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::InvokeDragSession
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::InvokeDragSessionImpl
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::EndDragSessionImpl(0) 1
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::Observe("quit-application")
[Parent 188516: Main Thread]: D/WidgetDrag [D 0][7f4ead15d600] nsDragSession::~nsDragSession
Flags: needinfo?(alexander.kempen)
Severity: -- → S2

Hi Alexander, thank you for the log. However, could you do the test again with MOZ_LOG="WidgetDrag:5,WidgetDragService:5"?

Flags: needinfo?(alexander.kempen)

(In reply to Thinker Li [:sinker] from comment #4)

Hi Alexander, thank you for the log. However, could you do the test again with MOZ_LOG="WidgetDrag:5,WidgetDragService:5"?

No, thank you for your help!

MOZ_LOG="WidgetDrag:5,WidgetDragService:5" firefox -P test
[Parent 219874: Main Thread]: D/WidgetDragService [7f537cce0fb0] nsBaseDragService
[Child 219959: Main Thread]: D/WidgetDragService [7f37b82a2c40] nsBaseDragService
[Child 219959: Main Thread]: D/WidgetDragService [7f37b82a2c40] nsDragServiceProxy
[Child 220033: Main Thread]: D/WidgetDragService [7f37b9764470] nsBaseDragService
[Child 220033: Main Thread]: D/WidgetDragService [7f37b9764470] nsDragServiceProxy
[Parent 219874: Main Thread]: I/WidgetDragService [7f537cce0fb0] InvokeDragSessionWithImage | aDragEvent: 7f5372cafa80 | aDataTransfer: 7f5360be4b80 | mSuppressLevel: 0
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] nsBaseDragSession
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::nsDragSession()
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::InvokeDragSession
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] InvokeDragSession | aWidget: 7f537edf4700 | aDOMNode: 7f537ead4f00 | aPrincipal: 0 | aCsp: 0 | aCookieJarSettings: 0 | aTransferableArray: 7f5372af28a0 | aActiontype: 7 | aContentPolicyType: 37
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::InvokeDragSessionImpl
[Parent 219874: Main Thread]: E/WidgetDragService [7f5360a0e800] InvokeDragSession | rv: NS_ERROR_FAILURE(2147500037) | Ending drag session due to internal error
[Parent 219874: Main Thread]: I/WidgetDragService [7f5360a0e800] EndDragSession | aDoneDrag: true | aKeyModifiers: 0 | Ending drag session now
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::EndDragSessionImpl(0) 1
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] EndDragSessionImpl | aDoneDrag: true | aKeyModifiers: 0 | mDoingDrag true
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] FireDragEventAtSource | mSourceNode: 7f537ead4f00 | mSourceDocument: 7f53adcbe900 | mSuppressLevel: 0 | presShell: 7f537e9bf000
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] DiscardInternalTransferData | Discarded non-OTHER transfer items.
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::Observe("quit-application")
[Parent 219874: Main Thread]: D/WidgetDrag [D 0][7f5360a0e800] nsDragSession::~nsDragSession
[Parent 219874: Main Thread]: D/WidgetDragService [7f5360a0e800] ~nsBaseDragSession
[Parent 219874: Main Thread]: D/WidgetDragService [7f537cce0fb0] ~nsBaseDragService
Flags: needinfo?(alexander.kempen)

InvokeDragSession | rv: NS_ERROR_FAILURE(2147500037) should be caused by the line [1]. It looks like that gtk and Wayland/sway doesn't work well. What is the version of gtk you installed? Gtk may miss some events.

[1] https://searchfox.org/mozilla-central/rev/488c0c38dbe349a068bb72bc8b67905038826c66/widget/gtk/nsDragService.cpp#793

OK, that's strange. Like I said, I tested this on 3 different systems running on the same versions, this issue only occurs on one of them.

They're all currently using gtk3 3.24.49.

OK, I've done some extra testing and this only happens on systems with multiple seats configured (seat0 and tablet0 in my case).

% swaymsg -t get_seats
Seat: tablet0
  Capabilities: 5
  Devices:
    Wacom HID 5115 Pen
    Wacom HID 5115 Finger

Seat: seat0
  Capabilities: 3
  Devices:
    Logitech MX Keys
    Logitech MX Keys
    Logitech MX Master 2S
    Logitech MX Master 2S
    SONiX USB DEVICE Keyboard
    SONiX USB DEVICE Keyboard
    SONiX USB DEVICE
    ThinkPad Extra Buttons
    AT Translated Set 2 keyboard
    Intel HID 5 button array
    Intel HID events
    Intel Virtual Switches
    Intel Virtual Buttons
    PRIMAX ThinkPad X1 Tablet Thin Keyboard Gen 2
    PRIMAX ThinkPad X1 Tablet Thin Keyboard Gen 2
    PRIMAX ThinkPad X1 Tablet Thin Keyboard Gen 2
    PRIMAX ThinkPad X1 Tablet Thin Keyboard Gen 2
    PRIMAX ThinkPad X1 Tablet Thin Keyboard Gen 2
    Sleep Button
    Lid Switch
    Power Button
    Video Bus

If I start sway with only 1 seat(the default seat0) configured, dragging/moving tabs in Firefox works, as soon as I add the second seat and restart Firefox I can no longer drag/move tabs.

Any ideas how I could debug this properly? Doesn't Firefox attach to all seats by default? It definitely used to work in previous versions.

You can disregard this issue. This seems to have been my fault.

I had drag "disabled" set for input type:touch which is supposed to disable dragging for all devices of type touch. The goal was to stop touch inputs from moving tabs around by accident.

Apparently the setting breaks dragging for all input types, not just touch. I'm closing this as INVALID and reporting the issue to sway/wlroots.

Thank you for your help!

Status: UNCONFIRMED → RESOLVED
Closed: 1 year ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: