author | zecke <zecke> | 2002-10-13 15:31:12 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-10-13 15:31:12 (UTC) |
commit | 6a9726437a59cf3b18bf57d6e20fb2dfaaa2fc34 (patch) (unidiff) | |
tree | 14fa6710ef6d80fa213250a97f13253eb88a80cd /noncore/apps/opie-console/receive_layer.cpp | |
parent | 5db679753dac04095a2fa4b03297785ed4ba4030 (diff) | |
download | opie-6a9726437a59cf3b18bf57d6e20fb2dfaaa2fc34.zip opie-6a9726437a59cf3b18bf57d6e20fb2dfaaa2fc34.tar.gz opie-6a9726437a59cf3b18bf57d6e20fb2dfaaa2fc34.tar.bz2 |
Move some stuff in filetransfer around
make pid == 0 after a finished process.
Introduce the FileReceive class
it does not parse progress though
Diffstat (limited to 'noncore/apps/opie-console/receive_layer.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/receive_layer.cpp | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/noncore/apps/opie-console/receive_layer.cpp b/noncore/apps/opie-console/receive_layer.cpp new file mode 100644 index 0000000..05e2c67 --- a/dev/null +++ b/noncore/apps/opie-console/receive_layer.cpp | |||
@@ -0,0 +1,33 @@ | |||
1 | #include <unistd.h> | ||
2 | |||
3 | #include <qstring.h> | ||
4 | #include <qfile.h> | ||
5 | |||
6 | #include "io_layer.h" | ||
7 | #include "receive_layer.h" | ||
8 | |||
9 | ReceiveLayer::ReceiveLayer( IOLayer* lay, const QString& startDir ) | ||
10 | : QObject(), m_curDir( startDir ), m_layer(lay ) | ||
11 | { | ||
12 | |||
13 | } | ||
14 | ReceiveLayer::~ReceiveLayer() { | ||
15 | |||
16 | } | ||
17 | IOLayer* ReceiveLayer::layer() { | ||
18 | return m_layer; | ||
19 | } | ||
20 | QString ReceiveLayer::currentDir()const{ | ||
21 | if (m_curDir.isEmpty() ) | ||
22 | return QString::fromLocal8Bit( ::getwd(NULL) ); | ||
23 | return m_curDir; | ||
24 | } | ||
25 | void ReceiveLayer::changeDir( const QString& str) { | ||
26 | ::chdir( str.latin1() ); | ||
27 | } | ||
28 | void ReceiveLayer::receive( const QString& dir, Mode, Features ) { | ||
29 | receive( dir ); | ||
30 | } | ||
31 | void ReceiveLayer::cancel() { | ||
32 | |||
33 | } | ||