summaryrefslogtreecommitdiff
authorharlekin <harlekin>2002-06-23 09:10:55 (UTC)
committer harlekin <harlekin>2002-06-23 09:10:55 (UTC)
commit1d773d5df7038410c498d38a68a9569c1350975a (patch) (unidiff)
treea14334997864cf5b01302e9aa05c0c09c72a86b3
parente9f053439c8409ea2e1e57de9bf6f764f994b222 (diff)
downloadopie-1d773d5df7038410c498d38a68a9569c1350975a.zip
opie-1d773d5df7038410c498d38a68a9569c1350975a.tar.gz
opie-1d773d5df7038410c498d38a68a9569c1350975a.tar.bz2
small load save update
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/opietooth/manager/bluebase.cpp27
1 files changed, 16 insertions, 11 deletions
diff --git a/noncore/net/opietooth/manager/bluebase.cpp b/noncore/net/opietooth/manager/bluebase.cpp
index 5d742b7..cc51405 100644
--- a/noncore/net/opietooth/manager/bluebase.cpp
+++ b/noncore/net/opietooth/manager/bluebase.cpp
@@ -80,5 +80,4 @@ namespace OpieTooth {
80 initGui(); 80 initGui();
81 81
82
83 //TESTING 82 //TESTING
84 ListView2->setRootIsDecorated(true); 83 ListView2->setRootIsDecorated(true);
@@ -135,10 +134,23 @@ namespace OpieTooth {
135 QList<RemoteDevice> *loadedDevices = new QList<RemoteDevice>; 134 QList<RemoteDevice> *loadedDevices = new QList<RemoteDevice>;
136 135
137 Config deviceListSave( QDir::homeDirPath() + "/Settings/bluetooth/devicelist.conf", Config::File ); 136 QDir deviceListSave( QDir::homeDirPath() + "/Settings/bluetooth/");
137 // list of .conf files
138 QStringList devicesFileList = deviceListSave.entryList();
138 139
140 // cut .conf of to get the mac and also read the name entry in it.
139 141
140 // RemoteDevice *currentDevice = RemoteDevice( , ); 142 for ( QStringList::Iterator it = devicesFileList.begin(); it != devicesFileList.end(); ++it ) {
141 //loadedDevices->append( currentDevice );
142 143
144 QString name;
145 QString mac;
146 qDebug((*it).latin1() );
147 Config conf((*it));
148 conf.setGroup("Info");
149 name = conf.readEntry("name", "Error");
150 qDebug("MAC: " + mac);
151 qDebug("NAME: " + name);
152 RemoteDevice currentDevice = RemoteDevice( mac , name );
153 loadedDevices->append( &currentDevice );
154 }
143 addSearchedDevices( *loadedDevices ); 155 addSearchedDevices( *loadedDevices );
144 } 156 }
@@ -192,5 +204,4 @@ namespace OpieTooth {
192 204
193 return (infoString); 205 return (infoString);
194
195 } 206 }
196 207
@@ -213,5 +224,4 @@ namespace OpieTooth {
213 box->setText( tr( "Changes applied" ) ); 224 box->setText( tr( "Changes applied" ) );
214 box->show(); 225 box->show();
215
216 // falls nötig hcid killhupen - die funktionalität adden 226 // falls nötig hcid killhupen - die funktionalität adden
217 } 227 }
@@ -262,5 +272,4 @@ namespace OpieTooth {
262 void BlueBase::startServiceActionHold( QListViewItem * item, const QPoint & point, int column ) { 272 void BlueBase::startServiceActionHold( QListViewItem * item, const QPoint & point, int column ) {
263 273
264
265 } 274 }
266 275
@@ -306,6 +315,4 @@ namespace OpieTooth {
306 QValueList<OpieTooth::Services>::Iterator it2; 315 QValueList<OpieTooth::Services>::Iterator it2;
307 316
308
309
310 QListViewItem * serviceItem; 317 QListViewItem * serviceItem;
311 318
@@ -333,5 +340,4 @@ namespace OpieTooth {
333 340
334 // search by mac 341 // search by mac
335 //
336 localDevice->isAvailable( device->mac() ); 342 localDevice->isAvailable( device->mac() );
337 343
@@ -366,5 +372,4 @@ namespace OpieTooth {
366 writeSavedDevices(); 372 writeSavedDevices();
367 } 373 }
368
369} 374}
370 375