author | mickeyl <mickeyl> | 2003-09-25 15:02:43 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-09-25 15:02:43 (UTC) |
commit | 9047b6d4ffe0cbcecd90fd994ce2353277c378a1 (patch) (side-by-side diff) | |
tree | c649c9c85c9c5846c0019e26bb3aaafbfbc76757 | |
parent | 990e3c5834b33227b327e1fec0d7f7f429e75952 (diff) | |
download | opie-9047b6d4ffe0cbcecd90fd994ce2353277c378a1.zip opie-9047b6d4ffe0cbcecd90fd994ce2353277c378a1.tar.gz opie-9047b6d4ffe0cbcecd90fd994ce2353277c378a1.tar.bz2 |
start with persistent configuration
-rw-r--r-- | noncore/net/wellenreiter/gui/configbase.ui | 107 | ||||
-rw-r--r-- | noncore/net/wellenreiter/gui/configwindow.cpp | 31 | ||||
-rw-r--r-- | noncore/net/wellenreiter/gui/configwindow.h | 5 |
3 files changed, 95 insertions, 48 deletions
diff --git a/noncore/net/wellenreiter/gui/configbase.ui b/noncore/net/wellenreiter/gui/configbase.ui index d9a0aea..d7ab3bb 100644 --- a/noncore/net/wellenreiter/gui/configbase.ui +++ b/noncore/net/wellenreiter/gui/configbase.ui @@ -13,4 +13,4 @@ <y>0</y> - <width>286</width> - <height>280</height> + <width>303</width> + <height>287</height> </rect> @@ -629,3 +629,3 @@ </attribute> - <grid> + <vbox> <property stdset="1"> @@ -638,3 +638,57 @@ </property> - <widget row="3" column="0" > + <widget> + <class>QCheckBox</class> + <property stdset="1"> + <name>name</name> + <cstring>lookupVendor</cstring> + </property> + <property stdset="1"> + <name>text</name> + <string>Lookup MAC vendor names</string> + </property> + </widget> + <widget> + <class>QCheckBox</class> + <property stdset="1"> + <name>name</name> + <cstring>openTree</cstring> + </property> + <property stdset="1"> + <name>text</name> + <string>Open Tree On New Station</string> + </property> + </widget> + <widget> + <class>QCheckBox</class> + <property stdset="1"> + <name>name</name> + <cstring>disablePM</cstring> + </property> + <property stdset="1"> + <name>text</name> + <string>Disable Power Management</string> + </property> + </widget> + <spacer> + <property> + <name>name</name> + <cstring>Spacer3</cstring> + </property> + <property stdset="1"> + <name>orientation</name> + <enum>Vertical</enum> + </property> + <property stdset="1"> + <name>sizeType</name> + <enum>Expanding</enum> + </property> + <property> + <name>sizeHint</name> + <size> + <width>20</width> + <height>20</height> + </size> + </property> + </spacer> + <widget> <class>QGroupBox</class> @@ -713,46 +767,3 @@ </widget> - <spacer row="2" column="0" > - <property> - <name>name</name> - <cstring>Spacer3</cstring> - </property> - <property stdset="1"> - <name>orientation</name> - <enum>Vertical</enum> - </property> - <property stdset="1"> - <name>sizeType</name> - <enum>Expanding</enum> - </property> - <property> - <name>sizeHint</name> - <size> - <width>20</width> - <height>20</height> - </size> - </property> - </spacer> - <widget row="0" column="0" > - <class>QCheckBox</class> - <property stdset="1"> - <name>name</name> - <cstring>lookupVendor</cstring> - </property> - <property stdset="1"> - <name>text</name> - <string>Lookup MAC vendor names</string> - </property> - </widget> - <widget row="1" column="0" > - <class>QCheckBox</class> - <property stdset="1"> - <name>name</name> - <cstring>openTree</cstring> - </property> - <property stdset="1"> - <name>text</name> - <string>Open Tree On New Station</string> - </property> - </widget> - </grid> + </vbox> </widget> diff --git a/noncore/net/wellenreiter/gui/configwindow.cpp b/noncore/net/wellenreiter/gui/configwindow.cpp index a331925..d255c6a 100644 --- a/noncore/net/wellenreiter/gui/configwindow.cpp +++ b/noncore/net/wellenreiter/gui/configwindow.cpp @@ -57,2 +57,4 @@ WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char + if ( !load() ) // no configuration present + { // try to guess device type @@ -79,2 +81,3 @@ WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char } + } @@ -97,2 +100,8 @@ WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char +WellenreiterConfigWindow::~WellenreiterConfigWindow() +{ + save(); +} + + int WellenreiterConfigWindow::driverType() const @@ -210 +219,23 @@ int WellenreiterConfigWindow::gpsPort() const } + + +bool WellenreiterConfigWindow::load() +{ +#ifdef Q_WS_X11 + #warning Persistent Configuration not yet implemented for standalone X11 build + return false; +#else + qDebug( "loading configuration settings..." ); + return true; +#endif +} + + +void WellenreiterConfigWindow::save() +{ +#ifdef Q_WS_X11 + #warning Persistent Configuration not yet implemented for standalone X11 build +#else + qDebug( "saving configuration settings..." ); +#endif +} diff --git a/noncore/net/wellenreiter/gui/configwindow.h b/noncore/net/wellenreiter/gui/configwindow.h index 8f160b1..2986320 100644 --- a/noncore/net/wellenreiter/gui/configwindow.h +++ b/noncore/net/wellenreiter/gui/configwindow.h @@ -39,2 +39,4 @@ class WellenreiterConfigWindow : public WellenreiterConfigBase WellenreiterConfigWindow( QWidget * parent = 0, const char * name = "WellenreiterConfigWindow", WFlags f = 0 ); + ~WellenreiterConfigWindow(); + int driverType() const; @@ -52,2 +54,5 @@ class WellenreiterConfigWindow : public WellenreiterConfigBase + void save(); + bool load(); + public slots: |