Commit 8df6c01c authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇
Browse files

Remove notification inhibitor lock

Now that the notifications dodge the popup

Differential Revision: https://phabricator.kde.org/D26706
parent ba966a34
...@@ -27,7 +27,6 @@ import org.kde.plasma.networkmanagement 0.2 as PlasmaNM ...@@ -27,7 +27,6 @@ import org.kde.plasma.networkmanagement 0.2 as PlasmaNM
FocusScope { FocusScope {
id: full id: full
property var notificationInhibitorLock: undefined
PlasmaNM.AvailableDevices { PlasmaNM.AvailableDevices {
id: availableDevices id: availableDevices
...@@ -81,33 +80,14 @@ FocusScope { ...@@ -81,33 +80,14 @@ FocusScope {
target: plasmoid target: plasmoid
onExpandedChanged: { onExpandedChanged: {
connectionView.currentVisibleButtonIndex = -1; connectionView.currentVisibleButtonIndex = -1;
if (expanded) {
var service = notificationsEngine.serviceForSource("notifications");
var operation = service.operationDescription("inhibit");
operation.hint = "x-kde-appname";
operation.value = "networkmanagement";
var job = service.startOperationCall(operation);
job.finished.connect(function(job) {
if (expanded) {
notificationInhibitorLock = job.result;
}
});
handler.requestScan()
} else {
notificationInhibitorLock = undefined;
toolbar.closeSearch()
}
if (expanded) { if (expanded) {
handler.requestScan();
full.connectionModel = networkModelComponent.createObject(full) full.connectionModel = networkModelComponent.createObject(full)
} else { } else {
full.connectionModel.destroy() full.connectionModel.destroy()
toolbar.closeSearch();
} }
} }
} }
PlasmaCore.DataSource {
id: notificationsEngine
engine: "notifications"
}
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment