aboutsummaryrefslogtreecommitdiff
path: root/include/datetime/date-time.h
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2014-06-11 12:36:41 +0000
committerCI bot <ps-jenkins@lists.canonical.com>2014-06-11 12:36:41 +0000
commit9eee6f013103e856f66f16e17e156b1f6103695a (patch)
tree3678963f3d3520e8703732d7d0bb8489f23b7f49 /include/datetime/date-time.h
parent5e6083e752f7dd50571f87e5910dca6302ce8113 (diff)
parentdb2898b2da7231490fe77ebcef0fb373ce1f2776 (diff)
downloadayatana-indicator-datetime-9eee6f013103e856f66f16e17e156b1f6103695a.tar.gz
ayatana-indicator-datetime-9eee6f013103e856f66f16e17e156b1f6103695a.tar.bz2
ayatana-indicator-datetime-9eee6f013103e856f66f16e17e156b1f6103695a.zip
Prefer to use ubuntu-platform-hardware-api for wakeups when possible s.t. user-defined alarms/appointments can wake up the phone from sleep to give a snap decision. Fixes: 1299916
Diffstat (limited to 'include/datetime/date-time.h')
-rw-r--r--include/datetime/date-time.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/datetime/date-time.h b/include/datetime/date-time.h
index f861c2e..4be35f7 100644
--- a/include/datetime/date-time.h
+++ b/include/datetime/date-time.h
@@ -61,10 +61,13 @@ public:
bool operator<=(const DateTime& that) const;
bool operator!=(const DateTime& that) const;
bool operator==(const DateTime& that) const;
+ int64_t operator- (const DateTime& that) const;
static bool is_same_day(const DateTime& a, const DateTime& b);
static bool is_same_minute(const DateTime& a, const DateTime& b);
+ bool is_set() const { return m_dt != nullptr; }
+
private:
std::shared_ptr<GDateTime> m_dt;
};