summary refs log tree commit diff
path: root/resources
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2023-06-19 20:45:57 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2023-06-19 20:45:57 +0200
commitefda425b6a569e135e6ff51a4124d52c844b28d8 (patch)
treeebbc32b0293d7f5057ba4ea9ca4dcdcd62a97211 /resources
parentFix UserSettingsModel and Communities singleton instantiation (diff)
downloadnheko-efda425b6a569e135e6ff51a4124d52c844b28d8.tar.xz
Some qmllint fixes
Diffstat (limited to 'resources')
-rw-r--r--resources/qml/delegates/EncryptionEnabled.qml6
-rw-r--r--resources/qml/pages/UserSettingsPage.qml2
-rw-r--r--resources/qml/voip/DeviceError.qml6
3 files changed, 6 insertions, 8 deletions
diff --git a/resources/qml/delegates/EncryptionEnabled.qml b/resources/qml/delegates/EncryptionEnabled.qml
index c8671c84..0e2b7fc0 100644
--- a/resources/qml/delegates/EncryptionEnabled.qml
+++ b/resources/qml/delegates/EncryptionEnabled.qml
@@ -4,7 +4,6 @@
 
 import ".."
 import QtQuick 2.15
-import QtQuick.Controls 2.15
 import QtQuick.Layouts 1.15
 import im.nheko 1.0
 
@@ -15,7 +14,6 @@ Rectangle {
 
     radius: fontMetrics.lineSpacing / 2 + Nheko.paddingMedium
     width: parent.width ? Math.min(parent.width, 700) : 0
-    anchors.horizontalCenter: parent.horizontalCenter
     height: contents.implicitHeight + Nheko.paddingMedium * 2
     color: palette.alternateBase
     border.color: Nheko.theme.green
@@ -31,8 +29,8 @@ Rectangle {
         Image {
             source: "image://colorimage/:/icons/icons/ui/shield-filled-checkmark.svg?" + Nheko.theme.green
             Layout.alignment: Qt.AlignVCenter
-            width: 24
-            height: width
+            Layout.preferredWidth: 24
+            Layout.preferredHeight: 24
         }
 
         Column {
diff --git a/resources/qml/pages/UserSettingsPage.qml b/resources/qml/pages/UserSettingsPage.qml
index c23606ff..0a3f5e52 100644
--- a/resources/qml/pages/UserSettingsPage.qml
+++ b/resources/qml/pages/UserSettingsPage.qml
@@ -1,7 +1,7 @@
 // SPDX-FileCopyrightText: Nheko Contributors
 //
 // SPDX-License-Identifier: GPL-3.0-or-later
-
+pragma ComponentBehavior: Bound
 import ".."
 import "../ui"
 import Qt.labs.platform 1.1 as Platform
diff --git a/resources/qml/voip/DeviceError.qml b/resources/qml/voip/DeviceError.qml
index afb70b7f..4b9b4675 100644
--- a/resources/qml/voip/DeviceError.qml
+++ b/resources/qml/voip/DeviceError.qml
@@ -5,9 +5,9 @@
 import QtQuick 2.9
 import QtQuick.Controls 2.3
 import QtQuick.Layouts 1.2
-import im.nheko 1.0
 
 Popup {
+    id: r
     property string errorString
     property var image
 
@@ -24,11 +24,11 @@ Popup {
         Image {
             Layout.preferredWidth: 16
             Layout.preferredHeight: 16
-            source: "image://colorimage/" + image + "?" + palette.windowText
+            source: "image://colorimage/" + r.image + "?" + palette.windowText
         }
 
         Label {
-            text: errorString
+            text: r.errorString
             color: palette.windowText
         }