mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-26 13:08:48 +03:00
Use readonly properties where possible
This commit is contained in:
parent
9b8e6c7f5c
commit
47a7adf823
3 changed files with 5 additions and 5 deletions
|
@ -43,7 +43,7 @@ ScrollView {
|
||||||
property alias model: row.model
|
property alias model: row.model
|
||||||
// use comma to update on scroll
|
// use comma to update on scroll
|
||||||
property var attachedPos: chat.contentY, attached ? chat.mapFromItem(attached, attached ? attached.width - width : 0, -height) : null
|
property var attachedPos: chat.contentY, attached ? chat.mapFromItem(attached, attached ? attached.width - width : 0, -height) : null
|
||||||
property int padding: 4
|
readonly property int padding: 4
|
||||||
|
|
||||||
visible: Settings.buttonsInTimeline && !!attached && (attached.hovered || messageActionHover.hovered)
|
visible: Settings.buttonsInTimeline && !!attached && (attached.hovered || messageActionHover.hovered)
|
||||||
x: attached ? attachedPos.x : 0
|
x: attached ? attachedPos.x : 0
|
||||||
|
|
|
@ -20,7 +20,7 @@ Page {
|
||||||
property var colors: currentActivePalette
|
property var colors: currentActivePalette
|
||||||
property var systemInactive
|
property var systemInactive
|
||||||
property var inactiveColors: currentInactivePalette ? currentInactivePalette : systemInactive
|
property var inactiveColors: currentInactivePalette ? currentInactivePalette : systemInactive
|
||||||
property int avatarSize: 40
|
readonly property int avatarSize: 40
|
||||||
property real highlightHue: colors.highlight.hslHue
|
property real highlightHue: colors.highlight.hslHue
|
||||||
property real highlightSat: colors.highlight.hslSaturation
|
property real highlightSat: colors.highlight.hslSaturation
|
||||||
property real highlightLight: colors.highlight.hslLightness
|
property real highlightLight: colors.highlight.hslLightness
|
||||||
|
|
|
@ -13,9 +13,9 @@ Item {
|
||||||
property real radius: 0
|
property real radius: 0
|
||||||
property color color: "#22000000"
|
property color color: "#22000000"
|
||||||
property real maxRadius: Math.max(width, height)
|
property real maxRadius: Math.max(width, height)
|
||||||
property real radiusAnimationRate: 0.05
|
readonly property real radiusAnimationRate: 0.05
|
||||||
property real radiusTailAnimationRate: 0.5
|
readonly property real radiusTailAnimationRate: 0.5
|
||||||
property real opacityAnimationDuration: 300
|
readonly property real opacityAnimationDuration: 300
|
||||||
readonly property real diameter: radius * 2
|
readonly property real diameter: radius * 2
|
||||||
property real centerX
|
property real centerX
|
||||||
property real centerY
|
property real centerY
|
||||||
|
|
Loading…
Reference in a new issue