summaryrefslogtreecommitdiff
path: root/noncore/net
Side-by-side diff
Diffstat (limited to 'noncore/net') (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/opieftp/opieftp.cpp29
1 files changed, 17 insertions, 12 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp
index 3dda17e..e64fd73 100644
--- a/noncore/net/opieftp/opieftp.cpp
+++ b/noncore/net/opieftp/opieftp.cpp
@@ -134,4 +134,5 @@ OpieFtp::OpieFtp( )
Local_View->setMultiSelection( TRUE );
Local_View->setSelectionMode(QListView::Extended);
+
QPEApplication::setStylusOperation( Local_View->viewport(),QPEApplication::RightOnHold);
@@ -319,5 +320,4 @@ void OpieFtp::newConnection()
PortSpinBox->setValue( 21);
TabWidget->setCurrentPage(2);
- currentServerConfig = -1;
}
@@ -433,6 +433,6 @@ void OpieFtp::localUpload()
ProgressBar->reset();
nullifyCallBack();
- it.current()->setSelected(FALSE);
} //end currentSelected
+ it.current()->setSelected(FALSE);
}
TabWidget->setCurrentPage(1);
@@ -487,6 +487,6 @@ void OpieFtp::remoteDownload()
ProgressBar->reset();
nullifyCallBack();
- it.current()->setSelected(FALSE);
}
+ it.current()->setSelected(FALSE);
}
TabWidget->setCurrentPage(0);
@@ -658,5 +658,5 @@ void OpieFtp::remoteListClicked(QListViewItem *selectedItem)
{
if( selectedItem) {
- QCopEnvelope ( "QPE/System", "busy()" );
+// QCopEnvelope ( "QPE/System", "busy()" );
QString oldRemoteCurrentDir = currentRemoteDir;
QString strItem=selectedItem->text(0);
@@ -687,12 +687,11 @@ void OpieFtp::remoteListClicked(QListViewItem *selectedItem)
currentRemoteDir = oldRemoteCurrentDir;
strItem="";
- qDebug("RemoteCurrentDir1 "+oldRemoteCurrentDir);
+// qDebug("RemoteCurrentDir1 "+oldRemoteCurrentDir);
}
} else if(strItem.find("/",0,TRUE) != -1) { // this is a directory
- qDebug("trying directory");
if( !remoteChDir( (const QString &)currentRemoteDir + strItem)) {
currentRemoteDir = oldRemoteCurrentDir;
strItem="";
- qDebug("RemoteCurrentDir1 "+oldRemoteCurrentDir);
+// qDebug("RemoteCurrentDir1 "+oldRemoteCurrentDir);
} else {
@@ -700,5 +699,6 @@ void OpieFtp::remoteListClicked(QListViewItem *selectedItem)
}
} else {
- qDebug("download "+strItem);
+ QCopEnvelope ( "QPE/System", "notBusy()" );
+ return;
}
}
@@ -707,6 +707,6 @@ void OpieFtp::remoteListClicked(QListViewItem *selectedItem)
currentRemoteDir +="/";
currentPathCombo->lineEdit()->setText( currentRemoteDir );
- fillRemoteCombo( (const QString &)currentDir);
- QCopEnvelope ( "QPE/System", "notBusy()" );
+ fillRemoteCombo( (const QString &)currentRemoteDir);
+// QCopEnvelope ( "QPE/System", "notBusy()" );
}
}
@@ -728,4 +728,5 @@ void OpieFtp::localListClicked(QListViewItem *selectedItem)
} else { // not a symlink
if(strItem.find(". .",0,TRUE) && strItem.find("/",0,TRUE)!=-1 ) {
+
if(QDir(QDir::cleanDirPath(currentDir.canonicalPath()+"/"+strItem)).exists() ) {
strItem=QDir::cleanDirPath(currentDir.canonicalPath()+"/"+strItem);
@@ -744,4 +745,5 @@ void OpieFtp::localListClicked(QListViewItem *selectedItem)
if( QFile::exists(strItem ) ) {
// qDebug("upload "+strItem);
+ return;
}
} //end not symlink
@@ -1069,5 +1071,4 @@ void OpieFtp::readConfig()
void OpieFtp::writeConfig()
{
-
Config cfg("opieftp");
cfg.setGroup("Server");
@@ -1075,4 +1076,9 @@ void OpieFtp::writeConfig()
int numberOfEntries = cfg.readNumEntry("numberOfEntries",0);
if( currentServerConfig == -1) {
+ for (int i = 1; i <= numberOfEntries; i++) {
+ temp.setNum(i);
+ cfg.setGroup("Server");
+ QString tempStr = cfg.readEntry( temp,"");
+ }
temp.setNum( numberOfEntries + 1);
@@ -1091,5 +1097,4 @@ void OpieFtp::writeConfig()
cfg.setGroup("Server");
cfg.writeEntry("numberOfEntries", QString::number(numberOfEntries + 1 ));
-
}
}