summaryrefslogtreecommitdiff
path: root/liveview/liveview.h
diff options
context:
space:
mode:
authorJavier S. Pedro <maemo@javispedro.com>2013-05-08 18:04:31 +0200
committerJavier S. Pedro <maemo@javispedro.com>2013-05-08 18:04:31 +0200
commitccd19d2b7ee4184503ea46b98333b27a5613190e (patch)
treef78cc3f3c946d7a4f8167f72fb20703c65494d84 /liveview/liveview.h
parent6003bf81107dd9be51589c074b74c5af82bfc8ab (diff)
downloadsowatch-ccd19d2b7ee4184503ea46b98333b27a5613190e.tar.gz
sowatch-ccd19d2b7ee4184503ea46b98333b27a5613190e.zip
big change: a new abstract BluetoothWatch class
Diffstat (limited to 'liveview/liveview.h')
-rw-r--r--liveview/liveview.h52
1 files changed, 52 insertions, 0 deletions
diff --git a/liveview/liveview.h b/liveview/liveview.h
new file mode 100644
index 0000000..39b1b92
--- /dev/null
+++ b/liveview/liveview.h
@@ -0,0 +1,52 @@
+#ifndef LIVEVIEW_H
+#define LIVEVIEW_H
+
+#include <sowatch.h>
+#include <sowatchbt.h>
+
+namespace sowatch
+{
+
+class LiveView : public BluetoothWatch
+{
+ Q_OBJECT
+
+public:
+ explicit LiveView(ConfigKey *settings, QObject *parent = 0);
+ ~LiveView();
+
+ QPaintEngine* paintEngine() const;
+ int metric(PaintDeviceMetric metric) const;
+
+ QString model() const;
+ QStringList buttons() const;
+ bool isConnected() const;
+ bool busy() const;
+
+ void setDateTime(const QDateTime& dateTime);
+ void queryDateTime();
+ QDateTime dateTime() const;
+
+ void queryBatteryLevel();
+ int batteryLevel() const;
+
+ void queryCharging();
+ bool charging() const;
+
+ void displayIdleScreen();
+ void displayNotification(Notification *notification);
+ void displayApplication();
+
+ void vibrate(int msecs);
+
+protected:
+ void setupBluetoothWatch();
+ void desetupBluetoothWatch();
+
+private:
+ ConfigKey *_settings;
+};
+
+}
+
+#endif // LIVEVIEW_H