author | llornkcor <llornkcor> | 2002-03-28 02:18:16 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-03-28 02:18:16 (UTC) |
commit | a2cd4f6515e590ef2e818929843e2923b75beef5 (patch) (side-by-side diff) | |
tree | 918bcd4c46acd2c63ea7fa7ad40c212e1002e457 | |
parent | d360439051f476cd847c4d8cec27a52addcd72a2 (diff) | |
download | opie-a2cd4f6515e590ef2e818929843e2923b75beef5.zip opie-a2cd4f6515e590ef2e818929843e2923b75beef5.tar.gz opie-a2cd4f6515e590ef2e818929843e2923b75beef5.tar.bz2 |
wishy-washy on single vs double click
-rw-r--r-- | noncore/net/opieftp/opieftp.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp index 907a812..efcaf84 100644 --- a/noncore/net/opieftp/opieftp.cpp +++ b/noncore/net/opieftp/opieftp.cpp @@ -128,50 +128,52 @@ OpieFtp::OpieFtp( ) Local_View->addColumn( tr("File"),150); Local_View->addColumn( tr("Size"),-1); Local_View->setColumnAlignment(1,QListView::AlignRight); Local_View->addColumn( tr("Date"),-1); Local_View->setColumnAlignment(2,QListView::AlignRight); Local_View->setAllColumnsShowFocus(TRUE); Local_View->setMultiSelection( TRUE ); QPEApplication::setStylusOperation( Local_View->viewport(),QPEApplication::RightOnHold); tabLayout->addWidget( Local_View, 0, 0 ); - connect( Local_View, SIGNAL( doubleClicked( QListViewItem*)), + connect( Local_View, SIGNAL( clicked( QListViewItem*)), this,SLOT( localListClicked(QListViewItem *)) ); +// connect( Local_View, SIGNAL( doubleClicked( QListViewItem*)), +// this,SLOT( localListClicked(QListViewItem *)) ); connect( Local_View, SIGNAL( mouseButtonPressed( int, QListViewItem *, const QPoint&, int)), this,SLOT( ListPressed(int, QListViewItem *, const QPoint&, int)) ); TabWidget->insertTab( tab, tr( "Local" ) ); tab_2 = new QWidget( TabWidget, "tab_2" ); tabLayout_2 = new QGridLayout( tab_2 ); tabLayout_2->setSpacing( 2); tabLayout_2->setMargin( 2); Remote_View = new QListView( tab_2, "Remote_View" ); Remote_View->addColumn( tr("File"),150); Remote_View->addColumn( tr("Size"),-1); Remote_View->setColumnAlignment(1,QListView::AlignRight); Remote_View->addColumn( tr("Date"),-1); Remote_View->setColumnAlignment(2,QListView::AlignRight); Remote_View->addColumn( tr("Dir"),-1); Remote_View->setColumnAlignment(4,QListView::AlignRight); Remote_View->setAllColumnsShowFocus(TRUE); Remote_View->setMultiSelection( TRUE ); QPEApplication::setStylusOperation( Remote_View->viewport(),QPEApplication::RightOnHold); - connect( Remote_View, SIGNAL( doubleClicked( QListViewItem*)), + connect( Remote_View, SIGNAL( clicked( QListViewItem*)), this,SLOT( remoteListClicked(QListViewItem *)) ); connect( Remote_View, SIGNAL( mouseButtonPressed( int, QListViewItem *, const QPoint&, int)), this,SLOT( RemoteListPressed(int, QListViewItem *, const QPoint&, int)) ); tabLayout_2->addWidget( Remote_View, 0, 0 ); TabWidget->insertTab( tab_2, tr( "Remote" ) ); tab_3 = new QWidget( TabWidget, "tab_3" ); tabLayout_3 = new QGridLayout( tab_3 ); tabLayout_3->setSpacing( 2); tabLayout_3->setMargin( 2); @@ -431,25 +433,25 @@ void OpieFtp::localUpload() if( !FtpPut( localFile.latin1(), remoteFile.latin1(),FTPLIB_IMAGE, conn ) ) { QString msg; msg.sprintf(tr("Unable to upload\n")+"%s",FtpLastResponse(conn)); msg.replace(QRegExp(":"),"\n"); QMessageBox::message(tr("Note"),msg); } } else { QMessageBox::message(tr("Note"),tr("Cannot upload directories")); } ProgressBar->reset(); nullifyCallBack(); - it.current()->setSelected(FALSE); + it.current()->setSelected(FALSE); } //end currentSelected } TabWidget->setCurrentPage(1); remoteDirList( (const QString &)currentRemoteDir); //this also calls populate QCopEnvelope ( "QPE/System", "notBusy()" ); } void OpieFtp::nullifyCallBack() { FtpOptions(FTPLIB_CALLBACK, NULL, conn); FtpOptions(FTPLIB_IDLETIME, NULL, conn); FtpOptions(FTPLIB_CALLBACKARG, NULL, conn); @@ -485,25 +487,25 @@ void OpieFtp::remoteDownload() FtpOptions(FTPLIB_CALLBACKARG, (long) &fsz, conn); FtpOptions(FTPLIB_CALLBACKBYTES, (long) fsz/10, conn); qDebug("Get: %s, %s",localFile.latin1(),remoteFile.latin1()); if(!FtpGet( localFile.latin1(), remoteFile.latin1(),FTPLIB_IMAGE, conn ) ) { QString msg; msg.sprintf(tr("Unable to download \n")+"%s",FtpLastResponse(conn)); msg.replace(QRegExp(":"),"\n"); QMessageBox::message(tr("Note"),msg); } ProgressBar->reset(); nullifyCallBack(); - it.current()->setSelected(FALSE); + it.current()->setSelected(FALSE); } } TabWidget->setCurrentPage(0); populateLocalView(); QCopEnvelope ( "QPE/System", "notBusy()" ); } bool OpieFtp::remoteDirList(const QString &dir) { QString tmp = QDir::homeDirPath(); if(tmp.right(1) != "/") tmp+="/._temp"; @@ -740,25 +742,25 @@ void OpieFtp::localListClicked(QListViewItem *selectedItem) populateLocalView(); } else { currentDir.cdUp(); populateLocalView(); } if(QDir(strItem).exists()){ currentDir.cd(strItem, TRUE); populateLocalView(); } } else { strItem=QDir::cleanDirPath(currentDir.canonicalPath()+"/"+strItem); if( QFile::exists(strItem ) ) { - qDebug("upload "+strItem); + // qDebug("upload "+strItem); } } //end not symlink chdir(strItem.latin1()); } } } void OpieFtp::doLocalCd() { localListClicked( Local_View->currentItem()); } |