-rw-r--r-- | noncore/net/opietooth/manager/bluebase.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/noncore/net/opietooth/manager/bluebase.cpp b/noncore/net/opietooth/manager/bluebase.cpp index 0385cb1..3e7e2ab 100644 --- a/noncore/net/opietooth/manager/bluebase.cpp +++ b/noncore/net/opietooth/manager/bluebase.cpp @@ -191,52 +191,53 @@ namespace OpieTooth { qDebug((*it).latin1() ); Config conf((*it)); conf.setGroup("Info"); name = conf.readEntry("name", "Error"); qDebug("MAC: " + mac); qDebug("NAME: " + name); RemoteDevice currentDevice = RemoteDevice( mac , name ); loadedDevices->append( ¤tDevice ); } addSearchedDevices( *loadedDevices ); } /** * Write the list of allready known devices * */ void BlueBase::writeSavedDevices() { QListViewItemIterator it( ListView2 ); for ( ; it.current(); ++it ) { // seperate config file for each device, to store more information in future. // TO FIX: BTLISTITEM!!! + qDebug( "/Settings/bluetooth/" + (((BTListItem*)it.current())->mac()) + ".conf"); + Config conf( QDir::homeDirPath() + "/Settings/bluetooth/" + (((BTListItem*)it.current())->mac()) + ".conf", Config::File ); - // Config conf( QDir::homeDirPath() + "/Settings/bluetooth/" + (((BTListItem)it.current())->mac()) + ".conf", Config::File ); - // conf.setGroup( "Info" ); - // conf.writeEntry( "name", it.current()->name() ); + conf.setGroup( "Info" ); + conf.writeEntry( "name", ((BTListItem*)it.current())->name() ); } } /** * Set up the gui */ void BlueBase::initGui() { StatusLabel->setText( getStatus() ); // maybe move it to getStatus() cryptCheckBox->setChecked( useEncryption ); authCheckBox->setChecked( enableAuthentification ); pagescanCheckBox->setChecked( enablePagescan ); inquiryscanCheckBox->setChecked( enableInquiryscan ); deviceNameLine->setText( deviceName ); passkeyLine->setText( defaultPasskey ); // set info tab setInfo(); } /** * Get the status informations and returns it |