summaryrefslogtreecommitdiff
path: root/noncore
authorllornkcor <llornkcor>2002-04-19 23:44:14 (UTC)
committer llornkcor <llornkcor>2002-04-19 23:44:14 (UTC)
commit609a534bc1f5efda3242be2d1dc5dbc4a13715cb (patch) (side-by-side diff)
tree26ba7eb664cac1f7606f8b6d0db5930a8d5fa209 /noncore
parentf62cb71116d1aa16603fe6e87169e8b98125ce1f (diff)
downloadopie-609a534bc1f5efda3242be2d1dc5dbc4a13715cb.zip
opie-609a534bc1f5efda3242be2d1dc5dbc4a13715cb.tar.gz
opie-609a534bc1f5efda3242be2d1dc5dbc4a13715cb.tar.bz2
changed date and size columns, and added about
Diffstat (limited to 'noncore') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opieftp/opieftp.cpp28
-rw-r--r--noncore/net/opieftp/opieftp.h4
-rw-r--r--noncore/net/opieftp/opieftp.pro4
3 files changed, 24 insertions, 12 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp
index 7f5d71c..e15bbef 100644
--- a/noncore/net/opieftp/opieftp.cpp
+++ b/noncore/net/opieftp/opieftp.cpp
@@ -22,6 +22,7 @@
#include <qpe/qcopenvelope_qws.h>
#include <qpe/config.h>
#include <qpe/mimetype.h>
+#include <qpe/qpemessagebox.h>
#include <qstringlist.h>
#include <qtextstream.h>
@@ -84,7 +85,7 @@ OpieFtp::OpieFtp( )
localMenu = new QPopupMenu( this );
remoteMenu = new QPopupMenu( this );
tabMenu = new QPopupMenu( this );
-
+
layout->addMultiCellWidget( menuBar, 0, 0, 0, 2 );
menuBar->insertItem( tr( "Connection" ), connectionMenu);
@@ -114,9 +115,12 @@ OpieFtp::OpieFtp( )
tabMenu->insertItem( tr( "Switch to Local" ), this, SLOT( switchToLocalTab() ));
tabMenu->insertItem( tr( "Switch to Remote" ), this, SLOT( switchToRemoteTab() ));
tabMenu->insertItem( tr( "Switch to Config" ), this, SLOT( switchToConfigTab() ));
+ tabMenu->insertSeparator();
+ tabMenu->insertItem( tr( "About" ), this, SLOT( doAbout() ));
tabMenu->setCheckable(TRUE);
+
cdUpButton = new QPushButton(Resource::loadIconSet("up"),"",this,"cdUpButton");
cdUpButton ->setFixedSize( QSize( 20, 20 ) );
connect( cdUpButton ,SIGNAL(released()),this,SLOT( upDir()) );
@@ -150,9 +154,9 @@ OpieFtp::OpieFtp( )
Local_View = new QListView( tab, "Local_View" );
// Local_View->setResizePolicy( QListView::AutoOneFit );
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(1,QListView::AlignRight);
+ Local_View->addColumn( tr("Size"),-1);
Local_View->setColumnAlignment(2,QListView::AlignRight);
Local_View->setAllColumnsShowFocus(TRUE);
@@ -180,9 +184,9 @@ OpieFtp::OpieFtp( )
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(1,QListView::AlignRight);
+ Remote_View->addColumn( tr("Size"),-1);
Remote_View->setColumnAlignment(2,QListView::AlignRight);
Remote_View->addColumn( tr("Dir"),-1);
Remote_View->setColumnAlignment(4,QListView::AlignRight);
@@ -611,7 +615,7 @@ void OpieFtp::populateLocalView()
}
}
if(fileL !="./" && fi->exists()) {
- item= new QListViewItem( Local_View,fileL,fileS , fileDate);
+ item= new QListViewItem( Local_View,fileL, fileDate, fileS );
QPixmap pm;
if(isDir || fileL.find("/",0,TRUE) != -1) {
@@ -677,13 +681,13 @@ bool OpieFtp::populateRemoteView( )
fileDate = fileDate.stripWhiteSpace();
if(fileL.find("total",0,TRUE) == -1) {
if(s.left(1) == "d" || fileL.find("/",0,TRUE) != -1) {
- QListViewItem * item = new QListViewItem( Remote_View, fileL, fileS, fileDate,"d");
+ QListViewItem * item = new QListViewItem( Remote_View, fileL, fileDate, fileS,"d");
item->setPixmap( 0, Resource::loadPixmap( "folder" ));
// if(itemDir)
item->moveItem(itemDir);
itemDir=item;
} else {
- QListViewItem * item = new QListViewItem( Remote_View, fileL, fileS, fileDate,"f");
+ QListViewItem * item = new QListViewItem( Remote_View, fileL, fileDate, fileS,"f");
item->setPixmap( 0, Resource::loadPixmap( "fileopen" ));
// if(itemFile)
item->moveItem(itemDir);
@@ -1313,3 +1317,11 @@ void OpieFtp::homeButtonPushed() {
populateLocalView();
update();
}
+
+void OpieFtp::doAbout() {
+ QMessageBox::message("OpieFtp","Opie ftp client is copyright 2002 by\n"
+ "L.J.Potter<llornkcor@handhelds.org>\n"
+ "and uses ftplib copyright 1996-2000\n"
+ "by Thomas Pfau, pfau@cnj.digex.net\n\n"
+ "and is licensed by the GPL");
+}
diff --git a/noncore/net/opieftp/opieftp.h b/noncore/net/opieftp/opieftp.h
index 6852b1c..218a958 100644
--- a/noncore/net/opieftp/opieftp.h
+++ b/noncore/net/opieftp/opieftp.h
@@ -55,7 +55,7 @@ public:
QLineEdit *PasswordEdit, *remotePath;
QLabel *TextLabel2, *TextLabel1, *TextLabel3, *TextLabel4;;
QSpinBox* PortSpinBox;
- QPopupMenu *connectionMenu, *localMenu, *remoteMenu, *tabMenu;
+ QPopupMenu *connectionMenu, *localMenu, *remoteMenu, *tabMenu, *aboutMenu;
QDir currentDir;
QString currentRemoteDir;
QString filterStr;
@@ -67,7 +67,7 @@ protected slots:
void upDir();
void homeButtonPushed();
void docButtonPushed();
-
+ void doAbout();
void serverComboEdited(const QString & );
void showLocalMenu( QListViewItem *);
void showRemoteMenu( QListViewItem *);
diff --git a/noncore/net/opieftp/opieftp.pro b/noncore/net/opieftp/opieftp.pro
index f25d15f..7aead00 100644
--- a/noncore/net/opieftp/opieftp.pro
+++ b/noncore/net/opieftp/opieftp.pro
@@ -1,7 +1,7 @@
TEMPLATE = app
CONFIG += qt warn_on release
-HEADERS = opieftp.h inputDialog.h ftplib.h
-SOURCES = opieftp.cpp inputDialog.cpp ftplib.c main.cpp
+HEADERS = opieftp.h inputDialog.h ftplib.h filePermissions.h
+SOURCES = opieftp.cpp inputDialog.cpp ftplib.c filePermissions.cpp main.cpp
TARGET = opieftp
REQUIRES=medium-config
DESTDIR = $(OPIEDIR)/bin