Diffstat (limited to 'noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp b/noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp index fc76301..4469129 100644 --- a/noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp +++ b/noncore/net/opietooth/manager/rfcommassigndialogimpl.cpp | |||
@@ -50,70 +50,70 @@ void RfcommAssignDialog::newDevice( const QString & mac ) | |||
50 | { | 50 | { |
51 | 51 | ||
52 | for ( int i = 0 ; i < m_range; i++ ) | 52 | for ( int i = 0 ; i < m_range; i++ ) |
53 | { | 53 | { |
54 | 54 | ||
55 | QMap<QString, RfCommConfObject*>::Iterator it; | 55 | QMap<QString, RfCommConfObject*>::Iterator it; |
56 | it = confHandler->foundEntries().find( QString("%1").arg( i ) ); | 56 | it = confHandler->foundEntries().find( QString("%1").arg( i ) ); |
57 | // make sure that rfcommX is not assigned yet | 57 | // make sure that rfcommX is not assigned yet |
58 | if ( it == confHandler->foundEntries().end() ) | 58 | if ( it == confHandler->foundEntries().end() ) |
59 | { | 59 | { |
60 | QDialog dialog( this, "newdevice", true, WStyle_ContextHelp ); | 60 | QDialog dialog( this, "newdevice", true, WStyle_ContextHelp ); |
61 | 61 | ||
62 | RfcommDialogItem *newDev = new RfcommDialogItem( &dialog ); | 62 | RfcommDialogItem *newDev = new RfcommDialogItem( &dialog ); |
63 | newDev->setIdent( i ); | 63 | newDev->setIdent( i ); |
64 | newDev->setMac( mac ); | 64 | newDev->setMac( mac ); |
65 | 65 | ||
66 | if ( QPEApplication::execDialog( &dialog ) == QDialog::Accepted ) | 66 | if ( QPEApplication::execDialog( &dialog ) == QDialog::Accepted ) |
67 | { | 67 | { |
68 | RfcommDialogItem *rfcomm = new RfcommDialogItem( m_box ); | 68 | RfcommDialogItem *rfcomm = new RfcommDialogItem( m_box ); |
69 | m_itemList.insert( i , rfcomm ); | 69 | m_itemList.insert( i , rfcomm ); |
70 | rfcomm->setIdent( i ); | 70 | rfcomm->setIdent( i ); |
71 | rfcomm->setMac( mac ); | 71 | rfcomm->setMac( mac ); |
72 | rfcomm->setChannel( newDev->channel() ); | 72 | rfcomm->setChannel( newDev->channel() ); |
73 | rfcomm->setComment( newDev->comment() ); | 73 | rfcomm->setComment( newDev->comment() ); |
74 | qDebug( "New device set up" ); | 74 | odebug << "New device set up" << oendl; |
75 | } | 75 | } |
76 | } | 76 | } |
77 | } | 77 | } |
78 | } | 78 | } |
79 | 79 | ||
80 | void RfcommAssignDialog::loadConfig() | 80 | void RfcommAssignDialog::loadConfig() |
81 | { | 81 | { |
82 | 82 | ||
83 | //Config cfg( "bluetoothmanager-rfcommbind" ); | 83 | //Config cfg( "bluetoothmanager-rfcommbind" ); |
84 | 84 | ||
85 | for ( int i = 0 ; i < m_range; i++ ) | 85 | for ( int i = 0 ; i < m_range; i++ ) |
86 | { | 86 | { |
87 | // cfg.setGroup( QString("%1").arg( i ) ); | 87 | // cfg.setGroup( QString("%1").arg( i ) ); |
88 | RfcommDialogItem *rfcomm = new RfcommDialogItem( m_box ); | 88 | RfcommDialogItem *rfcomm = new RfcommDialogItem( m_box ); |
89 | m_itemList.insert( i , rfcomm ); | 89 | m_itemList.insert( i , rfcomm ); |
90 | rfcomm->setIdent( i ); | 90 | rfcomm->setIdent( i ); |
91 | QMap<QString, RfCommConfObject*>::Iterator it; | 91 | QMap<QString, RfCommConfObject*>::Iterator it; |
92 | it = confHandler->foundEntries().find( QString("%1").arg( i ) ); | 92 | it = confHandler->foundEntries().find( QString("%1").arg( i ) ); |
93 | if ( it != confHandler->foundEntries().end() ) | 93 | if ( it != confHandler->foundEntries().end() ) |
94 | { | 94 | { |
95 | qDebug( "Found key in foundEntries() " ); | 95 | odebug << "Found key in foundEntries() " << oendl; |
96 | rfcomm->setMac( it.data()->mac() ); | 96 | rfcomm->setMac( it.data()->mac() ); |
97 | rfcomm->setChannel( it.data()->channel() ); | 97 | rfcomm->setChannel( it.data()->channel() ); |
98 | rfcomm->setComment( it.data()->comment() ); | 98 | rfcomm->setComment( it.data()->comment() ); |
99 | } | 99 | } |
100 | /* Use rfcomm.conf directly for now | 100 | /* Use rfcomm.conf directly for now |
101 | * rfcomm->setMac( cfg.readEntry( "mac", "" ) ); | 101 | * rfcomm->setMac( cfg.readEntry( "mac", "" ) ); |
102 | * rfcomm->setChannel( cfg.readNumEntry( "channel", 1 ) ); | 102 | * rfcomm->setChannel( cfg.readNumEntry( "channel", 1 ) ); |
103 | * rfcomm->setComment( cfg.readEntry( "comment", "" ) ); | 103 | * rfcomm->setComment( cfg.readEntry( "comment", "" ) ); |
104 | */ | 104 | */ |
105 | } | 105 | } |
106 | } | 106 | } |
107 | 107 | ||
108 | 108 | ||
109 | void RfcommAssignDialog::saveConfig() | 109 | void RfcommAssignDialog::saveConfig() |
110 | { | 110 | { |
111 | 111 | ||
112 | //Config cfg( "bluetoothmanager-rfcommbind" ); | 112 | //Config cfg( "bluetoothmanager-rfcommbind" ); |
113 | 113 | ||
114 | QMap< int, RfcommDialogItem*>::Iterator it; | 114 | QMap< int, RfcommDialogItem*>::Iterator it; |
115 | 115 | ||
116 | QMap< QString, RfCommConfObject*> outMap; | 116 | QMap< QString, RfCommConfObject*> outMap; |
117 | 117 | ||
118 | for( it = m_itemList.begin(); it != m_itemList.end(); ++it ) | 118 | for( it = m_itemList.begin(); it != m_itemList.end(); ++it ) |
119 | { | 119 | { |