summaryrefslogtreecommitdiff
path: root/gui/qml
diff options
context:
space:
mode:
authorkali kaneko (leap communications) <kali@leap.se>2020-06-16 21:28:48 +0200
committerkali kaneko (leap communications) <kali@leap.se>2020-06-26 12:12:41 +0200
commitc17b5f6f7b6b28c890764688ff5e966ecebece63 (patch)
tree4c9931b10e7cddd9050f76aff95205dbf04d6d26 /gui/qml
parenta18e61aa1be37aa568552c69fbd743d25498b9bb (diff)
[feat] re-implement donation reminders
first pass on giving functionality to the donation reminder
Diffstat (limited to 'gui/qml')
-rw-r--r--gui/qml/DonateDialog.qml5
-rw-r--r--gui/qml/main.qml7
2 files changed, 7 insertions, 5 deletions
diff --git a/gui/qml/DonateDialog.qml b/gui/qml/DonateDialog.qml
index b7431ab..eb761a4 100644
--- a/gui/qml/DonateDialog.qml
+++ b/gui/qml/DonateDialog.qml
@@ -16,12 +16,13 @@ MessageDialog {
onAccepted: {
if (backend) {
- backend.donateAccepted(true)
+ backend.openURL(ctx.donateURL)
+ backend.donateAccepted()
}
}
onRejected: {
if (backend) {
- backend.donateAccepted(false)
+ backend.donateRejected()
}
}
}
diff --git a/gui/qml/main.qml b/gui/qml/main.qml
index 98eac80..65c09cb 100644
--- a/gui/qml/main.qml
+++ b/gui/qml/main.qml
@@ -16,10 +16,9 @@ ApplicationWindow {
target: jsonModel
onDataChanged: {
ctx = JSON.parse(jsonModel.getJson());
- if (ctx.donate == 'true') {
+ if (ctx.donateDialog == 'true') {
console.debug(jsonModel.getJson())
donate.visible = true
- backend.toggleDonate()
}
}
}
@@ -171,7 +170,9 @@ ApplicationWindow {
MenuItem {
text: qsTr("Donate...")
visible: true
- //onTriggered: donate.open()
+ onTriggered: {
+ donate.visible = true
+ }
}
MenuItem {