[gnome-control-center] power: conditionally display the bluetooth button



commit fda606c4f88154bf97814998a51fb22fdc1f42a7
Author: Antoine Jacoutot <ajacoutot gnome org>
Date:   Tue Oct 14 10:38:09 2014 +0200

    power: conditionally display the bluetooth button
    
    We do not want to display the bluetooth power option if we were built
    without bluetooth support; same way we do with NetworkManager.

 panels/power/cc-power-panel.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/panels/power/cc-power-panel.c b/panels/power/cc-power-panel.c
index 21d7022..6ef1208 100644
--- a/panels/power/cc-power-panel.c
+++ b/panels/power/cc-power-panel.c
@@ -1613,6 +1613,7 @@ add_power_saving_section (CcPowerPanel *self)
                     G_CALLBACK (wifi_switch_changed), self);
 #endif
 
+#ifdef HAVE_BLUETOOTH
   priv->bt_rfkill = g_dbus_proxy_new_for_bus_sync (G_BUS_TYPE_SESSION,
                                                   G_DBUS_PROXY_FLAGS_NONE,
                                                   NULL,
@@ -1654,6 +1655,7 @@ add_power_saving_section (CcPowerPanel *self)
       g_signal_connect (G_OBJECT (priv->bt_switch), "notify::active",
                        G_CALLBACK (bt_switch_changed), self);
     }
+#endif
 
   gtk_widget_show_all (widget);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]