summaryrefslogtreecommitdiff
path: root/buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp')
-rw-r--r--buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp b/buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp
index f4e70ae..d5d1766 100644
--- a/buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp
+++ b/buteo-plugins/buteo-sync-plugin-mastodon-notifications/mastodonnotificationssyncadaptor.cpp
@@ -38,15 +38,15 @@
#include <algorithm>
-#define OPEN_BROWSER_ACTION(openUrlArgs) \
+#define OPEN_URL_ACTION(openUrl) \
Notification::remoteAction( \
"default", \
"", \
- "org.sailfishos.browser", \
+ "org.sailfishos.fileservice", \
"/", \
- "org.sailfishos.browser", \
+ "org.sailfishos.fileservice", \
"openUrl", \
- QVariantList() << openUrlArgs \
+ QVariantList() << openUrl \
)
namespace {
@@ -655,11 +655,7 @@ void MastodonNotificationsSyncAdaptor::publishSystemNotification(int accountId,
&& !parsedOpenUrl.host().isEmpty()
? openUrl
: fallbackUrl;
- QStringList openUrlArgs;
- openUrlArgs << safeOpenUrl;
-
- notification->setUrgency(Notification::Low);
- notification->setRemoteAction(OPEN_BROWSER_ACTION(openUrlArgs));
+ notification->setRemoteAction(OPEN_URL_ACTION(safeOpenUrl));
notification->publish();
if (notification->replacesId() == 0) {
qCWarning(lcSocialPlugin) << "failed to publish Mastodon notification"
@@ -728,6 +724,7 @@ Notification *MastodonNotificationsSyncAdaptor::createNotification(int accountId
notification->setHintValue("x-nemo.sociald.account-id", accountId);
notification->setHintValue(NotificationIdHint, notificationId);
notification->setHintValue("x-nemo-feedback", QStringLiteral("social"));
+ notification->setHintValue("x-nemo-priority", 100); // Show on lockscreen
notification->setCategory(QLatin1String(NotificationCategory));
m_notificationObjects.insert(objectKey, notification);