[Pkg-privacy-commits] [tails-installer] 141/210: Add DPI scaling support
Intrigeri
intrigeri at moszumanska.debian.org
Wed May 24 15:26:38 UTC 2017
This is an automated email from the git hooks/post-receive script.
intrigeri pushed a commit to tag 3.90.0
in repository tails-installer.
commit c02ab07072993a74f89305cb78fae83ded9e7367
Author: Martin Briza <mbriza at redhat.com>
Date: Wed Aug 26 14:32:48 2015 +0200
Add DPI scaling support
---
liveusb-creator.spec | 10 +++-
liveusb/components/AdwaitaButton.qml | 5 +-
liveusb/components/AdwaitaCheckBox.qml | 39 +++++++++++++
liveusb/components/AdwaitaComboBox.qml | 12 ++--
liveusb/components/AdwaitaProgressBar.qml | 16 +++---
liveusb/components/AdwaitaRadioButton.qml | 9 ++-
liveusb/components/AdwaitaRectangle.qml | 10 ++--
liveusb/components/BackButton.qml | 31 ++++++-----
liveusb/components/DownloadDialog.qml | 58 +++++++++++---------
liveusb/components/ImageDetails.qml | 61 +++++++++++----------
liveusb/components/ImageList.qml | 91 ++++++++++++++++---------------
liveusb/components/IndicatedImage.qml | 2 +
liveusb/components/MenuButton.qml | 12 ++--
liveusb/components/QuitButton.qml | 12 ++--
liveusb/liveusb.qml | 15 +++--
15 files changed, 228 insertions(+), 155 deletions(-)
diff --git a/liveusb-creator.spec b/liveusb-creator.spec
index 07b9913..799852c 100644
--- a/liveusb-creator.spec
+++ b/liveusb-creator.spec
@@ -10,14 +10,14 @@
Name: liveusb-creator
Version: 3.15.0
-Release: 0.1.newui.afdc2a1c%{?dist}
+Release: 0.1.newui%{?dist}
Summary: A liveusb creator
Group: Applications/System
License: GPLv2
URL: https://fedorahosted.org/liveusb-creator
#Source0: https://github.com/lmacken/liveusb-creator/archive/#{commit}.tar.gz
-Source0: liveusb-creator-bc1b3fda.tar
+Source0: liveusb-creator-00e2ea65.tar
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
@@ -97,6 +97,12 @@ rm -rf %{buildroot}
%{_datadir}/polkit-1/actions/org.fedoraproject.pkexec.run-liveusb-creator.policy
%changelog
+* Tue Aug 25 2015 mbriza <mbriza at redhat.com> - 3.15.0-0.1.newui
+- Update to git: 00e2ea65
+
+* Thu Aug 20 2015 mbriza <mbriza at redhat.com> - 3.15.0-0.1.newui.afdc2a1c.20150820git63a2a068
+- Update to git: 63a2a068
+
* Thu Aug 20 2015 mbriza <mbriza at redhat.com> - 3.15.0-0.1.newui.afdc2a1c.20150820gitbc1b3fda
- Update to git: bc1b3fda
diff --git a/liveusb/components/AdwaitaButton.qml b/liveusb/components/AdwaitaButton.qml
index e4b90af..038d907 100644
--- a/liveusb/components/AdwaitaButton.qml
+++ b/liveusb/components/AdwaitaButton.qml
@@ -13,9 +13,10 @@ Button {
border.color: control.enabled ? "#777777" : "#c2c2c2"
}
label: Item {
- implicitWidth: labelText.width + 16
+ implicitWidth: labelText.width + $(16)
Text {
- x: 8
+ x: $(8)
+ font.pointSize: $(9)
id: labelText
color: control.enabled ? root.textColor : "gray"
text: control.text
diff --git a/liveusb/components/AdwaitaCheckBox.qml b/liveusb/components/AdwaitaCheckBox.qml
new file mode 100644
index 0000000..ce28a0b
--- /dev/null
+++ b/liveusb/components/AdwaitaCheckBox.qml
@@ -0,0 +1,39 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0
+import QtQuick.Controls.Styles 1.0
+
+CheckBox {
+ style: CheckBoxStyle {
+ indicator: AdwaitaRectangle {
+ implicitWidth: $(15)
+ implicitHeight: $(15)
+ Item {
+ visible: control.checked
+ rotation: -45
+ anchors.fill: parent
+ Rectangle {
+ color: "black"
+ x: $(5)
+ y: $(4)
+ width: $(3)
+ height: $(6)
+ radius: $(4)
+ }
+ Rectangle {
+ color: "black"
+ x: $(5)
+ y: $(8)
+ width: $(12)
+ height: $(3)
+ radius: $(4)
+ }
+ }
+ }
+ label: Text {
+ font.pointSize: $(9)
+ text: control.text
+ }
+ spacing: $(8)
+ }
+}
+
diff --git a/liveusb/components/AdwaitaComboBox.qml b/liveusb/components/AdwaitaComboBox.qml
index 723628c..cf4e46a 100644
--- a/liveusb/components/AdwaitaComboBox.qml
+++ b/liveusb/components/AdwaitaComboBox.qml
@@ -4,22 +4,24 @@ import QtQuick.Controls.Styles 1.2
import QtQuick.Controls.Private 1.0
ComboBox {
- implicitWidth: 128
- implicitHeight: 32
+ implicitWidth: $(128)
+ implicitHeight: $(32)
style: ComboBoxStyle {
background: AdwaitaRectangle {
width: control.width
Arrow {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
- anchors.rightMargin: 16
+ anchors.rightMargin: $(16)
+ scale: $(1.3)
rotation: 90
- scale: 1.3
}
}
+ font.pointSize: $(9)
label: Text {
width: control.width
- x: 4
+ x: $(4)
+ font.pointSize: $(9)
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignLeft
text: control.currentText
diff --git a/liveusb/components/AdwaitaProgressBar.qml b/liveusb/components/AdwaitaProgressBar.qml
index e663759..877d3da 100644
--- a/liveusb/components/AdwaitaProgressBar.qml
+++ b/liveusb/components/AdwaitaProgressBar.qml
@@ -4,18 +4,18 @@ import QtQuick.Controls.Styles 1.2
ProgressBar {
id: root
- width: 100
- height: 6
+ width: $(100)
+ height: $(6)
property color progressColor: "#54aada"
property color backgroundColor: "#c3c3c3"
style: ProgressBarStyle {
background: Rectangle {
- height: 6
+ height: $(6)
border {
color: "#777777"
- width: 1
+ width: $(1)
}
- radius: 3
+ radius: $(3)
clip: true
gradient: Gradient {
GradientStop { position: 0.0; color: Qt.lighter(root.backgroundColor, 1.05) }
@@ -24,12 +24,12 @@ ProgressBar {
}
progress: Rectangle {
clip: true
- height: 4
+ height: $(4)
border {
color: "#777777"
- width: 1
+ width: $(1)
}
- radius: 3
+ radius: $(3)
gradient: Gradient {
GradientStop { position: 0.0; color: Qt.lighter(root.progressColor, 1.05) }
GradientStop { position: 0.9; color: root.progressColor }
diff --git a/liveusb/components/AdwaitaRadioButton.qml b/liveusb/components/AdwaitaRadioButton.qml
index ca53d31..0a4170f 100644
--- a/liveusb/components/AdwaitaRadioButton.qml
+++ b/liveusb/components/AdwaitaRadioButton.qml
@@ -5,8 +5,8 @@ import QtQuick.Controls.Styles 1.0
RadioButton {
style: RadioButtonStyle {
indicator: AdwaitaRectangle {
- implicitWidth: 15
- implicitHeight: 15
+ implicitWidth: $(15)
+ implicitHeight: $(15)
radius: width / 2 + 1
Rectangle {
anchors.centerIn: parent
@@ -17,6 +17,11 @@ RadioButton {
visible: control.checked
}
}
+ label: Text {
+ font.pointSize: $(9)
+ text: control.text
+ }
+ spacing: $(8)
}
}
diff --git a/liveusb/components/AdwaitaRectangle.qml b/liveusb/components/AdwaitaRectangle.qml
index e04a407..f318f5e 100644
--- a/liveusb/components/AdwaitaRectangle.qml
+++ b/liveusb/components/AdwaitaRectangle.qml
@@ -2,13 +2,13 @@ import QtQuick 2.0
Rectangle {
id: rect
- implicitHeight: 36
- implicitWidth: 36
- radius: 3
+ implicitHeight: $(36)
+ implicitWidth: $(36)
+ radius: $(3)
Rectangle {
- radius: parent.radius - 1
- anchors.margins: 0.5
+ radius: parent.radius - $(1)
+ anchors.margins: $(0.5)
anchors.fill: parent
gradient: control.enabled ? !(control.pressed || control.checked) ? !control.hovered ? regularGradient: hoveredGradient : downGradient : disabledGradient
Gradient {
diff --git a/liveusb/components/BackButton.qml b/liveusb/components/BackButton.qml
index 5848a54..9cd3495 100644
--- a/liveusb/components/BackButton.qml
+++ b/liveusb/components/BackButton.qml
@@ -2,39 +2,40 @@ import QtQuick 2.0
import QtQuick.Controls 1.2
AdwaitaButton {
- width: arrow.width + text.width + 28
+ width: arrow.width + text.width + $(28)
Item {
id: arrow
anchors.left: parent.left
- anchors.leftMargin: 12
+ anchors.leftMargin: $(12)
anchors.verticalCenter: parent.verticalCenter
rotation: -45
transformOrigin: Item.Center
- width: 10
- height: 10
+ width: $(10)
+ height: $(10)
Rectangle {
- x: 1.5
- y: 1.5
- width: 2
- height: 9
- radius: 2
+ x: $(1.5)
+ y: $(1.5)
+ width: $(2)
+ height: $(9)
+ radius: $(2)
color: "#444444"
}
Rectangle {
- y: 1.5
- x: 1.5
- width: 9
- height: 2
- radius: 2
+ y: $(1.5)
+ x: $(1.5)
+ width: $(9)
+ height: $(2)
+ radius: $(2)
color: "#444444"
}
}
Text {
id: text
text: "Back"
+ font.pointSize: $(9)
anchors {
left: arrow.left
- leftMargin: 16
+ leftMargin: $(16)
verticalCenter: parent.verticalCenter
}
}
diff --git a/liveusb/components/DownloadDialog.qml b/liveusb/components/DownloadDialog.qml
index b9f6e31..b091753 100644
--- a/liveusb/components/DownloadDialog.qml
+++ b/liveusb/components/DownloadDialog.qml
@@ -8,10 +8,10 @@ Dialog {
id: root
title: qsTranslate("", "Write %1 to USB").arg(liveUSBData.currentImage.name)
- height: layout.height + 56
+ height: layout.height + $(56)
standardButtons: StandardButton.NoButton
- width: 640
+ width: $(640)
function reset() {
writeImmediately.confirmed = false
@@ -34,28 +34,28 @@ Dialog {
horizontalScrollBarPolicy: Qt.ScrollBarAlwaysOff
contentItem: Item {
width: contentWrapper.width
- height: layout.height + 32
+ height: layout.height + $(32)
Column {
id: layout
- spacing: 24
+ spacing: $(24)
anchors {
top: parent.top
left: parent.left
right: parent.right
- topMargin: 32
- leftMargin: 48
+ topMargin: $(32)
+ leftMargin: $(48)
rightMargin: anchors.leftMargin
}
Column {
id: infoColumn
- spacing: 4
+ spacing: $(4)
width: parent.width
Repeater {
model: liveUSBData.currentImage.error
RowLayout {
width: infoColumn.width
- spacing: 8
+ spacing: $(8)
Rectangle {
anchors.centerIn: cross
width: cross.height
@@ -73,13 +73,14 @@ Dialog {
verticalAlignment: Text.AlignVCenter
color: "red"
text: "✕"
- font.pointSize: 14
+ font.pointSize: $(14)
}
Text {
Layout.fillHeight: true
Layout.fillWidth: true
verticalAlignment: Text.AlignVCenter
wrapMode: Text.Wrap
+ font.pointSize: $(9)
text: liveUSBData.currentImage.error[index]
}
}
@@ -90,19 +91,20 @@ Dialog {
model: (liveUSBData.currentImage.writer.finished || liveUSBData.currentImage.error.length > 0) ? null : liveUSBData.currentImage.warning
RowLayout {
width: infoColumn.width
- spacing: 8
+ spacing: $(8)
Text {
Layout.fillHeight: true
verticalAlignment: Text.AlignVCenter
color: "red"
text: "!"
- font.pointSize: 14
+ font.pointSize: $(14)
}
Text {
Layout.fillHeight: true
Layout.fillWidth: true
verticalAlignment: Text.AlignVCenter
wrapMode: Text.Wrap
+ font.pointSize: $(9)
text: liveUSBData.currentImage.warning[index]
}
}
@@ -112,7 +114,7 @@ Dialog {
model: liveUSBData.currentImage.error.length > 0 ? null : liveUSBData.currentImage.info
RowLayout {
width: infoColumn.width
- spacing: 8
+ spacing: $(8)
// a rotated exclamation mark instead of an 'i' as for information - that's funny, right... right?!
Text {
Layout.fillHeight: true
@@ -120,7 +122,7 @@ Dialog {
color: "blue"
text: "!"
rotation: 180
- font.pointSize: 14
+ font.pointSize: $(14)
}
Text {
Layout.fillHeight: true
@@ -145,6 +147,7 @@ Dialog {
Layout.fillWidth: true
Layout.fillHeight: true
horizontalAlignment: Text.AlignHCenter
+ font.pointSize: $(9)
property double leftSize: liveUSBData.currentImage.download.maxProgress - liveUSBData.currentImage.download.progress
property string leftStr: leftSize <= 0 ? "" :
(leftSize < 1024) ? (leftSize + " B") :
@@ -172,17 +175,17 @@ Dialog {
RowLayout {
anchors.horizontalCenter: parent.horizontalCenter
- spacing: 32
+ spacing: $(32)
IndicatedImage {
source: liveUSBData.currentImage.logo
- sourceSize.width: 64
- sourceSize.height: 64
+ sourceSize.width: $(64)
+ sourceSize.height: $(64)
fillMode: Image.PreserveAspectFit
}
Arrow {
id: writeArrow
anchors.verticalCenter: parent.verticalCenter
- height: 14
+ height: $(14)
SequentialAnimation {
running: liveUSBData.currentImage.writer.running
loops: -1
@@ -227,9 +230,9 @@ Dialog {
enabled: !liveUSBData.currentImage.writer.running
Row {
- spacing: 8
+ spacing: $(8)
anchors.fill: parent
- anchors.leftMargin: 8
+ anchors.leftMargin: $(8)
visible: liveUSBData.usbDriveNames.length <= 0
BusyIndicator {
anchors.verticalCenter: parent.verticalCenter
@@ -241,6 +244,7 @@ Dialog {
verticalAlignment: Text.AlignVCenter
text: qsTranslate("", "There are no portable drives connected")
color: "gray"
+ font.pointSize: $(9)
}
}
}
@@ -248,10 +252,11 @@ Dialog {
ColumnLayout {
width: parent.width
- spacing: 12
+ spacing: $(12)
RowLayout {
height: acceptButton.height
width: parent.width
+ spacing: $(10)
AdwaitaButton {
id: optionGroup
implicitHeight: parent.height / 8 * 5
@@ -270,7 +275,7 @@ Dialog {
verticalAlignment: Text.AlignVCenter
text: "+"
font.bold: true
- font.pointSize: 12
+ font.pointSize: $(12)
}
}
@@ -279,6 +284,7 @@ Dialog {
verticalAlignment: Text.AlignVCenter
text: qsTranslate("", "Options")
enabled: optionGroup.enabled
+ font.pointSize: $(9)
MouseArea {
anchors.fill: parent
onClicked: optionGroup.checked = !optionGroup.checked
@@ -287,7 +293,7 @@ Dialog {
Item {
Layout.fillWidth: true
- height: 1
+ height: $(1)
}
AdwaitaButton {
@@ -296,7 +302,7 @@ Dialog {
right: acceptButton.left
top: parent.top
bottom: parent.bottom
- rightMargin: 6
+ rightMargin: $(6)
}
text: qsTranslate("", "Cancel")
enabled: !liveUSBData.currentImage.writer.running
@@ -371,11 +377,11 @@ Dialog {
}
Column {
id: advancedOptions
- spacing: 6
+ spacing: $(6)
Repeater {
id: groupLayoutRepeater
model: optionGroup.checked ? liveUSBData.optionValues : null
- CheckBox {
+ AdwaitaCheckBox {
checked: liveUSBData.optionValues[index]
enabled: !liveUSBData.currentImage.writer.running
height: implicitHeight
@@ -389,7 +395,7 @@ Dialog {
}
}
// It's better to have this one separately to have the confirmation clearer
- CheckBox {
+ AdwaitaCheckBox {
id: writeImmediately
height: optionGroup.checked ? implicitHeight : 0
visible: optionGroup.checked
diff --git a/liveusb/components/ImageDetails.qml b/liveusb/components/ImageDetails.qml
index 9ef2866..05ff0c8 100644
--- a/liveusb/components/ImageDetails.qml
+++ b/liveusb/components/ImageDetails.qml
@@ -25,15 +25,15 @@ Item {
leftMargin: mainWindow.margin
rightMargin: anchors.leftMargin
}
- height: 64
+ height: $(64)
BackButton {
id: backButton
anchors {
left: parent.left
top: parent.top
bottom: parent.bottom
- topMargin: 16
- bottomMargin: 16
+ topMargin: $(16)
+ bottomMargin: $(16)
}
onClicked: {
canGoBack = false
@@ -53,8 +53,8 @@ Item {
right: parent.right
top: parent.top
bottom: parent.bottom
- topMargin: 16
- bottomMargin: 16
+ topMargin: $(16)
+ bottomMargin: $(16)
}
}
}
@@ -66,45 +66,43 @@ Item {
}
contentItem: Item {
- y: 72
+ y: $(72)
x: mainWindow.margin
width: root.width - 2 * mainWindow.margin
- height: childrenRect.height + 64 + 32
+ height: childrenRect.height + $(64) + $(32)
ColumnLayout {
width: parent.width
- spacing: 32
+ spacing: $(32)
RowLayout {
anchors.left: parent.left
anchors.right: parent.right
- spacing: 32
+ spacing: $(32)
Layout.alignment: Qt.AlignLeft
Item {
- width: 64
- height: 64
+ width: $(64)
+ height: $(64)
IndicatedImage {
id: iconRect
- anchors.centerIn: parent
+ anchors.fill: parent
source: liveUSBData.currentImage.logo
- sourceSize.width: parent.width
- sourceSize.height: parent.height
fillMode: Image.PreserveAspectFit
}
}
ColumnLayout {
Layout.alignment: Qt.AlignLeft
- spacing: 8
+ spacing: $(8)
RowLayout {
Text {
Layout.fillWidth: true
anchors.left: parent.left
- font.pointSize: 13
+ font.pointSize: $(13)
text: liveUSBData.currentImage.name
}
Text {
anchors.right: parent.right
- font.pointSize: 11
+ font.pointSize: $(11)
property double size: liveUSBData.currentImage.size
text: size <= 0 ? "" :
(size < 1024) ? (size + " B") :
@@ -120,6 +118,7 @@ Item {
RowLayout {
anchors.verticalCenter: parent.verticalCenter
visible: liveUSBData.currentImage.arch.length
+ spacing: $(8)
ExclusiveGroup {
id: archEG
}
@@ -139,6 +138,7 @@ Item {
RowLayout {
visible: liveUSBData.currentImage.isLocal
+ spacing: $(12)
AdwaitaButton {
text: qsTranslate("", "Select Live ISO")
onClicked: {
@@ -147,6 +147,7 @@ Item {
}
}
Text {
+ font.pointSize: $(9)
text: qsTranslate("", "Selected file: %1").arg(liveUSBData.currentImage.path ? (((String)(liveUSBData.currentImage.path)).split("/").slice(-1)[0]) : qsTranslate("", "None"))
}
}
@@ -154,7 +155,7 @@ Item {
Text {
// I'm sorry, everyone, I can't find a better way to determine if the date is valid
text: liveUSBData.currentImage.releaseDate.toLocaleDateString().length > 0 ? (qsTranslate("", "Released on %s").arg(liveUSBData.currentImage.releaseDate.toLocaleDateString())) : ""
- font.pointSize: 8
+ font.pointSize: $(8)
color: "gray"
}
}
@@ -165,7 +166,7 @@ Item {
wrapMode: Text.WordWrap
text: liveUSBData.currentImage.description
textFormat: Text.RichText
- font.pointSize: 9
+ font.pointSize: $(9)
}
Repeater {
id: screenshotRepeater
@@ -184,25 +185,25 @@ Item {
incrementControl: Item {}
decrementControl: Item {}
corner: Item {
- implicitWidth: 11
- implicitHeight: 11
+ implicitWidth: $(11)
+ implicitHeight: $(11)
}
scrollBarBackground: Rectangle {
color: "#dddddd"
- implicitWidth: 11
- implicitHeight: 11
+ implicitWidth: $(11)
+ implicitHeight: $(11)
}
handle: Rectangle {
color: "#b3b5b6"
- x: 2
- y: 2
- implicitWidth: 7
- implicitHeight: 7
- radius: 4
+ x: $(2)
+ y: $(2)
+ implicitWidth: $(7)
+ implicitHeight: $(7)
+ radius: $(4)
}
transientScrollBars: false
- handleOverlap: 1
- minimumHandleLength: 10
+ handleOverlap: $(1)
+ minimumHandleLength: $(10)
}
}
DownloadDialog {
diff --git a/liveusb/components/ImageList.qml b/liveusb/components/ImageList.qml
index 34e4460..7d9f911 100644
--- a/liveusb/components/ImageList.qml
+++ b/liveusb/components/ImageList.qml
@@ -22,17 +22,17 @@ Item {
color: searchInput.activeFocus ? "#4a90d9" : "#c3c3c3"
width: 1
}
- radius: 6
+ radius: $(6)
color: "white"
anchors {
top: parent.top
left: parent.left
right: archSelect.left
- topMargin: 12
+ topMargin: $(12)
leftMargin: mainWindow.margin
- rightMargin: 4
+ rightMargin: $(4)
}
- height: 36
+ height: $(36)
Item {
id: magnifyingGlass
@@ -41,17 +41,17 @@ Item {
leftMargin: (parent.height - height) / 2
verticalCenter: parent.verticalCenter
}
- height: childrenRect.height + 3
- width: childrenRect.width + 2
+ height: childrenRect.height + $(3)
+ width: childrenRect.width + $(2)
Rectangle {
- height: 11
+ height: $(11)
antialiasing: true
width: height
radius: height / 2
color: "black"
Rectangle {
- height: 7
+ height: $(7)
antialiasing: true
width: height
radius: height / 2
@@ -59,11 +59,11 @@ Item {
anchors.centerIn: parent
}
Rectangle {
- height: 2
- width: 6
- radius: 2
- x: 8
- y: 11
+ height: $(2)
+ width: $(6)
+ radius: $(2)
+ x: $(8)
+ y: $(11)
rotation: 45
color: "black"
}
@@ -76,11 +76,12 @@ Item {
top: parent.top
bottom: parent.bottom
right: parent.right
- margins: 8
+ margins: $(8)
}
Text {
anchors.fill: parent
color: "light gray"
+ font.pointSize: $(9)
text: qsTranslate("", "Find an operating system image")
visible: !parent.activeFocus && parent.text.length == 0
verticalAlignment: Text.AlignVCenter
@@ -106,10 +107,10 @@ Item {
right: parent.right
top: parent.top
rightMargin: mainWindow.margin
- topMargin: 12
+ topMargin: $(12)
}
- height: 36
- width: 148
+ height: $(36)
+ width: $(148)
model: liveUSBData.releaseProxyModel.possibleArchs
onCurrentIndexChanged: {
liveUSBData.releaseProxyModel.archFilter = currentText
@@ -132,9 +133,9 @@ Item {
id: whiteBackground
z: -1
clip: true
- radius: 6
+ radius: $(6)
color: "white"
- y: liveUSBData.releaseProxyModel.isFront || moveUp.running ? parent.height / 2 - height / 2 : 54
+ y: liveUSBData.releaseProxyModel.isFront || moveUp.running ? parent.height / 2 - height / 2 : $(54)
Behavior on y {
id: moveUp
enabled: false
@@ -145,7 +146,7 @@ Item {
}
//height: !liveUSBData.releaseProxyModel.isFront ? parent.height - 54 + 4 : parent.height - 108
- height: liveUSBData.releaseProxyModel.isFront ? 84 * 3 + 36 : parent.height
+ height: liveUSBData.releaseProxyModel.isFront ? $(84) * 3 + $(36) : parent.height
/*Behavior on height {
NumberAnimation { duration: root.fadeDuration }
@@ -175,7 +176,7 @@ Item {
topMargin: whiteBackground.y
}
footer: Item {
- height: !liveUSBData.releaseProxyModel.isFront ? 54 : 36
+ height: !liveUSBData.releaseProxyModel.isFront ? $(54) : $(36)
width: osListView.width
Rectangle {
clip: true
@@ -193,8 +194,8 @@ Item {
Repeater {
model: 3
Rectangle {
- height: 4
- width: 4
+ height: $(4)
+ width: $(4)
color: "#bebebe"
}
}
@@ -202,6 +203,7 @@ Item {
Text {
id: threeDotText
y: threeDotDots.hidden ? parent.height / 2 - height / 2 : -height
+ font.pointSize: $(9)
anchors.horizontalCenter: threeDotDots.horizontalCenter
Behavior on y { NumberAnimation { duration: 60 } }
clip: true
@@ -266,25 +268,25 @@ Item {
incrementControl: Item {}
decrementControl: Item {}
corner: Item {
- implicitWidth: 11
- implicitHeight: 11
+ implicitWidth: $(11)
+ implicitHeight: $(11)
}
scrollBarBackground: Rectangle {
color: "#dddddd"
- implicitWidth: 11
- implicitHeight: 11
+ implicitWidth: $(11)
+ implicitHeight: $(11)
}
handle: Rectangle {
color: "#b3b5b6"
- x: 2
- y: 2
- implicitWidth: 7
- implicitHeight: 7
- radius: 4
+ x: $(2)
+ y: $(2)
+ implicitWidth: $(7)
+ implicitHeight: $(7)
+ radius: $(4)
}
transientScrollBars: false
- handleOverlap: 1
- minimumHandleLength: 10
+ handleOverlap: $(1)
+ minimumHandleLength: $(10)
}
}
@@ -292,13 +294,13 @@ Item {
id: imageDelegate
Item {
width: parent.width
- height: 84
+ height: $(84)
Rectangle {
width: parent.width - 2
height: index == 0 ? parent.height - 1 : parent.height
x: 1
y: index == 0 ? 1 : 0
- radius: 4
+ radius: $(4)
color: "transparent"
IndicatedImage {
id: iconRect
@@ -306,8 +308,8 @@ Item {
top: parent.top
left: parent.left
bottom: parent.bottom
- leftMargin: 32
- topMargin: 16
+ leftMargin: $(32)
+ topMargin: $(16)
bottomMargin: anchors.topMargin
}
width: height
@@ -323,25 +325,27 @@ Item {
left: iconRect.right
right: arrow.left
bottom: parent.bottom
- leftMargin: 28
- rightMargin: 14
+ leftMargin: $(28)
+ rightMargin: $(14)
}
Text {
+ font.pointSize: $(9)
text: release.name
anchors {
bottom: parent.verticalCenter
left: parent.left
- bottomMargin: 2
+ bottomMargin: $(2)
}
// font.weight: Font.Bold
}
Text {
+ font.pointSize: $(9)
text: release.summary
anchors {
top: parent.verticalCenter
left: parent.left
right: parent.right
- topMargin: 2
+ topMargin: $(2)
}
wrapMode: Text.Wrap
color: "#a1a1a1"
@@ -351,10 +355,11 @@ Item {
Arrow {
id: arrow
visible: !release.isLocal
+ scale: $(1)
anchors {
verticalCenter: parent.verticalCenter
right: parent.right
- rightMargin: 20
+ rightMargin: $(20)
}
}
Rectangle {
diff --git a/liveusb/components/IndicatedImage.qml b/liveusb/components/IndicatedImage.qml
index a007958..a3239e5 100644
--- a/liveusb/components/IndicatedImage.qml
+++ b/liveusb/components/IndicatedImage.qml
@@ -19,6 +19,8 @@ Image {
top: parent.top
horizontalCenter: parent.horizontalCenter
}
+ width: $(implicitWidth)
+ height: $(implicitHeight)
opacity: parent.status == Image.Ready ? 0 : 1
Behavior on opacity {
NumberAnimation {
diff --git a/liveusb/components/MenuButton.qml b/liveusb/components/MenuButton.qml
index 545446f..6dd40b3 100644
--- a/liveusb/components/MenuButton.qml
+++ b/liveusb/components/MenuButton.qml
@@ -4,16 +4,16 @@ import QtQuick.Controls 1.2
AdwaitaButton {
Item {
anchors.centerIn: parent
- width: 10
- height: 10
+ width: $(10)
+ height: $(10)
Column {
- spacing: 2
+ spacing: $(2)
Repeater {
model: 3
delegate: Rectangle {
- height: 2
- width: 10
- radius: 2
+ height: $(2)
+ width: $(10)
+ radius: $(2)
color: "#444444"
}
}
diff --git a/liveusb/components/QuitButton.qml b/liveusb/components/QuitButton.qml
index b967598..39bcdaa 100644
--- a/liveusb/components/QuitButton.qml
+++ b/liveusb/components/QuitButton.qml
@@ -7,16 +7,16 @@ AdwaitaButton {
rotation: 45
transformOrigin: Item.Center
Rectangle {
- width: 2
- height: 12
- radius: 1
+ width: $(2)
+ height: $(12)
+ radius: $(1)
anchors.centerIn: parent
color: "#a1a1a1"
}
Rectangle {
- width: 12
- height: 2
- radius: 1
+ width: $(12)
+ height: $(2)
+ radius: $(1)
anchors.centerIn: parent
color: "#a1a1a1"
}
diff --git a/liveusb/liveusb.qml b/liveusb/liveusb.qml
index dade64a..a7e7729 100644
--- a/liveusb/liveusb.qml
+++ b/liveusb/liveusb.qml
@@ -9,18 +9,23 @@ import "components"
ApplicationWindow {
id: mainWindow
- minimumWidth: 800
- minimumHeight: 480
- width: 800
- height: 480
+ minimumWidth: $(800)
+ minimumHeight: $(480)
+ width: $(800)
+ height: $(480)
title: qsTranslate("", "Fedora LiveUSB Creator")
SystemPalette {
id: palette
}
+ property real scalingFactor: Math.ceil(Screen.pixelDensity * 25.4) / 96
+ function $(x) {
+ return x * scalingFactor
+ }
+
property bool canGoBack: false
- property real margin: 64 + (width - 800) / 4
+ property real margin: $(64) + (width - $(800)) / 4
Rectangle {
anchors.fill: parent
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/tails-installer.git
More information about the Pkg-privacy-commits
mailing list