Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[lipstick] Expose also notification actions that trigger only d-bus s…
…ignal. Contributes to JB#44716
  • Loading branch information
pvuorela committed Sep 4, 2020
1 parent 2d2f169 commit c7aff2e
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions src/notifications/lipsticknotification.cpp
Expand Up @@ -329,15 +329,16 @@ QVariantList LipstickNotification::remoteActions() const
++it;
}

QVariantMap vm;
vm.insert(QStringLiteral("name"), name);
if (!displayName.isEmpty()) {
vm.insert(QStringLiteral("displayName"), displayName);
}

const QString hint(m_hints.value(LipstickNotification::HINT_REMOTE_ACTION_PREFIX + name).toString());
if (!hint.isEmpty()) {
const QString icon(m_hints.value(LipstickNotification::HINT_REMOTE_ACTION_ICON_PREFIX + name).toString());

QVariantMap vm;
vm.insert(QStringLiteral("name"), name);
if (!displayName.isEmpty()) {
vm.insert(QStringLiteral("displayName"), displayName);
}
if (!icon.isEmpty()) {
vm.insert(QStringLiteral("icon"), icon);
}
Expand Down Expand Up @@ -365,9 +366,9 @@ QVariantList LipstickNotification::remoteActions() const
}
vm.insert(QStringLiteral("arguments"), args);
}

rv.append(vm);
}

rv.append(vm);
}

return rv;
Expand Down

0 comments on commit c7aff2e

Please sign in to comment.