summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opieftp/opieftp.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp
index f1b159c..6e9dc67 100644
--- a/noncore/net/opieftp/opieftp.cpp
+++ b/noncore/net/opieftp/opieftp.cpp
@@ -321,33 +321,36 @@ void OpieFtp::nullifyCallBack()
321{ 321{
322 FtpOptions(FTPLIB_CALLBACK, NULL, conn); 322 FtpOptions(FTPLIB_CALLBACK, NULL, conn);
323 FtpOptions(FTPLIB_IDLETIME, NULL, conn); 323 FtpOptions(FTPLIB_IDLETIME, NULL, conn);
324 FtpOptions(FTPLIB_CALLBACKARG, NULL, conn); 324 FtpOptions(FTPLIB_CALLBACKARG, NULL, conn);
325 FtpOptions(FTPLIB_CALLBACKBYTES, NULL, conn); 325 FtpOptions(FTPLIB_CALLBACKBYTES, NULL, conn);
326 326
327} 327}
328 328
329void OpieFtp::remoteDownload() 329void OpieFtp::remoteDownload()
330{ 330{
331 int fsz; 331 int fsz;
332 QCopEnvelope ( "QPE/System", "busy()" ); 332 QCopEnvelope ( "QPE/System", "busy()" );
333 qApp->processEvents(); 333 qApp->processEvents();
334 QString strItem = Remote_View->currentItem()->text(0); 334 QString strItem = Remote_View->currentItem()->text(0);
335// strItem=strItem.right(strItem.length()-1); 335// strItem=strItem.right(strItem.length()-1);
336 336
337 QString localFile = currentDir.canonicalPath()+strItem; 337 QString localFile = currentDir.canonicalPath();
338 if(localFile.right(1).find("/",0,TRUE) == -1)
339 localFile += "/";
340 localFile += strItem;
338// QString localFile = currentDir.canonicalPath()+"/"+strItem; 341// QString localFile = currentDir.canonicalPath()+"/"+strItem;
339 QString remoteFile= currentRemoteDir+strItem; 342 QString remoteFile= currentRemoteDir+strItem;
340 if (!FtpSize( remoteFile.latin1(), &fsz, FTPLIB_ASCII, conn)) 343 if (!FtpSize( remoteFile.latin1(), &fsz, FTPLIB_ASCII, conn))
341 fsz = 0; 344 fsz = 0;
342 QString temp; 345 QString temp;
343 temp.sprintf( remoteFile+" "+" %dkb", fsz); 346 temp.sprintf( remoteFile+" "+" %dkb", fsz);
344 347
345 ProgressBar->setTotalSteps(fsz); 348 ProgressBar->setTotalSteps(fsz);
346 FtpOptions(FTPLIB_CALLBACK, (long) log_progress, conn); 349 FtpOptions(FTPLIB_CALLBACK, (long) log_progress, conn);
347 FtpOptions(FTPLIB_IDLETIME, (long) 1000, conn); 350 FtpOptions(FTPLIB_IDLETIME, (long) 1000, conn);
348 FtpOptions(FTPLIB_CALLBACKARG, (long) &fsz, conn); 351 FtpOptions(FTPLIB_CALLBACKARG, (long) &fsz, conn);
349 FtpOptions(FTPLIB_CALLBACKBYTES, (long) fsz/10, conn); 352 FtpOptions(FTPLIB_CALLBACKBYTES, (long) fsz/10, conn);
350 qDebug("Get: %s, %s",localFile.latin1(),remoteFile.latin1()); 353 qDebug("Get: %s, %s",localFile.latin1(),remoteFile.latin1());
351 354
352 if(!FtpGet( localFile.latin1(), remoteFile.latin1(),FTPLIB_IMAGE, conn ) ) { 355 if(!FtpGet( localFile.latin1(), remoteFile.latin1(),FTPLIB_IMAGE, conn ) ) {
353 QString msg; 356 QString msg;