mirror of
https://github.com/monero-project/monero-gui.git
synced 2026-04-12 19:17:26 -04:00
components mobile scaling
This commit is contained in:
@@ -36,13 +36,13 @@ Item {
|
||||
property alias readOnly : input.readOnly
|
||||
property alias cursorPosition: input.cursorPosition
|
||||
property alias echoMode: input.echoMode
|
||||
property int fontSize: 18
|
||||
property int fontSize: 18 * scaleRatio
|
||||
property bool error: false
|
||||
signal editingFinished()
|
||||
signal accepted();
|
||||
signal textUpdated();
|
||||
|
||||
height: 37
|
||||
height: 37 * scaleRatio
|
||||
|
||||
function getColor(error) {
|
||||
if (error)
|
||||
@@ -53,14 +53,14 @@ Item {
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.bottomMargin: 1
|
||||
anchors.bottomMargin: 1 * scaleRatio
|
||||
color: "#DBDBDB"
|
||||
//radius: 4
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.topMargin: 1
|
||||
anchors.topMargin: 1 * scaleRatio
|
||||
color: getColor(error)
|
||||
//radius: 4
|
||||
}
|
||||
@@ -68,8 +68,8 @@ Item {
|
||||
Input {
|
||||
id: input
|
||||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 30
|
||||
anchors.leftMargin: 4 * scaleRatio
|
||||
anchors.rightMargin: 30 * scaleRatio
|
||||
font.pixelSize: parent.fontSize
|
||||
onEditingFinished: item.editingFinished()
|
||||
onAccepted: item.accepted();
|
||||
|
||||
Reference in New Issue
Block a user