[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [plasma-nm] /: Fix build with ModemManager disabled.
From:       Elias Probst <mail () eliasprobst ! eu>
Date:       2014-11-30 19:41:09
Message-ID: E1XvAMn-0001oG-6D () scm ! kde ! org
[Download RAW message or body]

Git commit d88f70e27c2f769b555ee5406b4ccaffc35c9d3b by Elias Probst.
Committed on 30/11/2014 at 19:40.
Pushed by eliasp into branch 'master'.

Fix build with ModemManager disabled.

M  +2    -0    kded/monitor.h
M  +6    -0    libs/handler.cpp
M  +6    -0    libs/handler.h

http://commits.kde.org/plasma-nm/d88f70e27c2f769b555ee5406b4ccaffc35c9d3b

diff --git a/kded/monitor.h b/kded/monitor.h
index e47cff7..ae89d3e 100644
--- a/kded/monitor.h
+++ b/kded/monitor.h
@@ -25,7 +25,9 @@
 #include <QDBusPendingCallWatcher>
 
 #include "bluetoothmonitor.h"
+#if WITH_MODEMMANAGER_SUPPORT
 #include "modemmonitor.h"
+#endif
 #include <config.h>
 
 class Q_DECL_EXPORT Monitor : public QObject
diff --git a/libs/handler.cpp b/libs/handler.cpp
index 63f605e..78e96dd 100644
--- a/libs/handler.cpp
+++ b/libs/handler.cpp
@@ -35,8 +35,10 @@
 #include <NetworkManagerQt/WirelessSetting>
 #include <NetworkManagerQt/ActiveConnection>
 
+#if WITH_MODEMMANAGER_SUPPORT
 #include <ModemManagerQt/Manager>
 #include <ModemManagerQt/ModemDevice>
+#endif
 
 #include <QDBusError>
 #include <QIcon>
@@ -98,6 +100,7 @@ void Handler::activateConnection(const QString& connection, const \
QString& devic  }
     }
 
+#if WITH_MODEMMANAGER_SUPPORT
     if (con->settings()->connectionType() == \
                NetworkManager::ConnectionSettings::Gsm) {
         NetworkManager::ModemDevice::Ptr nmModemDevice = \
NetworkManager::findNetworkInterface(device).objectCast<NetworkManager::ModemDevice>();
  if (nmModemDevice) {
@@ -116,6 +119,7 @@ void Handler::activateConnection(const QString& connection, const \
QString& devic  }
         }
     }
+#endif
 
     QDBusPendingReply<QDBusObjectPath> reply = \
                NetworkManager::activateConnection(connection, device, \
                specificObject);
     QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(reply, this);
@@ -505,9 +509,11 @@ void Handler::replyFinished(QDBusPendingCallWatcher * watcher)
     watcher->deleteLater();
 }
 
+#if WITH_MODEMMANAGER_SUPPORT
 void Handler::unlockRequiredChanged(MMModemLock modemLock)
 {
     if (modemLock == MM_MODEM_LOCK_NONE) {
         activateConnection(m_tmpConnectionPath, m_tmpDevicePath, m_tmpSpecificPath);
     }
 }
+#endif
diff --git a/libs/handler.h b/libs/handler.h
index e7a5c9b..f792a93 100644
--- a/libs/handler.h
+++ b/libs/handler.h
@@ -24,7 +24,9 @@
 #include <QDBusInterface>
 
 #include <NetworkManagerQt/Connection>
+#if WITH_MODEMMANAGER_SUPPORT
 #include <ModemManagerQt/GenericTypes>
+#endif
 
 #include <config.h>
 
@@ -110,14 +112,18 @@ public Q_SLOTS:
 private Q_SLOTS:
     void initKdedModule();
     void replyFinished(QDBusPendingCallWatcher * watcher);
+#if WITH_MODEMMANAGER_SUPPORT
     void unlockRequiredChanged(MMModemLock modemLock);
+#endif
 
 private:
     bool m_tmpBluetoothEnabled;
     bool m_tmpWimaxEnabled;
     bool m_tmpWirelessEnabled;
     bool m_tmpWwanEnabled;
+#if WITH_MODEMMANAGER_SUPPORT
     QString m_tmpConnectionPath;
+#endif
     QString m_tmpConnectionUuid;
     QString m_tmpDevicePath;
     QString m_tmpSpecificPath;


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic