author | korovkin <korovkin> | 2006-03-19 14:59:21 (UTC) |
---|---|---|
committer | korovkin <korovkin> | 2006-03-19 14:59:21 (UTC) |
commit | 39fedaa847ed64b2c0113a75d0f1de29da5876db (patch) (side-by-side diff) | |
tree | 442fc009975e72a22cb9773b88599ea388af195b /noncore/net/opietooth/manager/obexftpdialog.h | |
parent | 3de693f244170cb9424d841aef6a6d7175766fa3 (diff) | |
download | opie-39fedaa847ed64b2c0113a75d0f1de29da5876db.zip opie-39fedaa847ed64b2c0113a75d0f1de29da5876db.tar.gz opie-39fedaa847ed64b2c0113a75d0f1de29da5876db.tar.bz2 |
Added device browsing and files downloading using OBEX File transfer
protocol.
Diffstat (limited to 'noncore/net/opietooth/manager/obexftpdialog.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/opietooth/manager/obexftpdialog.h | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/noncore/net/opietooth/manager/obexftpdialog.h b/noncore/net/opietooth/manager/obexftpdialog.h new file mode 100644 index 0000000..b13efe5 --- a/dev/null +++ b/noncore/net/opietooth/manager/obexftpdialog.h @@ -0,0 +1,66 @@ +/* $Id$ */ +/* OBEX file browser dialog */ +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ +/* + * This code uses and is based on ObexFTP project code: http://triq.net/obexftp/ + */ +#ifndef _OBEXFTPDIALOG_H_ +#define _OBEXFTPDIALOG_H_ +#include "obexftpdialogbase.h" +#include <qstring.h> +#include <obexftp.h> +#include <uuid.h> +#include <client.h> +#include <opie2/ofileselector.h> +#include <qlayout.h> +namespace OpieTooth { + class ObexFtpDialog : public ObexFtpDialogBase { + Q_OBJECT + public: + ObexFtpDialog(const QString& device = 0, int port = 0, + QWidget* parent = 0, const char* name = 0, bool modal = TRUE, + WFlags fl = 0); + ~ObexFtpDialog(); + void log(QString str); + void log(QCString str); + void log(const char* str); + void log(QString& str); + void incProgress(); + void doneProgress(); + protected: + int cli_connect_uuid(const uint8_t *uuid, int uuid_len); + int errBox(QCString msg); //Error message box + int errBox(QString msg); //Error message box + int errBox(const char* msg); //Error message box + void status(QCString msg); //Text in the status bar + void status(QString msg); //Text in the status bar + void status(const char* msg); //Text in the status bar + protected: + QString m_device; //device MAC address + int m_port; //port + int transport; //transport type + bool use_conn; + bool use_path; + obexftp_client_t* client; //Obex ftp client handler + QString curdir; //Current directory on device + QString localCurdir; //Local current directory + QString file2get; //Remote file name + QString local; //Local file name + int progressStatus; //Progress status + Opie::Ui::OFileSelector* destFile; //Destination file or directory + QVBoxLayout* localLayout; //Window layout + private slots: + void slotBrowse(); + void slotCd(QListViewItem* item); + void getFile(); + void updateDir(const QString& newdir); + }; +}; +#endif |