Commit 34dba667 authored by Raine Makelainen's avatar Raine Makelainen

[nemo-systemsettings] Expose hasAndroidSupport from DeviceInfo. Contributes to JB#40915

parent 0c303461
......@@ -31,6 +31,7 @@
#include "deviceinfo.h"
#include <QFile>
#include <QSet>
#include <ssusysinfo.h>
......@@ -95,3 +96,8 @@ bool DeviceInfo::hasHardwareKey(Qt::Key key) const
Q_D(const DeviceInfo);
return d->m_keys.contains(key);
}
bool DeviceInfo::hasAndroidSupport() const
{
return QFile::exists(QLatin1String("/opt/alien/system/bin/alien_launcher"));
}
......@@ -43,6 +43,7 @@ class DeviceInfoPrivate;
class SYSTEMSETTINGS_EXPORT DeviceInfo: public QObject
{
Q_OBJECT
Q_PROPERTY(bool hasAndroidSupport READ hasAndroidSupport CONSTANT)
public:
enum Feature {
......@@ -97,9 +98,12 @@ public:
DeviceInfo(QObject *parent = 0);
~DeviceInfo();
Q_INVOKABLE bool hasFeature(DeviceInfo::Feature feature) const;
Q_INVOKABLE bool hasHardwareKey(Qt::Key key) const;
bool hasAndroidSupport() const;
private:
DeviceInfoPrivate *d_ptr;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment