status-desktop/ui/app/AppLayouts/Wallet/popups/SetCurrencyModal.qml

42 lines
837 B
QML
Raw Normal View History

2020-06-17 19:18:31 +00:00
import QtQuick 2.13
import QtQuick.Controls 2.13
import utils 1.0
import StatusQ.Controls 0.1
import shared.popups 1.0
import "../panels"
import "../stores"
// TODO: replace with StatusModal
2021-02-01 18:25:26 +00:00
ModalPopup {
id: popup
width: 480
height: 510
property string currentCurrency: RootStore.currentCurrency
2021-02-01 18:25:26 +00:00
onCurrentCurrencyChanged: {
setCurrencyModalContent.currency = currentCurrency
}
2021-02-18 16:36:05 +00:00
//% "Set Currency"
title: qsTrId("set-currency")
2020-07-22 20:40:32 +00:00
2021-02-01 18:25:26 +00:00
SetCurrencyModalContent {
id: setCurrencyModalContent
tokenListModel: CurrenciesStore {}
2021-02-01 18:25:26 +00:00
}
2020-07-22 20:40:32 +00:00
footer: StatusButton {
2021-02-01 18:25:26 +00:00
anchors.right: parent.right
//% "Save"
text: qsTrId("save")
2021-02-01 18:25:26 +00:00
onClicked: {
RootStore.updateCurrency(setCurrencyModalContent.currency)
2021-02-01 18:25:26 +00:00
popup.close()
2020-07-22 20:40:32 +00:00
}
}
}