GNOME Bugzilla – Bug 691764
Disable Bluetooth sharing with no Bluetooth
Last modified: 2013-01-28 18:00:39 UTC
Currently doesn't check that there is Bluetooth available. It should also be disabled if gnome-bluetooth isn't available. See the "default-adapter" and "default-adapter-powered" properties of BluetoothClient; http://developer.gnome.org/gnome-bluetooth/stable/BluetoothClient.html#BluetoothClient--default-adapter
Created attachment 233773 [details] [review] sharing: hide the bluetooth sharing when there is no bluetooth adapter
Review of attachment 233773 [details] [review]: ::: panels/sharing/cc-sharing-panel.c @@ +300,3 @@ + + if (killswitch_state == BLUETOOTH_KILLSWITCH_STATE_NO_ADAPTER + && !bluetooth_adapter) You can't have an adapter without a Bluetooth killswitch. It's a soft killswitch, but it's attached to every Bluetooth adapter. See the "rfkill" output (available at: http://git.sipsolutions.net/?p=rfkill.git)
Created attachment 234314 [details] [review] sharing: hide the bluetooth sharing when there is no bluetooth adapter
Review of attachment 234314 [details] [review]: ::: panels/sharing/cc-sharing-panel.c @@ +311,3 @@ +#ifdef HAVE_BLUETOOTH + + priv->bluetooth_killswitch = bluetooth_killswitch_new (); As mentioned on IRC, you should check the state here before connecting to the signal.
Modified version of the patch, which also gets the initial state, pushed as dbcffa5.