mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
Merge pull request #2001 from LukashonakV/ISSUE#1988
This commit is contained in:
commit
48312f4c91
@ -32,10 +32,10 @@ waybar::modules::Clock::Clock(const std::string& id, const Json::Value& config)
|
|||||||
time_zones_.push_back(date::locate_zone(config_["timezone"].asString()));
|
time_zones_.push_back(date::locate_zone(config_["timezone"].asString()));
|
||||||
}
|
}
|
||||||
|
|
||||||
// If all timezones are parsed and no one is good, add nullptr to the timezones vector, to mark
|
// If all timezones are parsed and no one is good, add current time zone. nullptr in timezones
|
||||||
// that local time should be shown.
|
// vector means that local time should be shown
|
||||||
if (!time_zones_.size()) {
|
if (!time_zones_.size()) {
|
||||||
time_zones_.push_back(nullptr);
|
time_zones_.push_back(date::current_zone());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check if a particular placeholder is present in the tooltip format, to know what to calculate
|
// Check if a particular placeholder is present in the tooltip format, to know what to calculate
|
||||||
|
Loading…
Reference in New Issue
Block a user