mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Mobile: avoid dereferencing undefined values
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
face9ba1a8
commit
4e583f9120
1 changed files with 3 additions and 3 deletions
|
@ -155,7 +155,7 @@ Kirigami.ScrollablePage {
|
||||||
anchors.left: leftBarDive.right
|
anchors.left: leftBarDive.right
|
||||||
Controls.Label {
|
Controls.Label {
|
||||||
id: locationText
|
id: locationText
|
||||||
text: location
|
text: (undefined !== location) ? location : ""
|
||||||
font.weight: Font.Bold
|
font.weight: Font.Bold
|
||||||
font.pointSize: subsurfaceTheme.regularPointSize
|
font.pointSize: subsurfaceTheme.regularPointSize
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
@ -179,14 +179,14 @@ Kirigami.ScrollablePage {
|
||||||
|
|
||||||
Controls.Label {
|
Controls.Label {
|
||||||
id: dateLabel
|
id: dateLabel
|
||||||
text: dateTime
|
text: (undefined !== dateTime) ? dateTime : ""
|
||||||
width: Math.max(locationText.width * 0.45, paintedWidth) // helps vertical alignment throughout listview
|
width: Math.max(locationText.width * 0.45, paintedWidth) // helps vertical alignment throughout listview
|
||||||
font.pointSize: subsurfaceTheme.smallPointSize
|
font.pointSize: subsurfaceTheme.smallPointSize
|
||||||
color: innerListItem.checked ? subsurfaceTheme.darkerPrimaryTextColor : secondaryTextColor
|
color: innerListItem.checked ? subsurfaceTheme.darkerPrimaryTextColor : secondaryTextColor
|
||||||
}
|
}
|
||||||
// let's try to show the depth / duration very compact
|
// let's try to show the depth / duration very compact
|
||||||
Controls.Label {
|
Controls.Label {
|
||||||
text: depthDuration
|
text: (undefined !== depthDuration) ? depthDuration : ""
|
||||||
width: Math.max(Kirigami.Units.gridUnit * 3, paintedWidth) // helps vertical alignment throughout listview
|
width: Math.max(Kirigami.Units.gridUnit * 3, paintedWidth) // helps vertical alignment throughout listview
|
||||||
font.pointSize: subsurfaceTheme.smallPointSize
|
font.pointSize: subsurfaceTheme.smallPointSize
|
||||||
color: innerListItem.checked ? subsurfaceTheme.darkerPrimaryTextColor : secondaryTextColor
|
color: innerListItem.checked ? subsurfaceTheme.darkerPrimaryTextColor : secondaryTextColor
|
||||||
|
|
Loading…
Add table
Reference in a new issue