author | llornkcor <llornkcor> | 2002-05-16 16:29:14 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-05-16 16:29:14 (UTC) |
commit | 62c1424c5421e926173133ab4acd7346c590612e (patch) (unidiff) | |
tree | f9df1716b94df11330bb7cb466e26d2e3d1f8add /noncore | |
parent | b94bd6003bf7c2024b0f254805f54ff4e52ead6e (diff) | |
download | opie-62c1424c5421e926173133ab4acd7346c590612e.zip opie-62c1424c5421e926173133ab4acd7346c590612e.tar.gz opie-62c1424c5421e926173133ab4acd7346c590612e.tar.bz2 |
fixed not loading ftp configs correctly..
-rw-r--r-- | noncore/net/opieftp/opieftp.cpp | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp index 7ca3fff..293c391 100644 --- a/noncore/net/opieftp/opieftp.cpp +++ b/noncore/net/opieftp/opieftp.cpp | |||
@@ -300,3 +300,3 @@ OpieFtp::OpieFtp( ) | |||
300 | 300 | ||
301 | // fillCombos(); | 301 | fillCombos(); |
302 | 302 | ||
@@ -305,3 +305,5 @@ OpieFtp::OpieFtp( ) | |||
305 | populateLocalView(); | 305 | populateLocalView(); |
306 | qDebug("read COnfig"); | ||
306 | readConfig(); | 307 | readConfig(); |
308 | qDebug("Set current item"); | ||
307 | ServerComboBox->setCurrentItem(currentServerConfig); | 309 | ServerComboBox->setCurrentItem(currentServerConfig); |
@@ -433,2 +435,3 @@ void OpieFtp::connector() | |||
433 | setCaption(ftp_host); | 435 | setCaption(ftp_host); |
436 | if( currentServerConfig == -1) | ||
434 | writeConfig(); | 437 | writeConfig(); |
@@ -1147,2 +1150,3 @@ void OpieFtp::readConfig() | |||
1147 | currentServerConfig = cfg.readNumEntry("currentServer", -1); | 1150 | currentServerConfig = cfg.readNumEntry("currentServer", -1); |
1151 | |||
1148 | // qDebug("Reading %d", currentServerConfig); | 1152 | // qDebug("Reading %d", currentServerConfig); |
@@ -1172,2 +1176,3 @@ void OpieFtp::writeConfig() | |||
1172 | cfg.writeEntry( temp, ServerComboBox->currentText() +":"+PortSpinBox->cleanText() ); | 1176 | cfg.writeEntry( temp, ServerComboBox->currentText() +":"+PortSpinBox->cleanText() ); |
1177 | cfg.writeEntry("currentServer", numberOfEntries+1); | ||
1173 | cfg.setGroup(temp); | 1178 | cfg.setGroup(temp); |
@@ -1178,2 +1183,3 @@ void OpieFtp::writeConfig() | |||
1178 | cfg.writeEntry("numberOfEntries", QString::number(numberOfEntries + 1 )); | 1183 | cfg.writeEntry("numberOfEntries", QString::number(numberOfEntries + 1 )); |
1184 | |||
1179 | } | 1185 | } |
@@ -1189,4 +1195,6 @@ void OpieFtp::fillCombos() | |||
1189 | temp.setNum(i); | 1195 | temp.setNum(i); |
1196 | qDebug(temp); | ||
1190 | cfg.setGroup("Server"); | 1197 | cfg.setGroup("Server"); |
1191 | remoteServerStr = cfg.readEntry( temp,""); | 1198 | remoteServerStr = cfg.readEntry( temp,""); |
1199 | qDebug( remoteServerStr); | ||
1192 | int divider = remoteServerStr.length() - remoteServerStr.find(":",0,TRUE); | 1200 | int divider = remoteServerStr.length() - remoteServerStr.find(":",0,TRUE); |
@@ -1197,2 +1205,3 @@ void OpieFtp::fillCombos() | |||
1197 | remoteServerStr = remoteServerStr.left(remoteServerStr.length()-divider); | 1205 | remoteServerStr = remoteServerStr.left(remoteServerStr.length()-divider); |
1206 | qDebug( remoteServerStr); | ||
1198 | ServerComboBox->insertItem( remoteServerStr ); | 1207 | ServerComboBox->insertItem( remoteServerStr ); |
@@ -1225,4 +1234,5 @@ void OpieFtp::serverComboSelected(int index) | |||
1225 | 1234 | ||
1226 | temp.setNum(index+1); | 1235 | temp.setNum(index); |
1227 | remoteServerStr = cfg.readEntry( temp,""); | 1236 | remoteServerStr = cfg.readEntry( temp,""); |
1237 | qDebug("Group" +temp); | ||
1228 | cfg.setGroup(temp); | 1238 | cfg.setGroup(temp); |
@@ -1241,5 +1251,7 @@ void OpieFtp::serverComboSelected(int index) | |||
1241 | UsernameComboBox->lineEdit()->setText(username); | 1251 | UsernameComboBox->lineEdit()->setText(username); |
1242 | 1252 | qDebug(username); | |
1243 | // qDebug("Password is "+cfg.readEntryCrypt(username, "me@opieftp.org")); | 1253 | // qDebug("Password is "+cfg.readEntryCrypt(username, "me@opieftp.org")); |
1244 | PasswordEdit->setText(cfg.readEntryCrypt(username, "me@opieftp.org")); | 1254 | PasswordEdit->setText(cfg.readEntryCrypt(username, "me@opieftp.org")); |
1255 | // UsernameComboBox | ||
1256 | // PasswordEdit | ||
1245 | 1257 | ||