File r1047612-hide-wireless-no-hardware.diff of Package NetworkManager-kde4

Index: monolithic/knetworkmanagertrayicon.cpp
===================================================================
--- monolithic/knetworkmanagertrayicon.cpp	(revision 1047611)
+++ monolithic/knetworkmanagertrayicon.cpp	(revision 1047612)
@@ -310,7 +310,8 @@
 
     // add the housekeeping actions
     contextMenu()->addSeparator();
-    if (d->interfaceTypes.testFlag(Solid::Control::NetworkInterface::Ieee80211)) {
+
+    if (!wirelessDeviceUnis.isEmpty() /*TODO Bluetooth too */ && d->interfaceTypes.testFlag(Solid::Control::NetworkInterface::Ieee80211)) {
         contextMenu()->addAction(d->flightModeAction);
     }
     contextMenu()->addAction(d->prefsAction);
openSUSE Build Service is sponsored by