author | harlekin <harlekin> | 2003-01-16 19:50:25 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2003-01-16 19:50:25 (UTC) |
commit | 0ec2acb93d322caefff68191678141d72f8d6da7 (patch) (unidiff) | |
tree | e49a373c2e676291c228ca41cb0defee98e75770 | |
parent | 7957a2f100eb687e63cd3593097c5914539c7406 (diff) | |
download | opie-0ec2acb93d322caefff68191678141d72f8d6da7.zip opie-0ec2acb93d322caefff68191678141d72f8d6da7.tar.gz opie-0ec2acb93d322caefff68191678141d72f8d6da7.tar.bz2 |
adapt to new bscp on ipaq
-rw-r--r-- | noncore/net/opietooth/applet/bluezapplet.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/net/opietooth/applet/bluezapplet.cpp b/noncore/net/opietooth/applet/bluezapplet.cpp index c0ad246..3fdbde0 100644 --- a/noncore/net/opietooth/applet/bluezapplet.cpp +++ b/noncore/net/opietooth/applet/bluezapplet.cpp | |||
@@ -33,74 +33,74 @@ | |||
33 | #include <qpe/resource.h> | 33 | #include <qpe/resource.h> |
34 | #include <qpe/qcopenvelope_qws.h> | 34 | #include <qpe/qcopenvelope_qws.h> |
35 | #include <qpe/resource.h> | 35 | #include <qpe/resource.h> |
36 | #include <qpe/config.h> | 36 | #include <qpe/config.h> |
37 | 37 | ||
38 | #include <qpoint.h> | 38 | #include <qpoint.h> |
39 | #include <qpainter.h> | 39 | #include <qpainter.h> |
40 | #include <qlayout.h> | 40 | #include <qlayout.h> |
41 | #include <qframe.h> | 41 | #include <qframe.h> |
42 | #include <qpixmap.h> | 42 | #include <qpixmap.h> |
43 | #include <qstring.h> | 43 | #include <qstring.h> |
44 | #include <qtimer.h> | 44 | #include <qtimer.h> |
45 | #include <qpopupmenu.h> | 45 | #include <qpopupmenu.h> |
46 | 46 | ||
47 | #include <device.h> | 47 | #include <device.h> |
48 | 48 | ||
49 | namespace OpieTooth { | 49 | namespace OpieTooth { |
50 | 50 | ||
51 | BluezApplet::BluezApplet( QWidget *parent, const char *name ) : QWidget( parent, name ) { | 51 | BluezApplet::BluezApplet( QWidget *parent, const char *name ) : QWidget( parent, name ) { |
52 | setFixedHeight( 18 ); | 52 | setFixedHeight( 18 ); |
53 | setFixedWidth( 14 ); | 53 | setFixedWidth( 14 ); |
54 | bluezOnPixmap = Resource::loadPixmap( "bluetoothapplet/bluezon" ); | 54 | bluezOnPixmap = Resource::loadPixmap( "bluetoothapplet/bluezon" ); |
55 | bluezOffPixmap = Resource::loadPixmap( "bluetoothapplet/bluezoff" ); | 55 | bluezOffPixmap = Resource::loadPixmap( "bluetoothapplet/bluezoff" ); |
56 | // bluezDiscoveryOnPixmap = Resource::loadPixmap( "bluetoothapplet/magglass" ); | 56 | // bluezDiscoveryOnPixmap = Resource::loadPixmap( "bluetoothapplet/magglass" ); |
57 | startTimer(5000); | 57 | startTimer(4000); |
58 | btDevice = 0; | 58 | btDevice = 0; |
59 | bluezactive = false; | 59 | bluezactive = false; |
60 | bluezDiscoveryActive = false; | 60 | bluezDiscoveryActive = false; |
61 | 61 | ||
62 | } | 62 | } |
63 | 63 | ||
64 | BluezApplet::~BluezApplet() { | 64 | BluezApplet::~BluezApplet() { |
65 | } | 65 | } |
66 | 66 | ||
67 | bool BluezApplet::checkBluezStatus() { | 67 | bool BluezApplet::checkBluezStatus() { |
68 | if (btDevice) { | 68 | if (btDevice) { |
69 | if (btDevice->isLoaded() ) { | 69 | if (btDevice->isLoaded() ) { |
70 | return true; | 70 | return true; |
71 | } else { | 71 | } else { |
72 | return false; | 72 | return false; |
73 | } | 73 | } |
74 | } else { | 74 | } else { |
75 | return false; | 75 | return false; |
76 | } | 76 | } |
77 | } | 77 | } |
78 | 78 | ||
79 | int BluezApplet::setBluezStatus(int c) { | 79 | int BluezApplet::setBluezStatus(int c) { |
80 | 80 | ||
81 | if (c == 1) { | 81 | if (c == 1) { |
82 | btDevice = new Device("/dev/ttySB0", "csr" ); | 82 | btDevice = new Device("/dev/ttySB0", "bcsp", "230400" ); |
83 | } else { | 83 | } else { |
84 | if (btDevice) { | 84 | if (btDevice) { |
85 | delete btDevice; | 85 | delete btDevice; |
86 | btDevice = 0; | 86 | btDevice = 0; |
87 | } | 87 | } |
88 | } | 88 | } |
89 | return 0; | 89 | return 0; |
90 | } | 90 | } |
91 | 91 | ||
92 | int BluezApplet::checkBluezDiscoveryStatus() { | 92 | int BluezApplet::checkBluezDiscoveryStatus() { |
93 | } | 93 | } |
94 | 94 | ||
95 | int BluezApplet::setBluezDiscoveryStatus(int d) { | 95 | int BluezApplet::setBluezDiscoveryStatus(int d) { |
96 | } | 96 | } |
97 | 97 | ||
98 | void BluezApplet::mousePressEvent( QMouseEvent *) { | 98 | void BluezApplet::mousePressEvent( QMouseEvent *) { |
99 | 99 | ||
100 | QPopupMenu *menu = new QPopupMenu(); | 100 | QPopupMenu *menu = new QPopupMenu(); |
101 | QPopupMenu *signal = new QPopupMenu(); | 101 | QPopupMenu *signal = new QPopupMenu(); |
102 | int ret=0; | 102 | int ret=0; |
103 | 103 | ||
104 | /* Refresh active state */ | 104 | /* Refresh active state */ |
105 | timerEvent( 0 ); | 105 | timerEvent( 0 ); |
106 | 106 | ||