@@ -39,6 +39,8 @@ Item {
3939 property bool fullscreen: false
4040 property int maxHeight
4141 property int margins
42+ property string acceptActionId
43+
4244 property Gradient greenGradient : Gradient {
4345 GradientStop { position: 0.0; color: "#3fb24f" }
4446 GradientStop { position: 1.0; color: "#3fb24f" }
@@ -141,6 +143,12 @@ Item {
141143 opacity: parent.opacity
142144 }
143145
146+ signal accept()
147+
148+ onAccept: {
149+ notification.notification.invokeAction(notification.acceptActionId)
150+ }
151+
144152 Item {
145153 id: contents
146154 anchors.fill: fullscreen ? nonShapedBack : shapedBack
@@ -344,7 +352,11 @@ Item {
344352 objectName: "button" + index
345353 width: buttonRow.width / 2 - spacing
346354 text: loader.actionLabel
347− property string actionId: loader.actionId
355+ Component.onCompleted: {
356+ if (index == 0) {
357+ notification.acceptActionId = loader.actionId
358+ }
359+ }
348360 gradient: notification.hints["x-canonical-private-button-tint"] == "true" && index == 0 ? greenGradient : darkgreyGradient
349361 onClicked: notification.notification.invokeAction(loader.actionId)
350362 }