aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRenato Araujo Oliveira Filho <renato.filho@canonical.com>2016-03-18 22:20:03 -0300
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2021-08-29 14:37:39 +0200
commitbbf8fdba0f3a8d57dcea96d2cfbc55e833c39adb (patch)
treef44da60ce09b185e3cde0536b4e43926a25b41b2 /src
parentb415ca00e1711d3a89f9de42dd57cbe929c4137e (diff)
downloadayatana-indicator-datetime-bbf8fdba0f3a8d57dcea96d2cfbc55e833c39adb.tar.gz
ayatana-indicator-datetime-bbf8fdba0f3a8d57dcea96d2cfbc55e833c39adb.tar.bz2
ayatana-indicator-datetime-bbf8fdba0f3a8d57dcea96d2cfbc55e833c39adb.zip
Lauch calendar app using the event start time.
Diffstat (limited to 'src')
-rw-r--r--src/actions-live.cpp15
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);
}