author | wimpie <wimpie> | 2004-04-08 01:25:02 (UTC) |
---|---|---|
committer | wimpie <wimpie> | 2004-04-08 01:25:02 (UTC) |
commit | 2ab70064958916733daf1b5f095cef562b2e9163 (patch) (side-by-side diff) | |
tree | 445f054fee55b678dab07e10bd5571b4651586d8 /noncore/settings/networksettings2/bluetooth | |
parent | 93ead8f65765ec7af4c14efeb2758c1cf7bcbd89 (diff) | |
download | opie-2ab70064958916733daf1b5f095cef562b2e9163.zip opie-2ab70064958916733daf1b5f095cef562b2e9163.tar.gz opie-2ab70064958916733daf1b5f095cef562b2e9163.tar.bz2 |
Link with libopiecore2
added linke to btmgr
Diffstat (limited to 'noncore/settings/networksettings2/bluetooth') (more/less context) (show whitespace changes)
4 files changed, 109 insertions, 49 deletions
diff --git a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPGUI.ui b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPGUI.ui index ddb5ddd..498f50b 100644 --- a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPGUI.ui +++ b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPGUI.ui @@ -11,8 +11,8 @@ <rect> <x>0</x> <y>0</y> - <width>283</width> - <height>199</height> + <width>278</width> + <height>339</height> </rect> </property> <property stdset="1"> @@ -28,70 +28,83 @@ <vbox> <property stdset="1"> <name>margin</name> - <number>2</number> + <number>0</number> </property> <property stdset="1"> <name>spacing</name> - <number>2</number> + <number>0</number> </property> <widget> - <class>QLayoutWidget</class> + <class>QCheckBox</class> <property stdset="1"> <name>name</name> - <cstring>Layout4</cstring> + <cstring>AnyPAN_CB</cstring> </property> - <hbox> <property stdset="1"> - <name>margin</name> - <number>0</number> + <name>text</name> + <string>Any available PAN device</string> </property> <property stdset="1"> - <name>spacing</name> - <number>6</number> + <name>checked</name> + <bool>true</bool> </property> + </widget> <widget> - <class>QLabel</class> + <class>QGroupBox</class> <property stdset="1"> <name>name</name> - <cstring>TextLabel4</cstring> + <cstring>GroupBox1</cstring> </property> <property stdset="1"> - <name>text</name> - <string>Name</string> + <name>enabled</name> + <bool>false</bool> </property> - </widget> - <widget> - <class>QLineEdit</class> <property stdset="1"> - <name>name</name> - <cstring>Name_LE</cstring> + <name>title</name> + <string>Select Card</string> </property> - </widget> - </hbox> - </widget> - <widget> - <class>QLabel</class> + <property> + <name>layoutMargin</name> + </property> + <vbox> <property stdset="1"> - <name>name</name> - <cstring>TextLabel3</cstring> + <name>margin</name> + <number>5</number> </property> <property stdset="1"> - <name>text</name> - <string>Description</string> + <name>spacing</name> + <number>6</number> </property> - </widget> <widget> - <class>QMultiLineEdit</class> + <class>QListView</class> + <column> + <property> + <name>text</name> + <string>BDAddress</string> + </property> + <property> + <name>clickable</name> + <bool>true</bool> + </property> + <property> + <name>resizeable</name> + <bool>true</bool> + </property> + </column> <property stdset="1"> <name>name</name> - <cstring>Description_LE</cstring> + <cstring>BTPANServers_LV</cstring> + </property> + <property stdset="1"> + <name>allColumnsShowFocus</name> + <bool>true</bool> </property> </widget> <widget> <class>QLayoutWidget</class> <property stdset="1"> <name>name</name> - <cstring>Layout5</cstring> + <cstring>Layout2</cstring> </property> <hbox> <property stdset="1"> @@ -102,30 +115,57 @@ <name>spacing</name> <number>6</number> </property> - <widget> - <class>QCheckBox</class> - <property stdset="1"> + <spacer> + <property> <name>name</name> - <cstring>Automatic_CB</cstring> + <cstring>Spacer1</cstring> </property> <property stdset="1"> - <name>text</name> - <string>Start automatically</string> + <name>orientation</name> + <enum>Horizontal</enum> </property> - </widget> + <property stdset="1"> + <name>sizeType</name> + <enum>Expanding</enum> + </property> + <property> + <name>sizeHint</name> + <size> + <width>20</width> + <height>20</height> + </size> + </property> + </spacer> <widget> - <class>QCheckBox</class> + <class>QPushButton</class> <property stdset="1"> <name>name</name> - <cstring>Confirm_CB</cstring> + <cstring>BTManager_BUT</cstring> </property> <property stdset="1"> <name>text</name> - <string>Confirm before start</string> + <string>Rescan</string> </property> </widget> </hbox> </widget> </vbox> </widget> + </vbox> +</widget> +<connections> + <connection> + <sender>BTManager_BUT</sender> + <signal>clicked()</signal> + <receiver>BluetoothBNEP_FRM</receiver> + <slot>SLOT_StartBTMgr()</slot> + </connection> + <connection> + <sender>AnyPAN_CB</sender> + <signal>toggled(bool)</signal> + <receiver>GroupBox1</receiver> + <slot>setDisabled(bool)</slot> + </connection> + <slot access="public">SLOT_StartBTMgr()</slot> +</connections> </UI> diff --git a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.cpp b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.cpp index a27f1a7..9a3156b 100644 --- a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.cpp +++ b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.cpp @@ -1,3 +1,5 @@ +#include <qtopia/qcopenvelope_qws.h> + #include <GUIUtils.h> #include "bluetoothBNEPedit.h" @@ -10,9 +12,15 @@ QString BluetoothBNEPEdit::acceptable( void ) { return QString(); } -bool BluetoothBNEPEdit::commit( BluetoothBNEPData & Data ) { +bool BluetoothBNEPEdit::commit( BluetoothBNEPData & ) { return 0; } -void BluetoothBNEPEdit::showData( BluetoothBNEPData & Data ) { +void BluetoothBNEPEdit::showData( BluetoothBNEPData & ) { +} + +void BluetoothBNEPEdit::SLOT_StartBTMgr( void ) { + QCopEnvelope e( "QPE/System", "execute(QString)" ); + e << QString( "bluetooth-manager" ); + } diff --git a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.h b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.h index d546f1e..82d23ad 100644 --- a/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.h +++ b/noncore/settings/networksettings2/bluetooth/bluetoothBNEPedit.h @@ -10,4 +10,8 @@ public : QString acceptable( void ); bool commit( BluetoothBNEPData & Data ); void showData( BluetoothBNEPData & Data ); + +public slots : + + void SLOT_StartBTMgr( void ); }; diff --git a/noncore/settings/networksettings2/bluetooth/bluetooth_NN.cpp b/noncore/settings/networksettings2/bluetooth/bluetooth_NN.cpp index 1d0a0f7..b59b4f0 100644 --- a/noncore/settings/networksettings2/bluetooth/bluetooth_NN.cpp +++ b/noncore/settings/networksettings2/bluetooth/bluetooth_NN.cpp @@ -48,7 +48,7 @@ const char * BluetoothBNEPNetNode::provides( void ) { bool BluetoothBNEPNetNode::generateProperFilesFor( ANetNodeInstance * ) { - return 1; + return 0; } bool BluetoothBNEPNetNode::hasDataFor( const QString & S ) { @@ -56,9 +56,17 @@ bool BluetoothBNEPNetNode::hasDataFor( const QString & S ) { } bool BluetoothBNEPNetNode::generateDeviceDataForCommonFile( - SystemFile & , - long ) { - return 1; + SystemFile & S , + long DevNr) { + QString NIC = genNic( DevNr ); + + if( S.name() == "interfaces" ) { + // generate mapping stanza for this interface + S << "# check if " << NIC << " can be brought UP" << endl; + S << "mapping " << NIC << endl; + S << " script networksettings2-request" << endl << endl; + } + return 0; } QString BluetoothBNEPNetNode::genNic( long nr ) { |