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 662384 - Connection switches in Bluetooth menu are not functioning
Connection switches in Bluetooth menu are not functioning
Status: RESOLVED DUPLICATE of bug 663891
Product: gnome-shell
Classification: Core
Component: general
3.2.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2011-10-21 12:07 UTC by Alexander Hunziker
Modified: 2012-01-24 18:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix bluetooth connection from Gnome Shell's panel on 3.2.1 (1.42 KB, patch)
2011-12-13 09:49 UTC, Alessandro Crismani
none Details | Review

Description Alexander Hunziker 2011-10-21 12:07:35 UTC
I have a Bluetooth device paired with my Laptop (an A2DP sound device). Even when it is connected and active, the Bluetooth menu in gnome-shell shows the connection as "off". Likewise, when the device is not active, trying to activate is using the slider in the menu has no effect.
Comment 1 Milan Bouchet-Valat 2011-10-21 12:50:33 UTC
I guess you have the same problem with the Bluetooth control panel you can open by choosing Bluetooth settings in the menu? How do you activate Bluetooth ? via the hardware switch ?
Comment 2 Alexander Hunziker 2011-10-21 13:58:47 UTC
No, g-c-c always shows the connection status correctly and also allows me to turn on and off. I always have my BT running, I don't use the HW switch.
Comment 3 Milan Bouchet-Valat 2011-10-21 20:24:08 UTC
So that's really a bug in the Shell. Could you try enabling the Bluetooth via the slider in the menu, and then attach here your ~/.xsession-errors file?
Comment 4 Nicolas Chaigneau 2011-10-25 23:44:15 UTC
I 'm affected  too by this bug with an A2DP sound device in Gnome-Shell. I can only manage connection at this device from the bluetooth wizard ; not with the slider in the menu : the slider may move and rest in the two states (connection off or on) but has no effect on the bluetooth connection.
Manipulating the slider leaves no entry in my xsession-errors file.
Comment 5 Alessandro Crismani 2011-12-12 08:51:17 UTC
Me too, can't connect to a pair of bluetooth headphones using GS's panel menu. Using g-c-c works as expected and I can connect and disconnect the headphones.

The relevant part of .xsession-errors is


    JS ERROR: !!!   Exception in callback for signal: toggled
    JS ERROR: !!!     message = '"menuitem is not defined"'
    JS ERROR: !!!     lineNumber = '230'
    JS ERROR: !!!     fileName = '"/usr/share/gnome-shell/js/ui/status/bluetooth.js"'
    JS ERROR: !!!     stack = '"([object Object],true)@/usr/share/gnome-shell/js/ui/status/bluetooth.js:230
_emit("toggled",true)@/usr/share/gjs-1.0/signals.js:124
()@/usr/share/gnome-shell/js/ui/popupMenu.js:796
([object _private_Clutter_Event])@/usr/share/gnome-shell/js/ui/popupMenu.js:788
([object _private_Shell_GenericContainer],[object _private_Clutter_Event])@/usr/share/gnome-shell/js/ui/popupMenu.js:81
"'

This is on Arch Linux - Gnome 3.2.1
Comment 6 Alessandro Crismani 2011-12-13 09:49:37 UTC
Created attachment 203325 [details] [review]
Fix bluetooth connection from Gnome Shell's panel on 3.2.1

The error from .xsession-errors is due to an undefined menuitem in js/ui/bluetooth.js:_buildDeviceSubMenu. The simple patch attached fixes it and works on my laptop running Gnome 3.2.1.

I am not sure if patches for Gnome 3.2.1 are welcomed, but I though that this simple one won't kill a cat and hence I uploaded it. Can anybody experiencing this problem try it on Gnome 3.2.1?

Please note that js/ui/bluetooth.js as of master already does the right thing and should work :)
Comment 7 Xavier Poirot 2012-01-23 10:16:06 UTC
Still getting the same bug, using gnome-shell 3.2.2

Same output as before, almost:
    JS ERROR: !!!   Exception in callback for signal: toggled
    JS ERROR: !!!     message = '"menuitem is not defined"'
    JS ERROR: !!!     lineNumber = '213'
    JS ERROR: !!!     fileName = '"/usr/share/gnome-shell/js/ui/status/bluetooth.js"'
    JS ERROR: !!!     stack = '"([object Object],true)@/usr/share/gnome-shell/js/ui/status/bluetooth.js:213
_emit("toggled",true)@/usr/share/gjs-1.0/signals.js:124
()@/usr/share/gnome-shell/js/ui/popupMenu.js:796
([object _private_Clutter_Event])@/usr/share/gnome-shell/js/ui/popupMenu.js:788
([object _private_Shell_GenericContainer],[object _private_Clutter_Event])@/usr/share/gnome-shell/js/ui/popupMenu.js:81


Archlinux - Gnome 3.2.2
Comment 8 Alessandro Crismani 2012-01-23 10:21:06 UTC
It wasn't fixed in 3.2.2. Try using the simple patch in the previous comment, it should work. I patched the file manually after having updated Gnome Shell and I have a working bluetooth menu in the panel, it is a matter of editing /usr/share/gnome-shell/js/ui/status/bluetooth.js and changing one line.
Comment 9 Xavier Poirot 2012-01-23 16:02:01 UTC
Have you tried committing it in the source code and not only here in the Bugzilla?
Comment 10 Jasper St. Pierre (not reading bugmail) 2012-01-23 16:11:35 UTC
The patch is in git, it just wasn't backported for 3.2.2.
Comment 11 Owen Taylor 2012-01-24 18:36:19 UTC
Fixed in git master - would have backported to 3.2.2 if I had noticed the proposal, but at this point I'm not expecting to do a 3.2.3

*** This bug has been marked as a duplicate of bug 663891 ***