Commit e0c708ff authored by Chupligin Sergey's avatar Chupligin Sergey

[Header] add scale fix issue #1

parent 4cb4baf3
...@@ -62,7 +62,7 @@ Item { ...@@ -62,7 +62,7 @@ Item {
PropertyChanges { PropertyChanges {
target: toolBarRect target: toolBarRect
width: parent.width width: parent.width
height: 75 height: size.dp(75)
} }
}, },
State { State {
...@@ -91,7 +91,7 @@ Item { ...@@ -91,7 +91,7 @@ Item {
} }
PropertyChanges { PropertyChanges {
target: toolBarRect target: toolBarRect
width: 75 width: size.dp(75)
height: parent.height height: parent.height
} }
} }
......
...@@ -25,13 +25,13 @@ Item { ...@@ -25,13 +25,13 @@ Item {
Rectangle { Rectangle {
id: backButton id: backButton
width: opacity ? 60 : 0 width: opacity ? size.dp(60) : 0
anchors.leftMargin: 20 anchors.leftMargin: size.dp(20)
//check if Stack.view has already been initialized as well //check if Stack.view has already been initialized as well
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
antialiasing: true antialiasing: true
height: width height: width
radius: 4 radius: size.dp(4)
color: backmouse.pressed ? "#222" : "transparent" color: backmouse.pressed ? "#222" : "transparent"
rotation: isUiPortrait ? 0 : 90 rotation: isUiPortrait ? 0 : 90
...@@ -46,7 +46,7 @@ Item { ...@@ -46,7 +46,7 @@ Item {
MouseArea { MouseArea {
id: backmouse id: backmouse
anchors.fill: parent anchors.fill: parent
anchors.margins: -10 anchors.margins: size.dp(-10)
onClicked: header && header.stackView && header.stackView.pop() onClicked: header && header.stackView && header.stackView.pop()
} }
} }
...@@ -56,16 +56,16 @@ Item { ...@@ -56,16 +56,16 @@ Item {
anchors.right: toolButtonsContainer.left anchors.right: toolButtonsContainer.left
anchors.left: backButton.visible ? backButton.right : parent.left anchors.left: backButton.visible ? backButton.right : parent.left
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.leftMargin: 20 anchors.leftMargin: size.dp(20)
anchors.rightMargin: 20 anchors.rightMargin: size.dp(20)
clip: true clip: true
font.family: Theme.fontFamily font.family: Theme.fontFamily
color: Theme.label.color color: Theme.label.color
font.pointSize: 24 font.pointSize: size.dp(24)
font.weight: Font.Bold font.weight: Font.Bold
LinearGradient { LinearGradient {
anchors.right: parent.right anchors.right: parent.right
width: 50 width: size.dp(50)
height: parent.paintedHeight height: parent.paintedHeight
visible: titleTxt.paintedWidth > titleTxt.width visible: titleTxt.paintedWidth > titleTxt.width
start: Qt.point(0,0) start: Qt.point(0,0)
...@@ -79,9 +79,9 @@ Item { ...@@ -79,9 +79,9 @@ Item {
Item { Item {
id: toolButtonsContainer id: toolButtonsContainer
anchors.right: dots.visible ? dots.left : parent.right anchors.right: dots.visible ? dots.left : parent.right
anchors.rightMargin: 20 anchors.rightMargin: size.dp(20)
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
width: tools ? (50 * Math.min(maxNumberOfToolButtons, tools.length)) : 0 width: tools ? (size.dp(50) * Math.min(maxNumberOfToolButtons, tools.length)) : 0
property int maxNumberOfToolButtons: 3 property int maxNumberOfToolButtons: 3
...@@ -107,7 +107,7 @@ Item { ...@@ -107,7 +107,7 @@ Item {
Image { Image {
id: dots id: dots
anchors.right: parent.right anchors.right: parent.right
anchors.rightMargin: 20 anchors.rightMargin: size.dp(20)
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
visible: drawerLevels && drawerLevels.length > 1 visible: drawerLevels && drawerLevels.length > 1
source: "../Styles/Nemo/images/dots-vertical.png" source: "../Styles/Nemo/images/dots-vertical.png"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment