Skip to content

Commit

Permalink
Merge branch 'jb51671-action-changes' into 'master'
Browse files Browse the repository at this point in the history
[lipstick] Add LipstickNotification::remoteActionsChanged() signal. JB#51671

See merge request mer-core/lipstick!164
  • Loading branch information
blam committed Oct 27, 2020
2 parents 07d88c3 + 5bf6b61 commit ee16375
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion src/notifications/lipsticknotification.cpp
Expand Up @@ -205,7 +205,10 @@ QStringList LipstickNotification::actions() const

void LipstickNotification::setActions(const QStringList &actions)
{
m_actions = actions;
if (m_actions != actions) {
m_actions = actions;
emit remoteActionsChanged();
}
}

QVariantHash LipstickNotification::hints() const
Expand Down
5 changes: 4 additions & 1 deletion src/notifications/lipsticknotification.h
Expand Up @@ -51,7 +51,7 @@ class LIPSTICK_EXPORT LipstickNotification : public QObject
Q_PROPERTY(int priority READ priority NOTIFY priorityChanged)
Q_PROPERTY(QString category READ category NOTIFY categoryChanged)
Q_PROPERTY(bool userRemovable READ isUserRemovable NOTIFY userRemovableChanged)
Q_PROPERTY(QVariantList remoteActions READ remoteActions CONSTANT)
Q_PROPERTY(QVariantList remoteActions READ remoteActions NOTIFY remoteActionsChanged)
Q_PROPERTY(QString owner READ owner CONSTANT)
Q_PROPERTY(qreal progress READ progress NOTIFY progressChanged)
Q_PROPERTY(bool hasProgress READ hasProgress NOTIFY hasProgressChanged)
Expand Down Expand Up @@ -334,6 +334,9 @@ class LIPSTICK_EXPORT LipstickNotification : public QObject
//! Sent when the user removability has been modified
void userRemovableChanged();

//! Sent when the remote actions have been modified
void remoteActionsChanged();

void hasProgressChanged();
void progressChanged();

Expand Down

0 comments on commit ee16375

Please sign in to comment.