Long press on history action button is broken
Submitted by Theo Linkspfeifer
Assigned to Xfce Bug Triage
Description
The popup menu does not appear when pressing and holding the left button on either "<-" or "->
" in the location bar.
$ thunar
(thunar:9275): Gtk-WARNING **: 23:33:35.434: no trigger event for menu popup
(thunar:9275): Gtk-CRITICAL **: 23:33:35.434: gtk_menu_popup_at_rect: assertion 'GDK_IS_WINDOW (rect_window)' failed
Version: git
Designs
- Show closed items
Activity
-
Newest first Oldest first
-
Show all activity Show comments only Show history only
- Author
Alexander Schwinn@alexxcons
said:Interesting, did not know that it existed :) .. probably broke during gtk3 port.
Fix should be done after https://github.com/andreldm/thunar/tree/ReplaceGtkAction got merged .. since I messed with the History Actions. (Or now, directly on the "ReplaceGtkAction" branch)
- Author
- Author
Theo Linkspfeifer submitted a patch:The functionality is gone when compiling Thunar from the linked branch. No more popup on left-click (long press) or right-click.
The attached diff fixes the bug in git master.
Patch 9647, "diff":
bug16601.diff - Author
Alexander Schwinn@alexxcons
said:thunar-history-action.c does not exist any more in the "ReplaceGtkAction" branch ... I'll rather see how to fix that in the branch, instead of adding dtuff to master which anyhow will be replaced soon.
- Author
Alexander Schwinn@alexxcons
said:Probably can be done by listening to "button-release-event" and checking the event->time in the handler (struct GdkEventButton) Its in thunar-window.c:750 and thunar-window.c:3690
Rebased, most recent version of the WIP branch: https://github.com/alexxcons/thunar/tree/ReplaceGtkAction2
- Author
Theo Linkspfeifer said:Does this mean that the bug will stay unfixed in 1.8?
- Author
Alexander Schwinn@alexxcons
said:(In reply to Theo Linkspfeifer from comment 6)
Does this mean that the bug will stay unfixed in 1.8?
Uh, true, completely forgot about 4.14 for this one.
Though I will wait until there is as well a solution for master. I dont want to re-introduce the feature on 4.14 if that could introduce a regression for master.
- Author
Alexander Schwinn@alexxcons
said:(In reply to Theo Linkspfeifer from comment 3)
Created attachment 9647 [details] diff
The functionality is gone when compiling Thunar from the linked branch. No more popup on left-click (long press) or right-click.
Popup on right-click is fixed in the most recent branch: https://github.com/alexxcons/thunar/tree/ReplaceGtkAction45 Though so far no support for long press in the WIP branch
- Alexander Schwinn added 1. Regression 5. History labels
added 1. Regression 5. History labels
- Developer
Probably can be done by listening to "button-release-event" and checking the event->time in the handler (struct GdkEventButton)
Ideally, the menu should be triggered without the need to release the button (long press).
- Theo Linkspfeifer mentioned in issue #642 (closed)
mentioned in issue #642 (closed)
- Developer
Just taking notes...
Nemo: https://github.com/linuxmint/nemo/blob/master/src/nemo-navigation-action.c
Extend
thunar_window_history_clicked
with something likeschedule_menu_popup_timeout
andunschedule_menu_popup_timeout
from the linked code. - Developer
Is there any reason to implement this, other than "it used to work"? Are there input devices where right-click is unavailable?
- Maintainer
I suppose @SKefalidis is right, we have the functionality already on right-click, and besides you, nobody seems to miss the long-press.
So if you dont have a special use-case, I would just drop the feature and close the issue.
- Developer
It works that way in various other file managers and even in Mozilla Firefox. Since the functionality would only add few lines of code, why not simply reimplement it?
- Developer
The only reason for the existence of this feature that I can think of is touchscreen displays.
Anyway, if we decide that we want Thunar to have that we shouldn't follow Nemo's example, since they haven't actually touched it at all. Instead, it should be developed using https://docs.gtk.org/gtk3/class.GestureLongPress.html. This should be both cleaner and shorter (as seen in https://github.com/GNOME/nautilus/commit/eed53461de1c5b39c11dcef05766fbf8875e99cf).
- Maintainer
It works that way in various other file managers and even in Mozilla Firefox.
Hmm, ok, seems to be available in nautilus, nemo and dolphin so some kind of quasi-standard. (caja and PCManFM dont have it)
Agreed that it rather should be done via GestureLongPress.