forked from Public/monero-gui
Add support for creating hardware wallet
This commit is contained in:
@@ -37,9 +37,10 @@ ColumnLayout {
|
||||
signal createWalletClicked()
|
||||
signal recoveryWalletClicked()
|
||||
signal openWalletClicked()
|
||||
signal createWalletFromDeviceClicked()
|
||||
opacity: 0
|
||||
visible: false
|
||||
property int buttonSize: (isMobile) ? 80 * scaleRatio : 190 * scaleRatio
|
||||
property int buttonSize: (isMobile) ? 80 * scaleRatio : 140 * scaleRatio
|
||||
property int buttonImageSize: (isMobile) ? buttonSize - 10 * scaleRatio : buttonSize - 30 * scaleRatio
|
||||
|
||||
function onPageClosed() {
|
||||
@@ -227,6 +228,51 @@ ColumnLayout {
|
||||
wrapMode: Text.WordWrap
|
||||
}
|
||||
}
|
||||
|
||||
GridLayout {
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
flow: !isMobile ? GridLayout.TopToBottom : GridLayout.LeftToRight
|
||||
rowSpacing: 20 * scaleRatio
|
||||
columnSpacing: 10 * scaleRatio
|
||||
|
||||
Rectangle {
|
||||
Layout.preferredHeight: page.buttonSize
|
||||
Layout.preferredWidth: page.buttonSize
|
||||
radius: page.buttonSize
|
||||
color: createWalletFromDeviceArea.containsMouse ? "#DBDBDB" : "#FFFFFF"
|
||||
|
||||
|
||||
Image {
|
||||
width: page.buttonImageSize
|
||||
height: page.buttonImageSize
|
||||
fillMode: Image.PreserveAspectFit
|
||||
horizontalAlignment: Image.AlignRight
|
||||
verticalAlignment: Image.AlignTop
|
||||
anchors.centerIn: parent
|
||||
source: "qrc:///images/createWalletFromDevice.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: createWalletFromDeviceArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
onClicked: {
|
||||
page.createWalletFromDeviceClicked()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
Layout.preferredWidth: page.buttonSize
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
color: "#4A4949"
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
wrapMode: Text.WordWrap
|
||||
text: qsTr("Create a new wallet from hardware device") + translationManager.emptyString
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
|
||||
Reference in New Issue
Block a user