summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/bluetooth
Unidiff
Diffstat (limited to 'noncore/settings/networksettings2/bluetooth') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/networksettings2/bluetooth/bluetoothRFCOMMrun.cpp8
-rw-r--r--noncore/settings/networksettings2/bluetooth/config.in2
2 files changed, 5 insertions, 5 deletions
diff --git a/noncore/settings/networksettings2/bluetooth/bluetoothRFCOMMrun.cpp b/noncore/settings/networksettings2/bluetooth/bluetoothRFCOMMrun.cpp
index ef6878a..3df7f5c 100644
--- a/noncore/settings/networksettings2/bluetooth/bluetoothRFCOMMrun.cpp
+++ b/noncore/settings/networksettings2/bluetooth/bluetoothRFCOMMrun.cpp
@@ -15,25 +15,25 @@ BluetoothRFCOMMRun::~BluetoothRFCOMMRun( void ) {
15} 15}
16 16
17State_t BluetoothRFCOMMRun::detectState( void ) { 17State_t BluetoothRFCOMMRun::detectState( void ) {
18 18
19 if( ! OT ) { 19 if( ! OT ) {
20 OT = OTGateway::getOTGateway(); 20 OT = OTGateway::getOTGateway();
21 } 21 }
22 22
23 if( deviceNrOfConnection() >= 0 ) { 23 if( deviceNrOfConnection() >= 0 ) {
24 return Available; 24 return Available;
25 } 25 }
26 26
27 owarn << "Bluetooth " 27 odebug << "Bluetooth "
28 << OT->isEnabled() 28 << OT->isEnabled()
29 << oendl; 29 << oendl;
30 30
31 return ( OT->isEnabled() ) ? Off : Unavailable; 31 return ( OT->isEnabled() ) ? Off : Unavailable;
32} 32}
33 33
34QString BluetoothRFCOMMRun::setMyState( NodeCollection *, 34QString BluetoothRFCOMMRun::setMyState( NodeCollection *,
35 Action_t A, 35 Action_t A,
36 bool ) { 36 bool ) {
37 37
38 if( OT ) { 38 if( OT ) {
39 OTGateway::getOTGateway(); 39 OTGateway::getOTGateway();
@@ -110,25 +110,25 @@ RFCOMMChannel * BluetoothRFCOMMRun::getChannel( void ) {
110 110
111 V->addWidget( L ); 111 V->addWidget( L );
112 V->addWidget( LB ); 112 V->addWidget( LB );
113 113
114 Dlg->resize( 100, 100 ); 114 Dlg->resize( 100, 100 );
115 Dlg->move( 20, 115 Dlg->move( 20,
116 (qApp->desktop()->height()-100)/2 ); 116 (qApp->desktop()->height()-100)/2 );
117 117
118 if( Dlg->exec() == QDialog::Accepted ) { 118 if( Dlg->exec() == QDialog::Accepted ) {
119 unsigned int i = 0; 119 unsigned int i = 0;
120 for( i = 0; i < Data->Devices.count(); i ++ ) { 120 for( i = 0; i < Data->Devices.count(); i ++ ) {
121 if( LB->isSelected(i) ) { 121 if( LB->isSelected(i) ) {
122 owarn << "Selected " << Data->Devices[i]->Name << oendl; 122 odebug << "Selected " << Data->Devices[i]->Name << oendl;
123 Ch = Data->Devices[i]; 123 Ch = Data->Devices[i];
124 break; 124 break;
125 } 125 }
126 } 126 }
127 } 127 }
128 128
129 delete Dlg; 129 delete Dlg;
130 return Ch; 130 return Ch;
131} 131}
132 132
133QString BluetoothRFCOMMRun::deviceFile( void ) { 133QString BluetoothRFCOMMRun::deviceFile( void ) {
134 if( deviceNrOfConnection() >= 0 ) { 134 if( deviceNrOfConnection() >= 0 ) {
@@ -138,27 +138,27 @@ QString BluetoothRFCOMMRun::deviceFile( void ) {
138 } 138 }
139 return QString(); 139 return QString();
140} 140}
141 141
142int BluetoothRFCOMMRun::deviceNrOfConnection( void ) { 142int BluetoothRFCOMMRun::deviceNrOfConnection( void ) {
143 143
144 if( ! OT ) { 144 if( ! OT ) {
145 OT = OTGateway::getOTGateway(); 145 OT = OTGateway::getOTGateway();
146 } 146 }
147 147
148 DeviceNr = -1; 148 DeviceNr = -1;
149 for( unsigned int i = 0; i < Data->Devices.count(); i ++ ) { 149 for( unsigned int i = 0; i < Data->Devices.count(); i ++ ) {
150 owarn << "Check for rfcomm on " 150 odebug << "Check for rfcomm on "
151 << Data->Devices[i]->BDAddress 151 << Data->Devices[i]->BDAddress
152 << " " 152 << " "
153 << Data->Devices[i]->Channel 153 << Data->Devices[i]->Channel
154 << oendl; 154 << oendl;
155 if( ( DeviceNr = OT->connectedToRFCommChannel( 155 if( ( DeviceNr = OT->connectedToRFCommChannel(
156 OTDeviceAddress( Data->Devices[i]->BDAddress ), 156 OTDeviceAddress( Data->Devices[i]->BDAddress ),
157 Data->Devices[i]->Channel ) ) >= 0 ) { 157 Data->Devices[i]->Channel ) ) >= 0 ) {
158 owarn << "Up " 158 odebug << "Up "
159 << oendl; 159 << oendl;
160 break; 160 break;
161 } 161 }
162 } 162 }
163 return DeviceNr; 163 return DeviceNr;
164} 164}
diff --git a/noncore/settings/networksettings2/bluetooth/config.in b/noncore/settings/networksettings2/bluetooth/config.in
index 398cff1..1a76f96 100644
--- a/noncore/settings/networksettings2/bluetooth/config.in
+++ b/noncore/settings/networksettings2/bluetooth/config.in
@@ -1,4 +1,4 @@
1 config NS2BT 1 config NS2BT
2 boolean "opie-networksettings2plugin-bluetooth (set up BLUETOOTH)" 2 boolean "opie-networksettings2plugin-bluetooth (set up BLUETOOTH)"
3 default "n" if NS2 3 default "n" if NS2
4 depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE && NS2CORE && NS2OPIETOOTH 4 depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE && NS2CORE && NS2OPIETOOTH && LIBBLUEZ_DEP