diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2014-01-16 17:42:43 -0600 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2014-01-16 17:42:43 -0600 |
commit | 40689ea36c360cb6fb42048f5d93303237745b86 (patch) | |
tree | d6aa59ed19596f928a6db2c1f1e5d8079ae4a159 /include | |
parent | 4cc19729c540ffba163d5c9a53b9352fe61fe8af (diff) | |
download | ayatana-indicator-datetime-40689ea36c360cb6fb42048f5d93303237745b86.tar.gz ayatana-indicator-datetime-40689ea36c360cb6fb42048f5d93303237745b86.tar.bz2 ayatana-indicator-datetime-40689ea36c360cb6fb42048f5d93303237745b86.zip |
update timezones-live to use Settings to tell when the user has enabled/disabled GeoClue lookups
Diffstat (limited to 'include')
-rw-r--r-- | include/datetime/timezones-live.h | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/include/datetime/timezones-live.h b/include/datetime/timezones-live.h index 5f2cb3e..286c967 100644 --- a/include/datetime/timezones-live.h +++ b/include/datetime/timezones-live.h @@ -20,9 +20,10 @@ #ifndef INDICATOR_DATETIME_LIVE_TIMEZONES_H #define INDICATOR_DATETIME_LIVE_TIMEZONES_H -#include <datetime/timezones.h> // base class -#include <datetime/timezone-file.h> // aggregated -#include <datetime/timezone-geoclue.h> // aggregated +#include <datetime/settings.h> +#include <datetime/timezones.h> +#include <datetime/timezone-file.h> +#include <datetime/timezone-geoclue.h> #include <memory> // shared_ptr<> @@ -37,16 +38,14 @@ namespace datetime { class LiveTimezones: public Timezones { public: - LiveTimezones(const std::string& filename); - - /** \brief Whether or not to track location by IP address */ - core::Property<bool> geolocation_enabled = core::Property<bool>(false); + LiveTimezones(std::shared_ptr<Settings>& settings, const std::string& filename); private: void update_geolocation(); void update_timezones(); FileTimezone m_file; + std::shared_ptr<Settings> m_settings; std::shared_ptr<GeoclueTimezone> m_geo; }; |