~ubuntu-branches/ubuntu/gutsy/kdebase-workspace/gutsy-backports

« back to all changes in this revision

Viewing changes to solid/control/backends/fakebluetooth/fakebluetoothremotedevice.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2007-09-05 20:45:14 UTC
  • Revision ID: james.westby@ubuntu.com-20070905204514-632hhspl0nvrc84i
Tags: upstream-3.93.0
ImportĀ upstreamĀ versionĀ 3.93.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*  This file is part of the KDE project
 
2
    Copyright (C) 2007 Daniel Gollub <dgollub@suse.de>
 
3
 
 
4
 
 
5
    This library is free software; you can redistribute it and/or
 
6
    modify it under the terms of the GNU Library General Public
 
7
    License version 2 as published by the Free Software Foundation.
 
8
 
 
9
    This library is distributed in the hope that it will be useful,
 
10
    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
11
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
12
    Library General Public License for more details.
 
13
 
 
14
    You should have received a copy of the GNU Library General Public License
 
15
    along with this library; see the file COPYING.LIB.  If not, write to
 
16
    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 
17
    Boston, MA 02110-1301, USA.
 
18
 
 
19
*/
 
20
 
 
21
#include <QStringList>
 
22
 
 
23
#include "fakebluetoothmanager.h"
 
24
#include "fakebluetoothinterface.h"
 
25
#include "fakebluetoothremotedevice.h"
 
26
 
 
27
#include <kdebug.h>
 
28
 
 
29
FakeBluetoothRemoteDevice::FakeBluetoothRemoteDevice(const QMap<QString, QVariant>  & propertyMap, QObject * parent)
 
30
        : Solid::Control::Ifaces::BluetoothRemoteDevice(parent), mPropertyMap(propertyMap)
 
31
{
 
32
 
 
33
    mUbi = mPropertyMap["ubi"].toString();
 
34
 
 
35
    kDebug() << "UBI: " << mUbi;
 
36
 
 
37
    mAddress = mPropertyMap["address"].toString();
 
38
    mConnected = mPropertyMap["connected"].toBool();
 
39
    mVersion = mPropertyMap["version"].toString();
 
40
    mRevision = mPropertyMap["revision"].toString();
 
41
    mManufacturer = mPropertyMap["manufacturer"].toString();
 
42
    mCompany = mPropertyMap["company"].toString();
 
43
    mMajorClass = mPropertyMap["majorClass"].toString();
 
44
    mMinorClass = mPropertyMap["minorClass"].toString();
 
45
    mServiceClass.append(mPropertyMap["serviceClasses"].toString());
 
46
    mName = mPropertyMap["name"].toString();
 
47
    mAlias = mPropertyMap["alias"].toString();
 
48
    mLastSeen = mPropertyMap["lastSeen"].toString();
 
49
    mLastUsed = mPropertyMap["lastUsed"].toString();
 
50
    mBonded = mPropertyMap["bonded"].toBool();
 
51
    mPinCodeLength = mPropertyMap["pinCodeLength"].toInt();
 
52
    mEncryptionKeySize = mPropertyMap["encryptionKeySize"].toInt();
 
53
 
 
54
}
 
55
 
 
56
FakeBluetoothRemoteDevice::~FakeBluetoothRemoteDevice()
 
57
{}
 
58
 
 
59
// TODO
 
60
KJob *FakeBluetoothRemoteDevice::createBonding()
 
61
{
 
62
    mBonded = true;
 
63
    return NULL;
 
64
}
 
65
 
 
66
#include "fakebluetoothremotedevice.moc"