aboutsummaryrefslogtreecommitdiff
path: root/include/datetime
diff options
context:
space:
mode:
Diffstat (limited to 'include/datetime')
-rw-r--r--include/datetime/actions-live.h24
-rw-r--r--include/datetime/actions.h2
-rw-r--r--include/datetime/clock-mock.h2
-rw-r--r--include/datetime/dbus-shared.h6
-rw-r--r--include/datetime/engine-eds.h6
-rw-r--r--include/datetime/engine-mock.h6
-rw-r--r--include/datetime/engine.h6
-rw-r--r--include/datetime/exporter.h2
-rw-r--r--include/datetime/formatter.h4
-rw-r--r--include/datetime/planner-range.h2
-rw-r--r--include/datetime/wakeup-timer-mainloop.h2
-rw-r--r--include/datetime/wakeup-timer-powerd.h2
12 files changed, 32 insertions, 32 deletions
diff --git a/include/datetime/actions-live.h b/include/datetime/actions-live.h
index 0bf48a8..0214d65 100644
--- a/include/datetime/actions-live.h
+++ b/include/datetime/actions-live.h
@@ -36,21 +36,21 @@ namespace datetime {
class LiveActions: public Actions
{
public:
- LiveActions(const std::shared_ptr<State>& state_in);
- ~LiveActions() =default;
+ explicit LiveActions(const std::shared_ptr<State>& state_in);
+ virtual ~LiveActions() =default;
- bool desktop_has_calendar_app() const;
- void desktop_open_alarm_app();
- void desktop_open_appointment(const Appointment&);
- void desktop_open_calendar_app(const DateTime&);
- void desktop_open_settings_app();
+ bool desktop_has_calendar_app() const override;
+ void desktop_open_alarm_app() override;
+ void desktop_open_appointment(const Appointment&) override;
+ void desktop_open_calendar_app(const DateTime&) override;
+ void desktop_open_settings_app() override;
- void phone_open_alarm_app();
- void phone_open_appointment(const Appointment&);
- void phone_open_calendar_app(const DateTime&);
- void phone_open_settings_app();
+ void phone_open_alarm_app() override;
+ void phone_open_appointment(const Appointment&) override;
+ void phone_open_calendar_app(const DateTime&) override;
+ void phone_open_settings_app() override;
- void set_location(const std::string& zone, const std::string& name);
+ void set_location(const std::string& zone, const std::string& name) override;
protected:
virtual void execute_command(const std::string& command);
diff --git a/include/datetime/actions.h b/include/datetime/actions.h
index f59ef67..87cb676 100644
--- a/include/datetime/actions.h
+++ b/include/datetime/actions.h
@@ -61,7 +61,7 @@ public:
const std::shared_ptr<State> state() const;
protected:
- Actions(const std::shared_ptr<State>& state);
+ explicit Actions(const std::shared_ptr<State>& state);
virtual ~Actions();
private:
diff --git a/include/datetime/clock-mock.h b/include/datetime/clock-mock.h
index 0e24377..84fd860 100644
--- a/include/datetime/clock-mock.h
+++ b/include/datetime/clock-mock.h
@@ -36,7 +36,7 @@ namespace datetime {
class MockClock: public Clock
{
public:
- MockClock(const DateTime& dt): m_localtime(dt) {}
+ explicit MockClock(const DateTime& dt): m_localtime(dt) {}
~MockClock() =default;
DateTime localtime() const { return m_localtime; }
diff --git a/include/datetime/dbus-shared.h b/include/datetime/dbus-shared.h
index c09caa2..0c6b4be 100644
--- a/include/datetime/dbus-shared.h
+++ b/include/datetime/dbus-shared.h
@@ -18,8 +18,8 @@
* Charles Kerr <charles.kerr@canonical.com>
*/
-#ifndef _INDICATOR_DATETIME_DBUS_SHARED_H_
-#define _INDICATOR_DATETIME_DBUS_SHARED_H_
+#ifndef INDICATOR_DATETIME_DBUS_SHARED_H
+#define INDICATOR_DATETIME_DBUS_SHARED_H
#define BUS_DATETIME_NAME "com.canonical.indicator.datetime"
#define BUS_DATETIME_PATH "/com/canonical/indicator/datetime"
@@ -29,4 +29,4 @@
#define BUS_POWERD_INTERFACE "com.canonical.powerd"
-#endif /* _INDICATOR_DATETIME_DBUS_SHARED_H_ */
+#endif /* INDICATOR_DATETIME_DBUS_SHARED_H */
diff --git a/include/datetime/engine-eds.h b/include/datetime/engine-eds.h
index 4b260a8..ebee838 100644
--- a/include/datetime/engine-eds.h
+++ b/include/datetime/engine-eds.h
@@ -17,8 +17,8 @@
* Charles Kerr <charles.kerr@canonical.com>
*/
-#ifndef INDICATOR_DATETIME_ENGINE_EDS__H
-#define INDICATOR_DATETIME_ENGINE_EDS__H
+#ifndef INDICATOR_DATETIME_ENGINE_EDS_H
+#define INDICATOR_DATETIME_ENGINE_EDS_H
#include <datetime/engine.h>
@@ -72,4 +72,4 @@ private:
} // namespace indicator
} // namespace unity
-#endif // INDICATOR_DATETIME_ENGINE_EDS__H
+#endif // INDICATOR_DATETIME_ENGINE_EDS_H
diff --git a/include/datetime/engine-mock.h b/include/datetime/engine-mock.h
index ecbf102..4b25120 100644
--- a/include/datetime/engine-mock.h
+++ b/include/datetime/engine-mock.h
@@ -17,8 +17,8 @@
* Charles Kerr <charles.kerr@canonical.com>
*/
-#ifndef INDICATOR_DATETIME_ENGINE_MOCK__H
-#define INDICATOR_DATETIME_ENGINE_MOCK__H
+#ifndef INDICATOR_DATETIME_ENGINE_MOCK_H
+#define INDICATOR_DATETIME_ENGINE_MOCK_H
#include <datetime/engine.h>
@@ -65,4 +65,4 @@ private:
} // namespace indicator
} // namespace unity
-#endif // INDICATOR_DATETIME_ENGINE_NOOP__H
+#endif // INDICATOR_DATETIME_ENGINE_MOCK_H
diff --git a/include/datetime/engine.h b/include/datetime/engine.h
index 2e8237e..56e9343 100644
--- a/include/datetime/engine.h
+++ b/include/datetime/engine.h
@@ -17,8 +17,8 @@
* Charles Kerr <charles.kerr@canonical.com>
*/
-#ifndef INDICATOR_DATETIME_ENGINE__H
-#define INDICATOR_DATETIME_ENGINE__H
+#ifndef INDICATOR_DATETIME_ENGINE_H
+#define INDICATOR_DATETIME_ENGINE_H
#include <datetime/appointment.h>
#include <datetime/date-time.h>
@@ -65,4 +65,4 @@ protected:
} // namespace indicator
} // namespace unity
-#endif // INDICATOR_DATETIME_ENGINE__H
+#endif // INDICATOR_DATETIME_ENGINE_H
diff --git a/include/datetime/exporter.h b/include/datetime/exporter.h
index dd57263..211e7bb 100644
--- a/include/datetime/exporter.h
+++ b/include/datetime/exporter.h
@@ -39,7 +39,7 @@ namespace datetime {
class Exporter
{
public:
- Exporter(const std::shared_ptr<Settings>&);
+ explicit Exporter(const std::shared_ptr<Settings>&);
~Exporter();
core::Signal<>& name_lost();
diff --git a/include/datetime/formatter.h b/include/datetime/formatter.h
index 0d695e2..9b3699d 100644
--- a/include/datetime/formatter.h
+++ b/include/datetime/formatter.h
@@ -86,7 +86,7 @@ public:
std::string relative_format(GDateTime* then, GDateTime* then_end=nullptr) const;
protected:
- Formatter(const std::shared_ptr<const Clock>&);
+ explicit Formatter(const std::shared_ptr<const Clock>&);
virtual ~Formatter();
static const char* default_header_time_format(bool twelvehour, bool show_seconds);
@@ -126,7 +126,7 @@ private:
class PhoneFormatter: public Formatter
{
public:
- PhoneFormatter(const std::shared_ptr<const Clock>& clock): Formatter(clock) {
+ explicit PhoneFormatter(const std::shared_ptr<const Clock>& clock): Formatter(clock) {
header_format.set(default_header_time_format(is_locale_12h(), false));
}
};
diff --git a/include/datetime/planner-range.h b/include/datetime/planner-range.h
index 2ee2fa0..d638182 100644
--- a/include/datetime/planner-range.h
+++ b/include/datetime/planner-range.h
@@ -72,7 +72,7 @@ private:
core::Property<std::vector<Appointment>> m_appointments;
// we've got a GSignal tag here, so disable copying
- SimpleRangePlanner(const RangePlanner&) =delete;
+ explicit SimpleRangePlanner(const RangePlanner&) =delete;
SimpleRangePlanner& operator=(const RangePlanner&) =delete;
};
diff --git a/include/datetime/wakeup-timer-mainloop.h b/include/datetime/wakeup-timer-mainloop.h
index 480d728..86da8cf 100644
--- a/include/datetime/wakeup-timer-mainloop.h
+++ b/include/datetime/wakeup-timer-mainloop.h
@@ -39,7 +39,7 @@ namespace datetime {
class MainloopWakeupTimer: public WakeupTimer
{
public:
- MainloopWakeupTimer(const std::shared_ptr<Clock>&);
+ explicit MainloopWakeupTimer(const std::shared_ptr<Clock>&);
~MainloopWakeupTimer();
void set_wakeup_time (const DateTime&);
core::Signal<>& timeout();
diff --git a/include/datetime/wakeup-timer-powerd.h b/include/datetime/wakeup-timer-powerd.h
index 6adbbb8..f11febe 100644
--- a/include/datetime/wakeup-timer-powerd.h
+++ b/include/datetime/wakeup-timer-powerd.h
@@ -39,7 +39,7 @@ namespace datetime {
class PowerdWakeupTimer: public WakeupTimer
{
public:
- PowerdWakeupTimer(const std::shared_ptr<Clock>&);
+ explicit PowerdWakeupTimer(const std::shared_ptr<Clock>&);
~PowerdWakeupTimer();
void set_wakeup_time(const DateTime&);
core::Signal<>& timeout();