-rw-r--r-- | core/obex/btobex.cpp | 4 | ||||
-rw-r--r-- | core/obex/btobex.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/core/obex/btobex.cpp b/core/obex/btobex.cpp index bb5c06d..b8556da 100644 --- a/core/obex/btobex.cpp +++ b/core/obex/btobex.cpp | |||
@@ -1,52 +1,52 @@ | |||
1 | 1 | ||
2 | #include "btobex.h" | 2 | #include "btobex.h" |
3 | #include <manager.h> | 3 | #include <opietooth/manager.h> |
4 | #include <services.h> | 4 | #include <opietooth/services.h> |
5 | 5 | ||
6 | /* OPIE */ | 6 | /* OPIE */ |
7 | #include <opie2/oprocess.h> | 7 | #include <opie2/oprocess.h> |
8 | #include <opie2/odebug.h> | 8 | #include <opie2/odebug.h> |
9 | 9 | ||
10 | /* QT */ | 10 | /* QT */ |
11 | #include <qfileinfo.h> | 11 | #include <qfileinfo.h> |
12 | #include <qstring.h> | 12 | #include <qstring.h> |
13 | #include <qmap.h> | 13 | #include <qmap.h> |
14 | #include <qmessagebox.h> | 14 | #include <qmessagebox.h> |
15 | 15 | ||
16 | using namespace OpieObex; | 16 | using namespace OpieObex; |
17 | 17 | ||
18 | using namespace Opie::Core; | 18 | using namespace Opie::Core; |
19 | /* TRANSLATOR OpieObex::Obex */ | 19 | /* TRANSLATOR OpieObex::Obex */ |
20 | using namespace OpieTooth; | 20 | using namespace OpieTooth; |
21 | 21 | ||
22 | BtObex::BtObex( QObject *parent, const char* name ) | 22 | BtObex::BtObex( QObject *parent, const char* name ) |
23 | : QObject(parent, name ) | 23 | : QObject(parent, name ) |
24 | { | 24 | { |
25 | m_rec = 0; | 25 | m_rec = 0; |
26 | m_send=0; | 26 | m_send=0; |
27 | m_count = 0; | 27 | m_count = 0; |
28 | m_receive = false; | 28 | m_receive = false; |
29 | connect( this, SIGNAL(error(int) ), // for recovering to receive | 29 | connect( this, SIGNAL(error(int) ), // for recovering to receive |
30 | SLOT(slotError() ) ); | 30 | SLOT(slotError() ) ); |
31 | connect( this, SIGNAL(sent(bool) ), | 31 | connect( this, SIGNAL(sent(bool) ), |
32 | SLOT(slotError() ) ); | 32 | SLOT(slotError() ) ); |
33 | btManager = NULL; | 33 | btManager = NULL; |
34 | }; | 34 | }; |
35 | 35 | ||
36 | BtObex::~BtObex() { | 36 | BtObex::~BtObex() { |
37 | if (btManager) | 37 | if (btManager) |
38 | delete btManager; | 38 | delete btManager; |
39 | delete m_rec; | 39 | delete m_rec; |
40 | delete m_send; | 40 | delete m_send; |
41 | } | 41 | } |
42 | 42 | ||
43 | void BtObex::receive() { | 43 | void BtObex::receive() { |
44 | m_receive = true; | 44 | m_receive = true; |
45 | m_outp = QString::null; | 45 | m_outp = QString::null; |
46 | m_rec = new OProcess(); | 46 | m_rec = new OProcess(); |
47 | 47 | ||
48 | // TODO mbhaynie: No idea if this actually works -- maybe opd is better. | 48 | // TODO mbhaynie: No idea if this actually works -- maybe opd is better. |
49 | *m_rec << "obexftpd" << "-b"; | 49 | *m_rec << "obexftpd" << "-b"; |
50 | // connect to the necessary slots | 50 | // connect to the necessary slots |
51 | connect(m_rec, SIGNAL(processExited(Opie::Core::OProcess*) ), | 51 | connect(m_rec, SIGNAL(processExited(Opie::Core::OProcess*) ), |
52 | this, SLOT(slotExited(Opie::Core::OProcess*) ) ); | 52 | this, SLOT(slotExited(Opie::Core::OProcess*) ) ); |
diff --git a/core/obex/btobex.h b/core/obex/btobex.h index 099f04a..ba50064 100644 --- a/core/obex/btobex.h +++ b/core/obex/btobex.h | |||
@@ -1,56 +1,56 @@ | |||
1 | 1 | ||
2 | 2 | ||
3 | #ifndef OpieBtObex_H | 3 | #ifndef OpieBtObex_H |
4 | #define OpieBtObex_H | 4 | #define OpieBtObex_H |
5 | 5 | ||
6 | #include <qobject.h> | 6 | #include <qobject.h> |
7 | #include <services.h> | 7 | #include <opietooth/services.h> |
8 | #include <manager.h> | 8 | #include <opietooth/manager.h> |
9 | 9 | ||
10 | namespace Opie {namespace Core {class OProcess;}} | 10 | namespace Opie {namespace Core {class OProcess;}} |
11 | class QCopChannel; | 11 | class QCopChannel; |
12 | using namespace OpieTooth; | 12 | using namespace OpieTooth; |
13 | namespace OpieObex { | 13 | namespace OpieObex { |
14 | // Maybe this should be derved from Obex. | 14 | // Maybe this should be derved from Obex. |
15 | class BtObex : public QObject { | 15 | class BtObex : public QObject { |
16 | Q_OBJECT | 16 | Q_OBJECT |
17 | public: | 17 | public: |
18 | /** | 18 | /** |
19 | * BtObex c'tor look | 19 | * BtObex c'tor look |
20 | */ | 20 | */ |
21 | BtObex( QObject *parent, const char* name); | 21 | BtObex( QObject *parent, const char* name); |
22 | /** | 22 | /** |
23 | * d'tor | 23 | * d'tor |
24 | */ | 24 | */ |
25 | ~BtObex(); | 25 | ~BtObex(); |
26 | 26 | ||
27 | /** TODO mbhaynie -- Maybe opd would be a better way to receive. | 27 | /** TODO mbhaynie -- Maybe opd would be a better way to receive. |
28 | * Starting listening to Bluetooth after enabled by the applet | 28 | * Starting listening to Bluetooth after enabled by the applet |
29 | * a signal gets emitted when received a file | 29 | * a signal gets emitted when received a file |
30 | */ | 30 | */ |
31 | void receive(); | 31 | void receive(); |
32 | void send( const QString&, const QString& ); | 32 | void send( const QString&, const QString& ); |
33 | void setReceiveEnabled( bool = false ); | 33 | void setReceiveEnabled( bool = false ); |
34 | signals: | 34 | signals: |
35 | 35 | ||
36 | /** | 36 | /** |
37 | * a signal | 37 | * a signal |
38 | * @param path The path to the received file | 38 | * @param path The path to the received file |
39 | */ | 39 | */ |
40 | void receivedFile( const QString& path); | 40 | void receivedFile( const QString& path); |
41 | /** | 41 | /** |
42 | * error signal if the program couldn't be started or the | 42 | * error signal if the program couldn't be started or the |
43 | * the connection timed out | 43 | * the connection timed out |
44 | */ | 44 | */ |
45 | void error( int ); | 45 | void error( int ); |
46 | /** | 46 | /** |
47 | * The current try to receive data | 47 | * The current try to receive data |
48 | */ | 48 | */ |
49 | void currentTry(unsigned int); | 49 | void currentTry(unsigned int); |
50 | /** | 50 | /** |
51 | * signal sent The file got beamed to the remote location | 51 | * signal sent The file got beamed to the remote location |
52 | */ | 52 | */ |
53 | void sent(bool); | 53 | void sent(bool); |
54 | void done(bool); | 54 | void done(bool); |
55 | 55 | ||
56 | private: | 56 | private: |