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 708337 - Double-clicking on network in Wi-Fi list doesn't work
Double-clicking on network in Wi-Fi list doesn't work
Status: RESOLVED OBSOLETE
Product: gnome-shell
Classification: Core
Component: general
3.22.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
triaged
: 783084 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-09-18 23:59 UTC by Bastien Nocera
Modified: 2021-07-05 14:33 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Wi-Fi list: connect to network on double-click (2.25 KB, patch)
2015-03-11 20:08 UTC, Isaac David
none Details | Review
Wi-Fi list: connect to network on double-click (2.16 KB, patch)
2015-03-19 04:22 UTC, Isaac David
needs-work Details | Review

Description Bastien Nocera 2013-09-18 23:59:47 UTC
gnome-shell 3.9.91

Double-clicking on a network inside the "Wi-Fi networks" dialogue should do the same as clicking it and then clicking the connect button.
Comment 1 Isaac David 2015-03-11 20:08:26 UTC
Created attachment 299128 [details] [review]
Wi-Fi list: connect to network on double-click

Add support for double-clicking on access points inside the
NetworkManager modal dialog. This commit changes NMWirelessDialog's
_selectNetwork() callback to fire the _connect() method when the
current and former selected networks match. To actually act on clicks
we need to stop relying on 'the key-focus-in' signal and move the
emission of a 'selected' signal right into the 'clicked' action
callback connected to NMWirelessDialogItem(s).

This doesn't take into account the time to double-click though,
which seems to be ingrained in the ClutterClickAction abstraction.
Comment 2 Isaac David 2015-03-11 20:19:25 UTC
We might want to ignore double clicks up to a certain speed, and ClutterClickAction doesn't seem to register 'clicked' events for fast double-clicks unless they happened on different coordinates (i.e. clicking while moving the cursor).

I'll try to prepare another patch using 'button-press-event' and 'button-released-event' instead of ClickAction. double_click_time from ClutterSettings might do it too.
Comment 3 Florian Müllner 2015-03-11 20:44:49 UTC
Review of attachment 299128 [details] [review]:

We definitively want a less-hacky solution here:

::: js/ui/status/network.js
@@ -659,3 @@
                                         reactive: true });
-        this.actor.connect('key-focus-in', Lang.bind(this, function() {
-            this.emit('selected');

This breaks keyboard navigation ...
Comment 4 Florian Müllner 2015-03-11 21:02:15 UTC
(In reply to Isaac David from comment #2)
> We might want to ignore double clicks up to a certain speed, and
> ClutterClickAction doesn't seem to register 'clicked' events for fast
> double-clicks unless they happened on different coordinates (i.e. clicking
> while moving the cursor).

That sounds like a bug that should get fixed.


> I'll try to prepare another patch using 'button-press-event' and
> 'button-released-event' instead of ClickAction.

Using one of them is probably fine, both will get tricky fairly quickly when you start handling sequences like button-1-press,button-2-press,button-2-release,button-1-release ...

Have you tried recording the time of the first click with Clutter.get_current_event_time() and use that in combination with ClutterSettings (or GtkSettings)?
Comment 5 Isaac David 2015-03-17 18:28:54 UTC
One more question: if using the button released event, do we want to track what button the event came from? I mean, is button-x-release followed by button-y-release a valid double click?

I coudln't find other double-click behaviours anywhere in the Shell.
Comment 6 Isaac David 2015-03-19 04:22:03 UTC
Created attachment 299781 [details] [review]
Wi-Fi list: connect to network on double-click

Add support for double-clicking on access points inside the
NetworkManager modal dialog. Use GtkSettings to honor the
time to double-click user preference.
Comment 7 Baurzhan M 2015-10-06 04:46:21 UTC
Hi, any updates on this issue?

Thanks,
Comment 8 Bastien Nocera 2016-10-28 14:52:08 UTC
Looks like this still applies correctly.
Comment 9 Baurzhan M 2016-12-07 07:29:44 UTC
We need to get it merged then.
Comment 10 Bastien Nocera 2016-12-07 12:59:50 UTC
(In reply to Baurzhan M from comment #9)
> We need to get it merged then.

We don't apply patches as soon as they apply correctly. Applying correctly is the minimum for the patch to be reviewed. We're at that step now.
Comment 11 Baurzhan M 2016-12-07 15:42:48 UTC
(In reply to Bastien Nocera from comment #10)
> (In reply to Baurzhan M from comment #9)
> > We need to get it merged then.
> 
> We don't apply patches as soon as they apply correctly. Applying correctly
> is the minimum for the patch to be reviewed. We're at that step now.

Hi,
I just built gnome-shell with this patch and it works in F25.
Comment 12 Florian Müllner 2016-12-07 16:37:59 UTC
(In reply to Florian Müllner from comment #4)
> (In reply to Isaac David from comment #2)
> > We might want to ignore double clicks up to a certain speed, and
> > ClutterClickAction doesn't seem to register 'clicked' events for fast
> > double-clicks unless they happened on different coordinates (i.e. clicking
> > while moving the cursor).
> 
> That sounds like a bug that should get fixed.

This comment still applies - "there's an issue with the high-level API, so I'm switching to the low-level one" isn't great, and throws away features the high-level API provides (like making sure that only press *and* release register as a click).
Comment 13 Bastien Nocera 2016-12-08 15:32:33 UTC
Review of attachment 299781 [details] [review]:

The best way to fix this would be to add double-click support to the clutter-click-action.c in mutter's clutter copy, and use that.
Comment 14 Florian Müllner 2017-05-25 14:01:33 UTC
*** Bug 783084 has been marked as a duplicate of this bug. ***
Comment 15 Marcin Zajaczkowski 2019-01-24 20:48:32 UTC
I thought gnome-shell migrated to GitLab for issue reporting, but I have only found https://gitlab.gnome.org/GNOME/gnome-shell/issues/296 - closed as a duplicated of that issue, not this one.

Could anyone point me the current issue in GitLab to comment and subscribe for notifications?
Comment 16 GNOME Infrastructure Team 2021-07-05 14:33:21 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of  gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a new ticket at
  https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/

Thank you for your understanding and your help.