diff options
author | Renato Araujo Oliveira Filho <renato.filho@canonical.com> | 2016-03-18 22:20:03 -0300 |
---|---|---|
committer | Robert Tari <robert@tari.in> | 2021-07-05 00:44:12 +0200 |
commit | bf7746273c111b004c56a0868bb1702d96ecb67f (patch) | |
tree | 40617ffc0b0d59d111adf3b1c0e41c583498e392 | |
parent | 976cb51840ec2eb1f63649cfdf82d1bc9fa3676b (diff) | |
download | ayatana-indicator-datetime-bf7746273c111b004c56a0868bb1702d96ecb67f.tar.gz ayatana-indicator-datetime-bf7746273c111b004c56a0868bb1702d96ecb67f.tar.bz2 ayatana-indicator-datetime-bf7746273c111b004c56a0868bb1702d96ecb67f.zip |
Lauch calendar app using the event start time.
-rw-r--r-- | src/actions-live.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/actions-live.cpp b/src/actions-live.cpp index 6ac1878..4fe2f39 100644 --- a/src/actions-live.cpp +++ b/src/actions-live.cpp @@ -162,25 +162,16 @@ void LiveActions::phone_open_appointment(const Appointment& appt) break; case Appointment::EVENT: - if (!appt.source_uid.empty() && !appt.uid.empty()) - { - std::stringstream cmd; - // event-id format: <source-id>/<event-id> - cmd << "calendar://eventid=" - << appt.source_uid - << "/" - << appt.uid; - dispatch_url(cmd.str()); - break; - } default: phone_open_calendar_app(appt.begin); + break; } } void LiveActions::phone_open_calendar_app(const DateTime& dt) { - auto cmd = dt.format("calendar:///?startdate=%Y%m%dT%H%M%SZ"); + const auto utc = dt.to_timezone("UTC"); + auto cmd = utc.format("calendar://startdate=%Y-%m-%dT%H:%M:%S+00:00"); dispatch_url(cmd); } |