diff options
| author | Jaquee <jaquee.monero@gmail.com> | 2017-08-07 15:47:56 +0200 |
|---|---|---|
| committer | Jaquee <jaquee.monero@gmail.com> | 2017-11-03 16:57:11 +0100 |
| commit | 9e0db8f4ffa7d979ffb07cd9d76aee885c261196 (patch) | |
| tree | cd8846ccc546cb6328de47695411d89f679df79b /components/StandardDropdown.qml | |
| parent | 66bb3fe7ac2b4e890ae7b89931f537bbfea1dd46 (diff) | |
| download | monzero-gui-9e0db8f4ffa7d979ffb07cd9d76aee885c261196.tar.gz monzero-gui-9e0db8f4ffa7d979ffb07cd9d76aee885c261196.tar.xz monzero-gui-9e0db8f4ffa7d979ffb07cd9d76aee885c261196.zip | |
components mobile scaling
Diffstat (limited to 'components/StandardDropdown.qml')
| -rw-r--r-- | components/StandardDropdown.qml | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/components/StandardDropdown.qml b/components/StandardDropdown.qml index 50b60fe0..f8b41d9d 100644 --- a/components/StandardDropdown.qml +++ b/components/StandardDropdown.qml @@ -38,7 +38,7 @@ Item { property string textColor: "#FFFFFF" property alias currentIndex: column.currentIndex property bool expanded: false - height: 37 + height: 37 * scaleRatio onExpandedChanged: if(expanded) appWindow.currentItem = dropdown function hide() { dropdown.expanded = false } @@ -59,7 +59,7 @@ Item { anchors.left: parent.left anchors.right: parent.right anchors.top: parent.top - height: 37 + height: 37 * scaleRatio Rectangle { anchors.left: parent.left @@ -82,8 +82,8 @@ Item { Rectangle { anchors.left: parent.left anchors.bottom: parent.bottom - height: 3 - width: 3 + height: 3 * scaleRatio + width: 3 * scaleRatio color: dropdown.pressedColor visible: dropdown.expanded || droplist.height > 0 } @@ -91,8 +91,8 @@ Item { Rectangle { anchors.right: parent.right anchors.bottom: parent.bottom - height: 3 - width: 3 + height: 3 * scaleRatio + width: 3 * scaleRatio color: dropdown.pressedColor visible: dropdown.expanded || droplist.height > 0 } @@ -101,11 +101,11 @@ Item { id: firstColText anchors.verticalCenter: parent.verticalCenter anchors.left: parent.left - anchors.leftMargin: 12 + anchors.leftMargin: 12 * scaleRatio elide: Text.ElideRight font.family: "Arial" font.bold: true - font.pixelSize: 12 + font.pixelSize: 12 * scaleRatio color: "#FFFFFF" text: column.currentIndex < repeater.model.rowCount() ? qsTr(repeater.model.get(column.currentIndex).column1) + translationManager.emptyString : "" } @@ -114,10 +114,10 @@ Item { id: secondColText anchors.verticalCenter: parent.verticalCenter anchors.right: separator.left - anchors.rightMargin: 12 + anchors.rightMargin: 12 * scaleRatio width: dropdown.expanded ? w : (separator.x - 12) - (firstColText.x + firstColText.width + 5) font.family: "Arial" - font.pixelSize: 12 + font.pixelSize: 12 * scaleRatio color: "#FFFFFF" text: column.currentIndex < repeater.model.rowCount() ? qsTr(repeater.model.get(column.currentIndex).column2) + translationManager.emptyString : "" @@ -129,7 +129,7 @@ Item { id: separator anchors.right: dropIndicator.left anchors.verticalCenter: parent.verticalCenter - height: 18 + height: 18 * scaleRatio width: 1 color: "#FFFFFF" } @@ -139,12 +139,12 @@ Item { anchors.top: parent.top anchors.bottom: parent.bottom anchors.right: parent.right - width: 32 + width: 32 * scaleRatio Image { anchors.centerIn: parent source: "../images/whiteDropIndicator.png" - rotation: dropdown.expanded ? 180 : 0 + rotation: dropdown.expanded ? 180 * scaleRatio : 0 } } @@ -168,14 +168,14 @@ Item { Rectangle { anchors.left: parent.left anchors.top: parent.top - width: 3; height: 3 + width: 3 * scaleRatio; height: 3 * scaleRatio color: dropdown.pressedColor } Rectangle { anchors.right: parent.right anchors.top: parent.top - width: 3; height: 3 + width: 3 * scaleRatio; height: 3 * scaleRatio color: dropdown.pressedColor } @@ -209,7 +209,7 @@ Item { delegate: Rectangle { anchors.left: parent.left anchors.right: parent.right - height: 30 + height: 30 * scaleRatio //radius: index === repeater.count - 1 ? 4 : 0 color: itemArea.containsMouse || index === column.currentIndex || itemArea.containsMouse ? dropdown.releasedColor : dropdown.pressedColor @@ -217,11 +217,11 @@ Item { anchors.verticalCenter: parent.verticalCenter anchors.left: parent.left anchors.right: col2Text.left - anchors.leftMargin: 12 - anchors.rightMargin: column2.length > 0 ? 12 : 0 + anchors.leftMargin: 12 * scaleRatio + anchors.rightMargin: column2.length > 0 ? 12 * scaleRatio: 0 font.family: "Arial" font.bold: true - font.pixelSize: 12 + font.pixelSize: 12 * scaleRatio color: "#FFFFFF" text: qsTr(column1) + translationManager.emptyString } @@ -230,9 +230,9 @@ Item { id: col2Text anchors.verticalCenter: parent.verticalCenter anchors.right: parent.right - anchors.rightMargin: 45 + anchors.rightMargin: 45 * scaleRatio font.family: "Arial" - font.pixelSize: 12 + font.pixelSize: 12 * scaleRatio color: "#FFFFFF" text: column2 } @@ -240,14 +240,14 @@ Item { Rectangle { anchors.left: parent.left anchors.top: parent.top - width: 3; height: 3 + width: 3 * scaleRatio; height: 3 * scaleRatio color: parent.color } Rectangle { anchors.right: parent.right anchors.top: parent.top - width: 3; height: 3 + width: 3 * scaleRatio; height: 3 * scaleRatio color: parent.color } |
