summaryrefslogtreecommitdiff
path: root/noncore/settings
Side-by-side diff
Diffstat (limited to 'noncore/settings') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/aqpkg/settingsimpl.cpp36
1 files changed, 33 insertions, 3 deletions
diff --git a/noncore/settings/aqpkg/settingsimpl.cpp b/noncore/settings/aqpkg/settingsimpl.cpp
index 9f611da..e2afada 100644
--- a/noncore/settings/aqpkg/settingsimpl.cpp
+++ b/noncore/settings/aqpkg/settingsimpl.cpp
@@ -288,2 +288,4 @@ void SettingsImpl :: editServer( int sel )
Server *s = dataMgr->getServer( servers->currentText() );
+ if ( s )
+ {
serverName = s->getServerName();
@@ -293,2 +295,10 @@ void SettingsImpl :: editServer( int sel )
}
+ else
+ {
+ serverName = "";
+ servername->setText( "" );
+ serverurl->setText( "" );
+ active->setChecked( false );
+ }
+}
@@ -307,2 +317,4 @@ void SettingsImpl :: removeServer()
Server *s = dataMgr->getServer( servers->currentText() );
+ if ( s )
+ {
dataMgr->getServerList().removeRef( s );
@@ -310,2 +322,3 @@ void SettingsImpl :: removeServer()
}
+}
@@ -334,3 +347,4 @@ void SettingsImpl :: changeServerDetails()
Server *s = dataMgr->getServer( servers->currentText() );
-
+ if ( s )
+ {
// Update url
@@ -339,3 +353,2 @@ void SettingsImpl :: changeServerDetails()
-
// Check if server name has changed, if it has then we need to replace the key in the map
@@ -350,2 +363,3 @@ void SettingsImpl :: changeServerDetails()
}
+ }
else
@@ -367,2 +381,4 @@ void SettingsImpl :: editDestination( int sel )
Destination *d = dataMgr->getDestination( destinations->currentText() );
+ if ( d )
+ {
destinationName = d->getDestinationName();
@@ -372,2 +388,10 @@ void SettingsImpl :: editDestination( int sel )
}
+ else
+ {
+ destinationName = "";
+ destinationname->setText( "" );
+ destinationurl->setText( "" );
+ linkToRoot->setChecked( false );
+ }
+}
@@ -386,2 +410,4 @@ void SettingsImpl :: removeDestination()
Destination *d = dataMgr->getDestination( destinations->currentText() );
+ if ( d )
+ {
dataMgr->getDestinationList().removeRef( d );
@@ -389,2 +415,3 @@ void SettingsImpl :: removeDestination()
}
+}
@@ -403,3 +430,4 @@ void SettingsImpl :: changeDestinationDetails()
Destination *d = dataMgr->getDestination( destinations->currentText() );
-
+ if ( d )
+ {
// Update url
@@ -417,2 +445,3 @@ void SettingsImpl :: changeDestinationDetails()
}
+
#ifdef QWS
@@ -424,2 +453,3 @@ void SettingsImpl :: changeDestinationDetails()
}
+ }
else