~ken-vandine/ubuntu/wily/libqofono/libqofono-0.79

« back to all changes in this revision

Viewing changes to src/qofonomtksettings.h

  • Committer: Ken VanDine
  • Author(s): Ken VanDine, Jonas Drange
  • Date: 2015-05-21 20:16:51 UTC
  • Revision ID: ken.vandine@canonical.com-20150521201651-boa8e4wvl26l369h
Tags: 0.70-0ubuntu4
[ Jonas Drange ]
* debian/patches/connman-resetcontexts.patch
  - Added bindings to Ofono's reset context API (LP: #1338758)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/****************************************************************************
 
2
**
 
3
** Copyright (C) 2014 Canonical Ltd.
 
4
** Contact: jonas.drange@canonical.com
 
5
**
 
6
** GNU Lesser General Public License Usage
 
7
** Alternatively, this file may be used under the terms of the GNU Lesser
 
8
** General Public License version 2.1 as published by the Free Software
 
9
** Foundation and appearing in the file LICENSE.LGPL included in the
 
10
** packaging of this file.  Please review the following information to
 
11
** ensure the GNU Lesser General Public License version 2.1 requirements
 
12
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
 
13
**
 
14
****************************************************************************/
 
15
 
 
16
#ifndef QOFONOMtkSettings_H
 
17
#define QOFONOMtkSettings_H
 
18
 
 
19
#include <QObject>
 
20
#include <QDBusVariant>
 
21
 
 
22
#include "qofono_global.h"
 
23
//! This class is used to access ofono mtk (MediaTek) settings API
 
24
/*!
 
25
 * The API is documented in
 
26
 * https://github.com/rilmodem/ofono/blob/master/doc/mtk-settings-api.txt
 
27
 */
 
28
 
 
29
class QOfonoMtkSettingsPrivate;
 
30
class QOFONOSHARED_EXPORT QOfonoMtkSettings : public QObject
 
31
{
 
32
    Q_OBJECT
 
33
    Q_PROPERTY(QString modemPath READ modemPath WRITE setModemPath NOTIFY modemPathChanged)
 
34
    Q_PROPERTY(bool has3G READ has3G WRITE setHas3G NOTIFY has3GChanged)
 
35
 
 
36
public:
 
37
    explicit QOfonoMtkSettings(QObject *parent = 0);
 
38
    ~QOfonoMtkSettings();
 
39
 
 
40
    QString modemPath() const;
 
41
    void setModemPath(const QString &path);
 
42
 
 
43
    bool has3G() const;
 
44
    void setHas3G(bool has3G);
 
45
 
 
46
    bool isValid() const;
 
47
Q_SIGNALS:
 
48
    void has3GChanged(bool has3G);
 
49
    void modemPathChanged(const QString &path);
 
50
 
 
51
public slots:
 
52
 
 
53
private:
 
54
    void updateProperty(const QString &property, const QVariant &value);
 
55
 
 
56
    QOfonoMtkSettingsPrivate *d_ptr;
 
57
private slots:
 
58
    void propertyChanged(const QString &property,const QDBusVariant &value);
 
59
};
 
60
 
 
61
#endif // QOFONOMtkSettings_H