summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--metawatch/metawatch.cpp3
-rw-r--r--sowatch.pro.user2
2 files changed, 3 insertions, 2 deletions
diff --git a/metawatch/metawatch.cpp b/metawatch/metawatch.cpp
index e6d8ea6..08b9890 100644
--- a/metawatch/metawatch.cpp
+++ b/metawatch/metawatch.cpp
@@ -178,7 +178,8 @@ void MetaWatch::setDateTime(const QDateTime &dateTime)
msg.data[1] = date.year() & 0xFF;
msg.data[2] = date.month();
msg.data[3] = date.day();
- msg.data[4] = date.dayOfWeek() - 1;
+ // Qt week starts on Monday([1-7]), MW starts on Sunday([0-6]).
+ msg.data[4] = date.dayOfWeek() % 7;
msg.data[5] = time.hour();
msg.data[6] = time.minute();
msg.data[7] = time.second();
diff --git a/sowatch.pro.user b/sowatch.pro.user
index d7bc3e6..7f97a16 100644
--- a/sowatch.pro.user
+++ b/sowatch.pro.user
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject>
-<!-- Written by Qt Creator 2.3.0, 2011-09-18T04:59:41. -->
+<!-- Written by Qt Creator 2.3.0, 2011-09-18T05:08:05. -->
<qtcreator>
<data>
<variable>ProjectExplorer.Project.ActiveTarget</variable>