Bug 269525 - x11-wm/twm: www/firefox dropdown menus close when mouse is moved
Summary: x11-wm/twm: www/firefox dropdown menus close when mouse is moved
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-x11 (Nobody)
URL: https://www.freshports.org/x11-wm/twm/
Keywords: needs-qa
Depends on:
Blocks:
 
Reported: 2023-02-13 06:10 UTC by rzdndr
Modified: 2023-04-09 08:47 UTC (History)
6 users (show)

See Also:
fernape: maintainer-feedback? (gecko)
grahamperrin: maintainer-feedback? (x11)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description rzdndr 2023-02-13 06:10:40 UTC
OS: FreeBSD, 13.1-RELEASE, FreeBSD 13.1-RELEASE, releng/13.1-n250148-fc952ac2212, GENERIC, amd64

Firefox: from package firefox-110.0,2

Problem: You can not click on any firefox menu item (for example "About Firefox" in the Help menu), or on any item in a folder in the bookmarks toolbar. You can click and open the bookmarks folder to see the links inside the folder, or the menu items in the firefox menu. As soon as the mouse is moved, the menu, or the bookmarks folder is closed, and you can not choose a menu item or link in a bookmarks folder.
Comment 1 Christoph Moench-Tegeder freebsd_committer freebsd_triage 2023-02-13 20:30:32 UTC
Could be related to https://bugzilla.mozilla.org/show_bug.cgi?id=1807482 ? Also not reproducable here.
Comment 2 rzdndr 2023-02-14 04:12:12 UTC
(In reply to Christoph Moench-Tegeder from comment #1)

What WM are you using? I am using TWM as the window manager.
Comment 3 Christoph Moench-Tegeder freebsd_committer freebsd_triage 2023-02-14 23:03:38 UTC
(In reply to rzdndr from comment #2)
I'm on fvwm2
Comment 4 Tatsuki Makino 2023-02-16 06:25:49 UTC
It does not seem to be a problem with my 
firefox-esr-102.8.0_1,1 + twm-1.0.12 + not wayland + 12.4-STABLE amd64.
Perhaps it is a problem with firefox-110

(In reply to rzdndr from comment #2)

Does it still happen when using the default settings for twm? The green one :)
I have NoGrabServer written in my settings, but I forget if this was relevant :)
Comment 5 rzdndr 2023-02-16 07:14:45 UTC
(In reply to Tatsuki Makino from comment #4)

It is definitely related to firefox 110.0

What I did is add "export XDG_SESSION_DESKTOP=twm" into my .xinitrc
file. This was given as a solution given in the bug report in  https://bugzilla.mozilla.org/show_bug.cgi?id=1807482. This solved the problem
and I can use the dropdown menus, most of the time. Sometimes it gets stuck in one of the sub folders in the bookmarks toolbar, and does not understand the mouse moved, but you can close the sub folger with esc at those times. I do not know if this might be a bug (in firefox).

Did not test it with the default TWM configuration (the green one). Maybe I should test that too.

The NoGrabServer settings did not do anything on my system. This might not be relevant. I did check that though.
Comment 6 rzdndr 2023-02-16 07:20:12 UTC
I did also test it with the default TWM configuration (with the green color). This did not make any difference. Firefox has the same problem.

The solution that I have found for now is to export XDG_SESSION_DESKTOP=twm in my .xinitrc file.
Comment 7 Tatsuki Makino 2023-02-16 08:41:09 UTC
(In reply to rzdndr from comment #6)

> XDG_SESSION_DESKTOP=twm

Between firefox-102.8.0 and 110.0, the code of nsWindow::CaptureRollupEvents in ${WRKSRC}/widget/gtk/nsWindow.cpp was rewritten significantly...
It seems that twm, sawfish and fvwm have to tell firefox what type of window manager to use to cause this malfunction.
The pathways that tell it are the environment variables XDG_CURRENT_DESKTOP, XDG_SESSION_DESKTOP, and DESKTOP_SESSION, which GetDesktopEnvironmentIdentifier() in ${WRKSRC}/widget/gtk/WidgetUtilsGtk.cpp seems to pick up.

Thus, setting it up at all times seems to be a workaround for twm users.
Comment 8 Tatsuki Makino 2023-04-09 03:46:55 UTC
112.0 (and 111) still have this problem.

The following operations are workarounds without changing the settings.

Down the mouse button on the button that displays the drop-down.
Move the mouse over the drop-down that is displayed.
Up the mouse button.
Move the mouse so that it does not extend outside the drop-down and click.
Comment 9 Graham Perrin freebsd_committer freebsd_triage 2023-04-09 08:47:13 UTC
Packages from latest, or quarterly? 

pkg -vv | grep -e url -e enabled -e priority


(In reply to rzdndr from comment #0)

> OS: FreeBSD, 13.1-RELEASE, FreeBSD 13.1-RELEASE, 
> releng/13.1-n250148-fc952ac2212, GENERIC, amd64

That's significantly outdated (around eleven months old), patches have not been applied. 

Please freebsd-update(8) to either: 

a) update  to 13.1-RELEASE-p7; or

b) upgrade to 13.2-RELEASE. 

I recommend the latter.