[PC-BSD Commits] r7746 - pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager

svn at pcbsd.org svn at pcbsd.org
Fri Oct 8 07:57:35 PDT 2010


Author: kris
Date: 2010-10-08 07:57:35 -0700 (Fri, 08 Oct 2010)
New Revision: 7746

Modified:
   pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.cpp
   pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.h
Log:

Added /dev/cua* devices to PPPOE config



Modified: pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.cpp
===================================================================
--- pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.cpp	2010-10-08 12:50:21 UTC (rev 7745)
+++ pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.cpp	2010-10-08 14:57:35 UTC (rev 7746)
@@ -10,9 +10,10 @@
 ** destructor.
 *****************************************************************************/
 #include <iostream>
+#include <QDir>
 #include <QFile>
 #include <QTemporaryFile>
-#include <qtextstream.h>
+#include <QTextStream>
 #include "networkman.h"
 #include "ui_networkman.h"
 #include <pcbsd-netif.h>
@@ -223,8 +224,24 @@
     textGlobalError->setText("");
     refreshDevices();
     DevSelectionChanged();
+
+    // Add any additional PPPOE devices
+    otherPPPOEDevs();
+
 }
 
+// Look for /dev/cua* devices
+void NetworkMan::otherPPPOEDevs()
+{
+    // Get listing of additional /dev/cua devices
+    QDir dir("/dev");
+
+    dir.setFilter(QDir::Files | QDir::NoDotAndDotDot | QDir::System );
+    QStringList list = dir.entryList(QStringList() << "cua*");
+    for (int i = 0; i < list.size(); ++i)
+       comboPPPOEDev->addItem(list.at(i));
+}
+
 // Function which locates the parent device of a wlan child device
 QString NetworkMan::getWifiParent(QString dev)
 {  

Modified: pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.h
===================================================================
--- pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.h	2010-10-08 12:50:21 UTC (rev 7745)
+++ pcbsd/current/src-qt4/pc-netmanager/src/NetworkManager/networkman.h	2010-10-08 14:57:35 UTC (rev 7746)
@@ -85,12 +85,15 @@
     QString getUpStatusForIdent( QString ident );
     QString getNextAvailWlan();
     QString getWifiParent(QString dev);
+    void loadProxyConfig();
+    void saveProxyConfig();
+
+    // PPPOE Stuff
+    void disablePPPOEConfig();
     void loadPPPOEConfig();
-    void disablePPPOEConfig();
+    void otherPPPOEDevs();
     void savePPPOEConfig();
     void updatePPPconf();
-    void loadProxyConfig();
-    void saveProxyConfig();
 
 signals:
 	void changed(bool);



More information about the Commits mailing list