diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2015-04-03 13:11:39 -0500 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2015-04-03 13:11:39 -0500 |
commit | 8c7daeeb87abd0be1b96169da18baf018c4859c9 (patch) | |
tree | dbcceb67a1cda0ef293394948f358f2b06063dd4 /include/datetime/alarm-queue-simple.h | |
parent | 6e4367c088eb9026f29295c650f8639e09423212 (diff) | |
download | ayatana-indicator-datetime-8c7daeeb87abd0be1b96169da18baf018c4859c9.tar.gz ayatana-indicator-datetime-8c7daeeb87abd0be1b96169da18baf018c4859c9.tar.bz2 ayatana-indicator-datetime-8c7daeeb87abd0be1b96169da18baf018c4859c9.zip |
add the new Alarm class as an argument to the alarm queue class
Diffstat (limited to 'include/datetime/alarm-queue-simple.h')
-rw-r--r-- | include/datetime/alarm-queue-simple.h | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/include/datetime/alarm-queue-simple.h b/include/datetime/alarm-queue-simple.h index d191aec..838d28a 100644 --- a/include/datetime/alarm-queue-simple.h +++ b/include/datetime/alarm-queue-simple.h @@ -20,6 +20,8 @@ #ifndef INDICATOR_DATETIME_ALARM_QUEUE_SIMPLE_H #define INDICATOR_DATETIME_ALARM_QUEUE_SIMPLE_H +#include <memory> // std::shared_ptr + #include <datetime/alarm-queue.h> #include <datetime/clock.h> #include <datetime/planner.h> @@ -39,20 +41,12 @@ public: const std::shared_ptr<Planner>& upcoming_planner, const std::shared_ptr<WakeupTimer>& timer); ~SimpleAlarmQueue(); - core::Signal<const Appointment&>& alarm_reached(); + core::Signal<const Appointment&, const Alarm&>& alarm_reached() override; private: - void requeue(); - bool find_next_alarm(Appointment& setme) const; - std::vector<Appointment> find_current_alarms() const; - void check_alarms(); - - std::set<std::pair<std::string,DateTime>> m_triggered; - const std::shared_ptr<Clock> m_clock; - const std::shared_ptr<Planner> m_planner; - const std::shared_ptr<WakeupTimer> m_timer; - core::Signal<const Appointment&> m_alarm_reached; - DateTime m_datetime; + class Impl; + friend class Impl; + std::unique_ptr<Impl> impl; }; |