Page MenuHomePhorge

D49.1732549115.diff
No OneTemporary

Size
971 B
Referenced Files
None
Subscribers
None

D49.1732549115.diff

diff --git a/src/contents/ui/SelfDestroyableOverlaySheet.qml b/src/contents/ui/SelfDestroyableOverlaySheet.qml
--- a/src/contents/ui/SelfDestroyableOverlaySheet.qml
+++ b/src/contents/ui/SelfDestroyableOverlaySheet.qml
@@ -11,11 +11,25 @@
import org.kde.kirigami 2.13 as Kirigami
Kirigami.OverlaySheet {
+ id: selfDestroyableOverlaySheet
property var shouldSelfDestroy: false
- onSheetOpenChanged: {
- if (!sheetOpen && shouldSelfDestroy) {
- destroy();
+ property var selfDestroyConn: Connections {
+ target: selfDestroyableOverlaySheet
+
+ // for KF5
+ function onSheetOpenChanged() {
+ if (!selfDestroyableOverlaySheet.sheetOpen
+ && selfDestroyableOverlaySheet.shouldSelfDestroy) {
+ selfDestroyableOverlaySheet.destroy();
+ }
+ }
+
+ // for KF6
+ function onClosed() {
+ if (selfDestroyableOverlaySheet.shouldSelfDestroy) {
+ selfDestroyableOverlaySheet.destroy();
+ }
}
}
}

File Metadata

Mime Type
text/plain
Expires
Mon, Nov 25, 7:38 AM (12 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
39842
Default Alt Text
D49.1732549115.diff (971 B)

Event Timeline