summaryrefslogtreecommitdiff
path: root/metawatch/metawatchdigitalsimulator.cpp
diff options
context:
space:
mode:
authorJavier S. Pedro <maemo@javispedro.com>2013-05-05 03:18:46 +0200
committerJavier S. Pedro <maemo@javispedro.com>2013-05-05 03:18:46 +0200
commit12cf6df3f1c90c6ccbab398f0ae03c946e4af638 (patch)
treea205f1240a421a1a6ac4d97e592730e5be00533b /metawatch/metawatchdigitalsimulator.cpp
parent12d61ddf50f5f34cafd25d7cbdc827156cfb184c (diff)
downloadsowatch-12cf6df3f1c90c6ccbab398f0ae03c946e4af638.tar.gz
sowatch-12cf6df3f1c90c6ccbab398f0ae03c946e4af638.zip
continue working on qml watchface support
Diffstat (limited to 'metawatch/metawatchdigitalsimulator.cpp')
-rw-r--r--metawatch/metawatchdigitalsimulator.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/metawatch/metawatchdigitalsimulator.cpp b/metawatch/metawatchdigitalsimulator.cpp
index dabc0f3..dcd0f6f 100644
--- a/metawatch/metawatchdigitalsimulator.cpp
+++ b/metawatch/metawatchdigitalsimulator.cpp
@@ -16,10 +16,14 @@ MetaWatchDigitalSimulator::MetaWatchDigitalSimulator(ConfigKey *config, QObject
_pixmap[IdleMode] = QPixmap(screenWidth, screenHeight);
_pixmap[ApplicationMode] = QPixmap(screenWidth, screenHeight);
_pixmap[NotificationMode] = QPixmap(screenWidth, screenHeight);
- _form->showNormal();
+
+ // Connect form signals
connect(_form, SIGNAL(buttonPressed(int)), SIGNAL(buttonPressed(int)));
connect(_form, SIGNAL(buttonReleased(int)), SIGNAL(buttonReleased(int)));
connect(_form, SIGNAL(destroyed()), SLOT(handleFormDestroyed()));
+
+ // Show the form
+ _form->showNormal();
}
MetaWatchDigitalSimulator::~MetaWatchDigitalSimulator()
@@ -79,6 +83,13 @@ void MetaWatchDigitalSimulator::update(Mode mode, const QList<QRect> &rects)
p.drawImage(r, _image[mode], r);
}
+
+ if (mode == IdleMode) {
+ QRect systemArea(0, 0, screenWidth, systemAreaHeight);
+ p.fillRect(systemArea, Qt::BDiagPattern);
+ p.drawText(systemArea, Qt::AlignCenter, "System area");
+ }
+
p.end();
int totalRows = rows.count(true);