summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-console/io_irda.cpp
Unidiff
Diffstat (limited to 'noncore/apps/opie-console/io_irda.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/opie-console/io_irda.cpp20
1 files changed, 2 insertions, 18 deletions
diff --git a/noncore/apps/opie-console/io_irda.cpp b/noncore/apps/opie-console/io_irda.cpp
index 38542f5..9d27c85 100644
--- a/noncore/apps/opie-console/io_irda.cpp
+++ b/noncore/apps/opie-console/io_irda.cpp
@@ -1,12 +1,8 @@
1#include "io_irda.h" 1#include "io_irda.h"
2 2
3/* OPIE */
4#include <opie2/odebug.h>
5using namespace Opie::Core;
6
7IOIrda::IOIrda( const Profile &config ) : IOSerial( config ) { 3IOIrda::IOIrda( const Profile &config ) : IOSerial( config ) {
8 m_attach = 0; 4 m_attach = 0;
9} 5}
10 6
11 7
12IOIrda::~IOIrda() { 8IOIrda::~IOIrda() {
@@ -24,23 +20,22 @@ void IOIrda::close() {
24} 20}
25 21
26bool IOIrda::open() { 22bool IOIrda::open() {
27 bool ret; 23 bool ret;
28 24
29 // irdaattach here 25 // irdaattach here
30 m_attach = new OProcess(); 26 m_attach = new Opie::Core::OProcess();
31 *m_attach << "irattach /dev/ttyS2 -s"; 27 *m_attach << "irattach /dev/ttyS2 -s";
32 28
33 connect( m_attach, SIGNAL( processExited(Opie::Core::OProcess*) ), 29 connect( m_attach, SIGNAL( processExited(Opie::Core::OProcess*) ),
34 this, SLOT( slotExited(Opie::Core::OProcess*) ) ); 30 this, SLOT( slotExited(Opie::Core::OProcess*) ) );
35 31
36 if ( m_attach->start() ) { 32 if ( m_attach->start() ) {
37 ret= IOSerial::open(); 33 ret= IOSerial::open();
38 } else { 34 } else {
39 // emit error!!! 35 // emit error!!!
40 owarn << "could not attach to device" << oendl;
41 delete m_attach; 36 delete m_attach;
42 m_attach = 0l; 37 m_attach = 0l;
43 } 38 }
44 return ret; 39 return ret;
45} 40}
46 41
@@ -59,22 +54,11 @@ QString IOIrda::identifier() const {
59} 54}
60 55
61QString IOIrda::name() const { 56QString IOIrda::name() const {
62 return "Irda IO Layer"; 57 return "Irda IO Layer";
63} 58}
64 59
65void IOIrda::slotExited(OProcess* proc ){ 60void IOIrda::slotExited(Opie::Core::OProcess* proc ){
66 close(); 61 close();
67 delete proc; 62 delete proc;
68} 63}
69 64
70QBitArray IOIrda::supports()const {
71 return QBitArray( 3 );
72}
73
74bool IOIrda::isConnected() {
75 return false;
76}
77
78void IOIrda::send(const QByteArray &data) {
79 odebug << "Please overload me..." << oendl;
80}