summaryrefslogtreecommitdiff
authorharlekin <harlekin>2002-06-16 15:24:00 (UTC)
committer harlekin <harlekin>2002-06-16 15:24:00 (UTC)
commitdf2185572894877d0b4c524227b204b9f1a2341b (patch) (side-by-side diff)
tree1da3398299a56d8995be9ca3441abb0d666aeb3e
parent0704b913f5da703218f66ddc18a4c6b280577d97 (diff)
downloadopie-df2185572894877d0b4c524227b204b9f1a2341b.zip
opie-df2185572894877d0b4c524227b204b9f1a2341b.tar.gz
opie-df2185572894877d0b4c524227b204b9f1a2341b.tar.bz2
update
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/opietooth/applet/bluezapplet.cpp15
-rw-r--r--noncore/net/opietooth/applet/bluezapplet.h4
2 files changed, 12 insertions, 7 deletions
diff --git a/noncore/net/opietooth/applet/bluezapplet.cpp b/noncore/net/opietooth/applet/bluezapplet.cpp
index 94e29c7..8bb7a93 100644
--- a/noncore/net/opietooth/applet/bluezapplet.cpp
+++ b/noncore/net/opietooth/applet/bluezapplet.cpp
@@ -62,15 +62,15 @@ namespace OpieTooth {
BluezApplet::~BluezApplet() {
}
- int BluezApplet::checkBluezStatus() {
+ bool BluezApplet::checkBluezStatus() {
if (btDevice) {
if (btDevice->isLoaded() ) {
- return 1;
+ return true;
} else {
- return 0;
+ return false;
}
} else {
- return 0;
+ return false;
}
}
@@ -128,19 +128,24 @@ namespace OpieTooth {
switch(ret) {
case 0:
setBluezStatus(0);
+ timerEvent(NULL);
break;
case 1:
setBluezStatus(1);
+ timerEvent(NULL);
break;
case 2:
// start bluetoothmanager
launchManager();
+ timerEvent(NULL);
break;
case 3:
setBluezDiscoveryStatus(0);
+ timerEvent(NULL);
break;
case 4:
setBluezDiscoveryStatus(1);
+ timerEvent(NULL);
break;
//case 7:
// With table of currently-detected devices.
@@ -165,7 +170,7 @@ namespace OpieTooth {
* @param the timer event
*/
void BluezApplet::timerEvent( QTimerEvent * ) {
- int oldactive = bluezactive;
+ bool oldactive = bluezactive;
int olddiscovery = bluezDiscoveryActive;
bluezactive = checkBluezStatus();
diff --git a/noncore/net/opietooth/applet/bluezapplet.h b/noncore/net/opietooth/applet/bluezapplet.h
index da05a18..6a8a00e 100644
--- a/noncore/net/opietooth/applet/bluezapplet.h
+++ b/noncore/net/opietooth/applet/bluezapplet.h
@@ -50,7 +50,7 @@ public slots:
void mousePressEvent( QMouseEvent * );
void paintEvent( QPaintEvent* );
void launchManager();
- int checkBluezStatus();
+ bool checkBluezStatus();
int setBluezStatus(int);
int checkBluezDiscoveryStatus();
int setBluezDiscoveryStatus(int);
@@ -61,7 +61,7 @@ public slots:
QPixmap bluezOnPixmap;
QPixmap bluezOffPixmap;
QPixmap bluezDiscoveryOnPixmap;
- int bluezactive;
+ bool bluezactive;
int bluezDiscoveryActive;
private slots: