From 3024eb9a3da4a40a6a7a5fd4d91d619d9dfb23a6 Mon Sep 17 00:00:00 2001 From: Toast Date: Fri, 6 Jun 2025 03:29:30 +0200 Subject: [PATCH] Qml: Move delete dialog and button to mod details page --- src/leek/qml/Main.qml | 13 ------------- src/leek/qml/ModPage.qml | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 13 deletions(-) diff --git a/src/leek/qml/Main.qml b/src/leek/qml/Main.qml index da54ba4..e211d4a 100644 --- a/src/leek/qml/Main.qml +++ b/src/leek/qml/Main.qml @@ -97,19 +97,6 @@ Kirigami.ApplicationWindow { onClicked: mod.enabled = checked } - Controls.Button { - text: "Delete" - onClicked: notImplementedDialog.open() - Kirigami.Dialog { - id: notImplementedDialog - title: "Not implemented!" - standardButtons: Kirigami.Dialog.Ok - padding: Kirigami.Units.largeSpacing - Controls.Label { - text: "Deleting is not implemented yet" - } - } - } } } } diff --git a/src/leek/qml/ModPage.qml b/src/leek/qml/ModPage.qml index 326b760..cbe0ec5 100644 --- a/src/leek/qml/ModPage.qml +++ b/src/leek/qml/ModPage.qml @@ -15,6 +15,24 @@ Kirigami.Page { applicationWindow().pageStack.pop(); } + Kirigami.Dialog { + id: notImplementedDialog + title: "Not implemented" + standardButtons: Kirigami.Dialog.Ok + padding: Kirigami.Units.largeSpacing + Controls.Label { + text: "Deleting is not implemented yet" + } + } + + actions: [ + Kirigami.Action { + text: "Remove" + icon.name: "delete-symbolic" + onToggled: notImplementedDialog.open() + } + ] + ColumnLayout { anchors { top: parent.top