After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 757439 - Middle click on folder in path bar causes hiding animation
Middle click on folder in path bar causes hiding animation
Status: RESOLVED FIXED
Product: nautilus
Classification: Core
Component: Path Bar
3.18.x
Other Linux
: Normal normal
: ---
Assigned To: Nautilus Maintainers
Nautilus Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-11-01 15:42 UTC by elias
Modified: 2017-06-19 10:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch for button_event_cb in pathbar (1.96 KB, patch)
2017-06-18 16:15 UTC, elias
none Details | Review
nautilus-pathbar: Handle middle click on button press (2.22 KB, patch)
2017-06-18 18:58 UTC, elias
none Details | Review
nautilus-pathbar: Handle middle click on button press (2.39 KB, patch)
2017-06-19 10:05 UTC, elias
committed Details | Review

Description elias 2015-11-01 15:42:48 UTC
If I middle click on the path bar, the folder opens in a new tab but there is also an animation to hide the window. Immediately after that the window appears again.
Comment 1 elias 2017-06-18 16:12:06 UTC
This only happens when "/org/gnome/desktop/wm/preferences/action-middle-click-titlebar" is set to "minimize".
Comment 2 elias 2017-06-18 16:15:21 UTC
Created attachment 353992 [details] [review]
Patch for button_event_cb in pathbar

This suggested change handles the middle click (like the right click) already on the button-press-event and not the button-release-event.
Comment 3 Carlos Soriano 2017-06-18 18:14:37 UTC
Review of attachment 353992 [details] [review]:

Code looks good! Can you write a proper commit message?

Some guidelines: https://wiki.gnome.org/Newcomers/SubmitPatch
Comment 4 Ernestas Kulik 2017-06-18 18:43:31 UTC
Review of attachment 353992 [details] [review]:

::: src/nautilus-pathbar.c
@@ +1534,3 @@
             return TRUE;
         }
+        else if (event->button == 2 && mask == 0)

Could you maybe use GDK_BUTTON_MIDDLE instead of the 2 there? It’s more readable that way.

@@ +1553,3 @@
         }
 
+        if (event->button == 1 && mask == GDK_CONTROL_MASK)

Same here, but GDK_BUTTON_PRIMARY.
Comment 5 elias 2017-06-18 18:58:30 UTC
Created attachment 353999 [details] [review]
nautilus-pathbar: Handle middle click on button press

I changed the numbers to gdk constants and added more explanation to the commit message.
Comment 6 Ernestas Kulik 2017-06-19 10:02:12 UTC
(In reply to elias from comment #5)
> Created attachment 353999 [details] [review] [review]
> nautilus-pathbar: Handle middle click on button press
> 
> I changed the numbers to gdk constants and added more explanation to the
> commit message.

I think you forgot to commit your changes. :p
Comment 7 elias 2017-06-19 10:05:52 UTC
Created attachment 354030 [details] [review]
nautilus-pathbar: Handle middle click on button press

This time with comitted changes...
Comment 8 Ernestas Kulik 2017-06-19 10:17:04 UTC
Review of attachment 354030 [details] [review]:

Looks good, thanks.
Comment 9 Ernestas Kulik 2017-06-19 10:20:00 UTC
Attachment 354030 [details] pushed as e671217 - pathbar: Handle middle click on button-press-event