repo: remove isMobile leftovers

This commit is contained in:
selsta 2019-09-06 00:11:12 +02:00
parent a267712d10
commit 8dab0755d3
No known key found for this signature in database
GPG key ID: 2EA0A99A8B07AE5E
31 changed files with 48 additions and 360 deletions

View file

@ -84,7 +84,7 @@ Rectangle {
menuColumn.previousButton.checked = true menuColumn.previousButton.checked = true
} }
width: (isMobile)? appWindow.width : 300 width: 300
color: "transparent" color: "transparent"
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.top: parent.top anchors.top: parent.top
@ -390,7 +390,6 @@ Rectangle {
} }
MoneroComponents.Label { MoneroComponents.Label {
visible: !isMobile
id: balanceLabel id: balanceLabel
text: qsTr("Balance") + translationManager.emptyString text: qsTr("Balance") + translationManager.emptyString
color: "white" color: "white"
@ -418,7 +417,7 @@ Rectangle {
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.top: (isMobile)? parent.top : column1.bottom anchors.top: column1.bottom
color: "transparent" color: "transparent"
Flickable { Flickable {

View file

@ -46,7 +46,6 @@ Rectangle {
property Item currentView property Item currentView
property Item previousView property Item previousView
property bool basicMode : isMobile
property string balanceLabelText: qsTr("Balance") + translationManager.emptyString property string balanceLabelText: qsTr("Balance") + translationManager.emptyString
property string balanceText property string balanceText
property string unlockedBalanceLabelText: qsTr("Unlocked Balance") + translationManager.emptyString property string unlockedBalanceLabelText: qsTr("Unlocked Balance") + translationManager.emptyString

View file

@ -58,7 +58,7 @@ Item {
RowLayout { RowLayout {
id: checkBoxLayout id: checkBoxLayout
layoutDirection: iconOnTheLeft ? Qt.LeftToRight : Qt.RightToLeft layoutDirection: iconOnTheLeft ? Qt.LeftToRight : Qt.RightToLeft
spacing: (!isMobile ? 10 : 8) spacing: 10
Item { Item {
id: checkMark id: checkMark

View file

@ -1,118 +0,0 @@
import QtQuick 2.9
import QtGraphicalEffects 1.0
import QtQuick.Layouts 1.1
import moneroComponents.Wallet 1.0
import "../components" as MoneroComponents
// BasicPanel header
Rectangle {
id: header
anchors.leftMargin: 1
anchors.rightMargin: 1
Layout.fillWidth: true
Layout.preferredHeight: 64
color: "#FFFFFF"
Image {
id: logo
visible: appWindow.width > 460
anchors.verticalCenter: parent.verticalCenter
anchors.verticalCenterOffset: -5
anchors.left: parent.left
anchors.leftMargin: 50
source: "qrc:///images/moneroLogo2.png"
}
Image {
id: icon
visible: !logo.visible
anchors.verticalCenter: parent.verticalCenter
anchors.left: parent.left
anchors.leftMargin: 40
source: "qrc:///images/moneroIcon.png"
}
Grid {
anchors.verticalCenter: parent.verticalCenter
anchors.top: parent.top
anchors.right: parent.right
anchors.topMargin: 10
width: 256
columns: 3
MoneroComponents.TextPlain {
id: balanceLabel
width: 116
height: 20
font.family: "Arial"
font.pixelSize: 12
font.letterSpacing: -1
elide: Text.ElideRight
horizontalAlignment: Text.AlignLeft
verticalAlignment: Text.AlignBottom
color: "#535353"
text: leftPanel.balanceLabelText + ":"
}
MoneroComponents.TextPlain {
id: balanceText
width: 110
height: 20
font.family: "Arial"
font.pixelSize: 18
font.letterSpacing: -1
elide: Text.ElideRight
horizontalAlignment: Text.AlignLeft
verticalAlignment: Text.AlignBottom
color: "#000000"
text: leftPanel.balanceText
}
Item {
height: 20
width: 20
Image {
anchors.verticalCenter: parent.verticalCenter
anchors.left: parent.left
source: "qrc:///images/lockIcon.png"
}
}
MoneroComponents.TextPlain {
width: 116
height: 20
font.family: "Arial"
font.pixelSize: 12
font.letterSpacing: -1
elide: Text.ElideRight
horizontalAlignment: Text.AlignLeft
verticalAlignment: Text.AlignBottom
color: "#535353"
text: qsTr("Unlocked Balance:")
}
MoneroComponents.TextPlain {
id: availableBalanceText
width: 110
height: 20
font.family: "Arial"
font.pixelSize: 14
font.letterSpacing: -1
elide: Text.ElideRight
horizontalAlignment: Text.AlignLeft
verticalAlignment: Text.AlignBottom
color: "#000000"
text: leftPanel.unlockedBalanceText
}
}
Rectangle {
anchors.left: parent.left
anchors.right: parent.right
anchors.bottom: parent.bottom
height: 1
color: "#DBDBDB"
}
}

View file

@ -74,7 +74,7 @@ Item {
MoneroComponents.TextPlain { MoneroComponents.TextPlain {
id: label id: label
Layout.leftMargin: (!isMobile ? 10 : 8) Layout.leftMargin: 10
color: MoneroComponents.Style.defaultFontColor color: MoneroComponents.Style.defaultFontColor
font.family: MoneroComponents.Style.fontRegular.name font.family: MoneroComponents.Style.fontRegular.name
font.pixelSize: radioButton.fontSize font.pixelSize: radioButton.fontSize

View file

@ -35,7 +35,7 @@ import "../js/Utils.js" as Utils
import "../components" as MoneroComponents import "../components" as MoneroComponents
GridLayout { GridLayout {
columns: (isMobile) ? 1 : 2 columns: 2
columnSpacing: 32 columnSpacing: 32
id: root id: root
property alias daemonAddrText: daemonAddr.text property alias daemonAddrText: daemonAddr.text

View file

@ -82,10 +82,8 @@ Rectangle {
function open() { function open() {
// Center // Center
if(!isMobile) {
root.x = parent.width/2 - root.width/2 root.x = parent.width/2 - root.width/2
root.y = 100 root.y = 100
}
root.z = 11 root.z = 11
root.visible = true; root.visible = true;
} }
@ -96,14 +94,14 @@ Rectangle {
} }
// TODO: implement without hardcoding sizes // TODO: implement without hardcoding sizes
width: isMobile ? screenWidth : 520 width: 520
height: isMobile ? screenHeight : 380 height: 380
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
spacing: 10 spacing: 10
anchors.fill: parent anchors.fill: parent
anchors.margins: (isMobile? 17 : 20) anchors.margins: 20
RowLayout { RowLayout {
id: column id: column

View file

@ -45,7 +45,7 @@ Rectangle {
property bool showCloseButton: true property bool showCloseButton: true
height: { height: {
if(!persistentSettings.customDecorations || isMobile) return 0; if(!persistentSettings.customDecorations) return 0;
return 50; return 50;
} }

View file

@ -46,7 +46,6 @@ function showSeedPage() {
leftPanel.selectItem(middlePanel.state); leftPanel.selectItem(middlePanel.state);
} }
passwordDialog.open(); passwordDialog.open();
if(isMobile) hideMenu();
updateBalance(); updateBalance();
} }

View file

@ -39,10 +39,8 @@ function switchPage(next) {
console.log("switchpage: currentPage: ", currentPage); console.log("switchpage: currentPage: ", currentPage);
// Update prev/next button positions for mobile/desktop // Update prev/next button positions for mobile/desktop
prevButton.anchors.verticalCenter = (!isMobile) ? wizard.verticalCenter : undefined prevButton.anchors.verticalCenter = wizard.verticalCenter
prevButton.anchors.bottom = (isMobile) ? wizard.bottom : undefined nextButton.anchors.verticalCenter = wizard.verticalCenter
nextButton.anchors.verticalCenter = (!isMobile) ? wizard.verticalCenter : undefined
nextButton.anchors.bottom = (isMobile) ? wizard.bottom : undefined
if (currentPage > 0 || currentPage < pages.length - 1) { if (currentPage > 0 || currentPage < pages.length - 1) {
pages[currentPage].opacity = 0 pages[currentPage].opacity = 0

180
main.qml
View file

@ -69,7 +69,6 @@ ApplicationWindow {
property bool foundNewBlock: false property bool foundNewBlock: false
property bool qrScannerEnabled: (typeof builtWithScanner != "undefined") && builtWithScanner property bool qrScannerEnabled: (typeof builtWithScanner != "undefined") && builtWithScanner
property int blocksToSync: 1 property int blocksToSync: 1
property var isMobile: (appWindow.width > 700 && !isAndroid) ? false : true
property bool isMining: false property bool isMining: false
property int walletMode: persistentSettings.walletMode property int walletMode: persistentSettings.walletMode
property var cameraUi property var cameraUi
@ -489,14 +488,14 @@ ApplicationWindow {
leftPanel.networkStatus.connected = status leftPanel.networkStatus.connected = status
// update local daemon status. // update local daemon status.
if(!isMobile && walletManager.isDaemonLocal(currentDaemonAddress)) if(walletManager.isDaemonLocal(currentDaemonAddress))
daemonRunning = status; daemonRunning = status;
// Update fee multiplier dropdown on transfer page // Update fee multiplier dropdown on transfer page
middlePanel.transferView.updatePriorityDropdown(); middlePanel.transferView.updatePriorityDropdown();
// If wallet isnt connected, advanced wallet mode and no daemon is running - Ask // If wallet isnt connected, advanced wallet mode and no daemon is running - Ask
if (!isMobile && appWindow.walletMode >= 2 && walletManager.isDaemonLocal(currentDaemonAddress) && !walletInitialized && status === Wallet.ConnectionStatus_Disconnected) { if (appWindow.walletMode >= 2 && walletManager.isDaemonLocal(currentDaemonAddress) && !walletInitialized && status === Wallet.ConnectionStatus_Disconnected) {
daemonManager.runningAsync(persistentSettings.nettype, function(running) { daemonManager.runningAsync(persistentSettings.nettype, function(running) {
if (!running) { if (!running) {
daemonManagerDialog.open(); daemonManagerDialog.open();
@ -1154,16 +1153,6 @@ ApplicationWindow {
}); });
} }
function hideMenu() {
goToBasicAnimation.start();
console.log(appWindow.width)
}
function showMenu() {
goToProAnimation.start();
console.log(appWindow.width)
}
objectName: "appWindow" objectName: "appWindow"
visible: true visible: true
@ -1615,149 +1604,87 @@ ApplicationWindow {
PropertyChanges { target: middlePanel; visible: false } PropertyChanges { target: middlePanel; visible: false }
PropertyChanges { target: wizard; visible: true } PropertyChanges { target: wizard; visible: true }
PropertyChanges { target: resizeArea; visible: true } PropertyChanges { target: resizeArea; visible: true }
PropertyChanges { target: mobileHeader; visible: false }
PropertyChanges { target: titleBar; state: "essentials" } PropertyChanges { target: titleBar; state: "essentials" }
}, State { }, State {
name: "normal" name: "normal"
PropertyChanges { target: leftPanel; visible: (isMobile)? false : true } PropertyChanges { target: leftPanel; visible: true }
PropertyChanges { target: middlePanel; visible: true } PropertyChanges { target: middlePanel; visible: true }
PropertyChanges { target: titleBar; basicButtonVisible: true } PropertyChanges { target: titleBar; basicButtonVisible: true }
PropertyChanges { target: wizard; visible: false } PropertyChanges { target: wizard; visible: false }
PropertyChanges { target: resizeArea; visible: true } PropertyChanges { target: resizeArea; visible: true }
PropertyChanges { target: titleBar; state: "default" } PropertyChanges { target: titleBar; state: "default" }
PropertyChanges { target: mobileHeader; visible: isMobile ? true : false }
} }
] ]
MobileHeader {
id: mobileHeader
visible: isMobile
anchors.left: parent.left
anchors.right: parent.right
height: visible? 65 : 0
MouseArea {
enabled: persistentSettings.customDecorations
property var previousPosition
anchors.fill: parent
propagateComposedEvents: true
onPressed: previousPosition = globalCursor.getPosition()
onPositionChanged: {
if (pressedButtons == Qt.LeftButton) {
var pos = globalCursor.getPosition()
var dx = pos.x - previousPosition.x
var dy = pos.y - previousPosition.y
appWindow.x += dx
appWindow.y += dy
previousPosition = pos
}
}
}
}
LeftPanel { LeftPanel {
id: leftPanel id: leftPanel
anchors.top: mobileHeader.bottom anchors.top: parent.top
anchors.left: parent.left anchors.left: parent.left
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
onTransferClicked: { onTransferClicked: {
middlePanel.state = "Transfer"; middlePanel.state = "Transfer";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onReceiveClicked: { onReceiveClicked: {
middlePanel.state = "Receive"; middlePanel.state = "Receive";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onMerchantClicked: { onMerchantClicked: {
middlePanel.state = "Merchant"; middlePanel.state = "Merchant";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onTxkeyClicked: { onTxkeyClicked: {
middlePanel.state = "TxKey"; middlePanel.state = "TxKey";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onSharedringdbClicked: { onSharedringdbClicked: {
middlePanel.state = "SharedRingDB"; middlePanel.state = "SharedRingDB";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onHistoryClicked: { onHistoryClicked: {
middlePanel.state = "History"; middlePanel.state = "History";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onAddressBookClicked: { onAddressBookClicked: {
middlePanel.state = "AddressBook"; middlePanel.state = "AddressBook";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onMiningClicked: { onMiningClicked: {
middlePanel.state = "Mining"; middlePanel.state = "Mining";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onSignClicked: { onSignClicked: {
middlePanel.state = "Sign"; middlePanel.state = "Sign";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onSettingsClicked: { onSettingsClicked: {
middlePanel.state = "Settings"; middlePanel.state = "Settings";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
onAccountClicked: { onAccountClicked: {
middlePanel.state = "Account"; middlePanel.state = "Account";
middlePanel.flickable.contentY = 0; middlePanel.flickable.contentY = 0;
if(isMobile) {
hideMenu();
}
updateBalance(); updateBalance();
} }
} }
@ -1765,102 +1692,13 @@ ApplicationWindow {
MiddlePanel { MiddlePanel {
id: middlePanel id: middlePanel
anchors.top: mobileHeader.bottom anchors.top: parent.top
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.left: leftPanel.visible ? leftPanel.right : parent.left anchors.left: leftPanel.visible ? leftPanel.right : parent.left
anchors.right: parent.right anchors.right: parent.right
state: "Transfer" state: "Transfer"
} }
SequentialAnimation {
id: goToBasicAnimation
// PropertyAction {
// target: appWindow
// properties: "visibility"
// value: Window.Windowed
// }
// PropertyAction {
// target: titleBar
// properties: "maximizeButtonVisible"
// value: false
// }
// PropertyAction {
// target: frameArea
// properties: "blocked"
// value: true
// }
PropertyAction {
target: resizeArea
properties: "visible"
value: true
}
// PropertyAction {
// target: appWindow
// properties: "height"
// value: 30
// }
// PropertyAction {
// target: appWindow
// properties: "width"
// value: 326
// }
PropertyAction {
target: leftPanel
properties: "visible"
value: false
}
PropertyAction {
target: middlePanel
properties: "basicMode"
value: true
}
// PropertyAction {
// target: appWindow
// properties: "height"
// value: middlePanel.height
// }
onStopped: {
// middlePanel.visible = false
leftPanel.visible = false
}
}
SequentialAnimation {
id: goToProAnimation
// PropertyAction {
// target: appWindow
// properties: "height"
// value: 30
// }
PropertyAction {
target: middlePanel
properties: "basicMode"
value: false
}
PropertyAction {
targets: [leftPanel, middlePanel, resizeArea]
properties: "visible"
value: true
}
// PropertyAction {
// target: appWindow
// properties: "height"
// value: maxWindowHeight
// }
// PropertyAction {
// target: frameArea
// properties: "blocked"
// value: false
// }
// PropertyAction {
// target: titleBar
// properties: "maximizeButtonVisible"
// value: true
// }
}
WizardController { WizardController {
id: wizard id: wizard
anchors.fill: parent anchors.fill: parent
@ -1932,13 +1770,7 @@ ApplicationWindow {
onMaximizeClicked: appWindow.visibility = appWindow.visibility !== Window.Maximized ? Window.Maximized : Window.Windowed onMaximizeClicked: appWindow.visibility = appWindow.visibility !== Window.Maximized ? Window.Maximized : Window.Windowed
onMinimizeClicked: appWindow.visibility = Window.Minimized onMinimizeClicked: appWindow.visibility = Window.Minimized
onGoToBasicVersion: { onGoToBasicVersion: {
if (yes) { //nop
// basicPanel.currentView = middlePanel.currentView
goToBasicAnimation.start()
} else {
// middlePanel.currentView = basicPanel.currentView
goToProAnimation.start()
}
} }
} }

View file

@ -64,7 +64,7 @@ Rectangle {
/* main layout */ /* main layout */
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left

View file

@ -52,7 +52,7 @@ Rectangle {
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left

View file

@ -52,7 +52,7 @@ Rectangle {
anchors.top: parent.top anchors.top: parent.top
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
spacing: 30 spacing: 30

View file

@ -41,7 +41,7 @@ Rectangle {
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
Layout.fillWidth: true Layout.fillWidth: true
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top

View file

@ -66,7 +66,7 @@ Rectangle {
/* main layout */ /* main layout */
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left

View file

@ -80,7 +80,7 @@ Rectangle {
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
Layout.fillWidth: true Layout.fillWidth: true
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left
@ -296,7 +296,7 @@ Rectangle {
GridLayout{ GridLayout{
Layout.topMargin: 12 Layout.topMargin: 12
columns: (isMobile) ? 1 : 2 columns: 2
columnSpacing: 32 columnSpacing: 32
ColumnLayout { ColumnLayout {
@ -368,7 +368,7 @@ Rectangle {
GridLayout { GridLayout {
columnSpacing: 20 columnSpacing: 20
columns: (isMobile) ? 1 : 2 columns: 2
MoneroComponents.CheckBox { MoneroComponents.CheckBox {
id: segregatePreForkOutputs id: segregatePreForkOutputs
@ -405,7 +405,7 @@ Rectangle {
id: segregationHeightRow id: segregationHeightRow
Layout.fillWidth: true Layout.fillWidth: true
Layout.topMargin: 17 Layout.topMargin: 17
columns: (isMobile) ? 1 : 2 columns: 2
columnSpacing: 32 columnSpacing: 32
MoneroComponents.LineEdit { MoneroComponents.LineEdit {

View file

@ -88,7 +88,7 @@ Rectangle {
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
Layout.fillWidth: true Layout.fillWidth: true
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left

View file

@ -123,7 +123,7 @@ Rectangle {
ColumnLayout { ColumnLayout {
id: pageRoot id: pageRoot
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left
@ -144,7 +144,7 @@ Rectangle {
} }
GridLayout { GridLayout {
columns: (isMobile || !(appWindow.walletMode >= 2)) ? 1 : 2 columns: appWindow.walletMode < 2 ? 1 : 2
Layout.fillWidth: true Layout.fillWidth: true
columnSpacing: 32 columnSpacing: 32
@ -443,7 +443,7 @@ Rectangle {
anchors.top: pageRoot.bottom anchors.top: pageRoot.bottom
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 32 anchors.topMargin: 32
spacing: 26 spacing: 26
enabled: !viewOnly || pageRoot.enabled enabled: !viewOnly || pageRoot.enabled
@ -462,7 +462,7 @@ Rectangle {
GridLayout { GridLayout {
visible: persistentSettings.transferShowAdvanced && appWindow.walletMode >= 2 visible: persistentSettings.transferShowAdvanced && appWindow.walletMode >= 2
columns: (isMobile) ? 2 : 6 columns: 6
StandardButton { StandardButton {
id: sweepUnmixableButton id: sweepUnmixableButton

View file

@ -45,7 +45,7 @@ Rectangle {
/* main layout */ /* main layout */
ColumnLayout { ColumnLayout {
id: mainLayout id: mainLayout
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 40 anchors.topMargin: 40
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top

View file

@ -44,7 +44,7 @@ Rectangle {
property bool showCloseButton: true property bool showCloseButton: true
height: { height: {
if(!persistentSettings.customDecorations || isMobile) return 0; if(!persistentSettings.customDecorations) return 0;
return 50; return 50;
} }

View file

@ -61,9 +61,7 @@ Rectangle {
property string borderColor: MoneroComponents.Style.blackTheme ? "#808080" : "#B9B9B9" property string borderColor: MoneroComponents.Style.blackTheme ? "#808080" : "#B9B9B9"
property int textMargin: { property int textMargin: {
// left-right margins for a given cell // left-right margins for a given cell
if(isMobile){ if(appWindow.width < 890){
return 10;
} else if(appWindow.width < 890){
return 32; return 32;
} else { } else {
return 64; return 64;

View file

@ -57,7 +57,7 @@ Rectangle {
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 0 anchors.topMargin: 0
spacing: 30 spacing: 30

View file

@ -47,12 +47,11 @@ Rectangle {
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 0 anchors.topMargin: 0
spacing: 6 spacing: 6
MoneroComponents.CheckBox { MoneroComponents.CheckBox {
visible: !isMobile
id: customDecorationsCheckBox id: customDecorationsCheckBox
checked: persistentSettings.customDecorations checked: persistentSettings.customDecorations
onClicked: Windows.setCustomWindowDecorations(checked) onClicked: Windows.setCustomWindowDecorations(checked)
@ -60,7 +59,6 @@ Rectangle {
} }
MoneroComponents.CheckBox { MoneroComponents.CheckBox {
visible: !isMobile
id: hideBalanceCheckBox id: hideBalanceCheckBox
checked: persistentSettings.hideBalance checked: persistentSettings.hideBalance
onClicked: { onClicked: {
@ -71,7 +69,6 @@ Rectangle {
} }
MoneroComponents.CheckBox { MoneroComponents.CheckBox {
visible: !isMobile
id: showPidCheckBox id: showPidCheckBox
checked: persistentSettings.showPid checked: persistentSettings.showPid
onClicked: { onClicked: {
@ -91,7 +88,6 @@ Rectangle {
} }
MoneroComponents.CheckBox { MoneroComponents.CheckBox {
visible: !isMobile
id: userInActivityCheckbox id: userInActivityCheckbox
checked: persistentSettings.lockOnUserInActivity checked: persistentSettings.lockOnUserInActivity
onClicked: persistentSettings.lockOnUserInActivity = !persistentSettings.lockOnUserInActivity onClicked: persistentSettings.lockOnUserInActivity = !persistentSettings.lockOnUserInActivity
@ -267,14 +263,6 @@ Rectangle {
appWindow.toggleLanguageView(); appWindow.toggleLanguageView();
} }
} }
MoneroComponents.TextBlock {
visible: isMobile
font.pixelSize: 14
textFormat: Text.RichText
Layout.fillWidth: true
text: qsTr("No Layout options exist yet in mobile mode.") + translationManager.emptyString;
}
} }
ListModel { ListModel {

View file

@ -47,7 +47,7 @@ Rectangle {
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 0 anchors.topMargin: 0
spacing: 10 spacing: 10

View file

@ -42,7 +42,7 @@ Rectangle{
/* main layout */ /* main layout */
ColumnLayout { ColumnLayout {
id: root id: root
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 0 anchors.topMargin: 0
anchors.left: parent.left anchors.left: parent.left
@ -276,7 +276,7 @@ Rectangle{
spacing: 20 spacing: 20
Layout.fillWidth: true Layout.fillWidth: true
Layout.topMargin: 20 Layout.topMargin: 20
visible: !isMobile && persistentSettings.useRemoteNode visible: persistentSettings.useRemoteNode
MoneroComponents.WarningBox { MoneroComponents.WarningBox {
Layout.topMargin: 26 Layout.topMargin: 26
@ -308,7 +308,7 @@ Rectangle{
} }
GridLayout { GridLayout {
columns: (isMobile) ? 1 : 2 columns: 2
columnSpacing: 32 columnSpacing: 32
MoneroComponents.LineEdit { MoneroComponents.LineEdit {
@ -368,7 +368,7 @@ Rectangle{
id: localNodeLayout id: localNodeLayout
spacing: 20 spacing: 20
Layout.topMargin: 40 Layout.topMargin: 40
visible: !isMobile && !persistentSettings.useRemoteNode visible: !persistentSettings.useRemoteNode
MoneroComponents.StandardButton { MoneroComponents.StandardButton {
small: true small: true
@ -427,7 +427,7 @@ Rectangle{
} }
RowLayout { RowLayout {
visible: !isMobile && !persistentSettings.useRemoteNode visible: !persistentSettings.useRemoteNode
ColumnLayout { ColumnLayout {
Layout.fillWidth: true Layout.fillWidth: true

View file

@ -45,7 +45,7 @@ Rectangle {
anchors.left: parent.left anchors.left: parent.left
anchors.top: parent.top anchors.top: parent.top
anchors.right: parent.right anchors.right: parent.right
anchors.margins: (isMobile)? 17 : 20 anchors.margins: 20
anchors.topMargin: 0 anchors.topMargin: 0
spacing: 0 spacing: 0

View file

@ -107,7 +107,6 @@
<file>components/DaemonConsole.qml</file> <file>components/DaemonConsole.qml</file>
<file>components/QRCodeScanner.qml</file> <file>components/QRCodeScanner.qml</file>
<file>components/Notifier.qml</file> <file>components/Notifier.qml</file>
<file>components/MobileHeader.qml</file>
<file>components/TextBlock.qml</file> <file>components/TextBlock.qml</file>
<file>components/RemoteNodeEdit.qml</file> <file>components/RemoteNodeEdit.qml</file>
<file>pages/Keys.qml</file> <file>pages/Keys.qml</file>

View file

@ -121,9 +121,7 @@ Rectangle {
property int flickableHeightMargin: 200 property int flickableHeightMargin: 200
property int layoutScale: { property int layoutScale: {
if(isMobile){ if(appWindow.width < 800){
return 0;
} else if(appWindow.width < 800){
return 1; return 1;
} else { } else {
return 2; return 2;

View file

@ -41,9 +41,7 @@ Rectangle {
color: "transparent" color: "transparent"
anchors.fill: parent anchors.fill: parent
property int layoutScale: { property int layoutScale: {
if(isMobile){ if(appWindow.width < 800){
return 0;
} else if(appWindow.width < 800){
return 1; return 1;
} else { } else {
return 2; return 2;

View file

@ -149,7 +149,7 @@ Rectangle {
GridLayout { GridLayout {
id: buttonsGrid id: buttonsGrid
opacity: 0 opacity: 0
columns: isMobile ? 1 : 2 columns: 2
Layout.alignment: Qt.AlignCenter Layout.alignment: Qt.AlignCenter
Layout.topMargin: 20 Layout.topMargin: 20
Layout.fillWidth: true Layout.fillWidth: true