blob: eb761a4acbe3b48c043864ac2887722f69bb5ffd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
import QtQuick 2.0
import QtQuick.Dialogs 1.2
MessageDialog {
standardButtons: StandardButton.No | StandardButton.Yes
title: "Donate"
icon: StandardIcon.Warning
text: getText()
function getText() {
var _name = ctx ? ctx.appName : "vpn"
var donateTxt = qsTr(
"The %1 service is expensive to run. Because we don't want to store personal information about you, there are no accounts or billing for this service. But if you want the service to continue, donate at least $5 each month.\n\nDo you want to donate now?").arg(_name)
return donateTxt
}
onAccepted: {
if (backend) {
backend.openURL(ctx.donateURL)
backend.donateAccepted()
}
}
onRejected: {
if (backend) {
backend.donateRejected()
}
}
}
|