diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2016-03-30 20:16:50 -0500 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2016-03-30 20:16:50 -0500 |
commit | 27a62a021058342a32fd8670207b662779f9193e (patch) | |
tree | 057606ee3129fe8ee093b371a1413ea8515de216 | |
parent | f0be2764da557e7576c4645848984fac5f94b611 (diff) | |
download | subsurface-27a62a021058342a32fd8670207b662779f9193e.tar.gz |
Revert "QML UI: make dives outside of dive trips always visible"
This reverts commit a065b974723896df91a8da93803fbb47571201bf.
The folding as implemented is too painfully slow and buggy on devices.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | qt-mobile/qml/DiveList.qml | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/qt-mobile/qml/DiveList.qml b/qt-mobile/qml/DiveList.qml index 4b4c5794f..988221efd 100644 --- a/qt-mobile/qml/DiveList.qml +++ b/qt-mobile/qml/DiveList.qml @@ -21,8 +21,8 @@ MobileComponents.Page { enabled: true checked: diveListView.currentIndex === model.index width: parent.width - height: dive.tripMeta == activeTrip || dive.tripMeta === "--" ? diveDelegateItem.height : 0 - visible: dive.tripMeta == activeTrip || dive.tripMeta === "--" ? true : false + height: dive.tripMeta == activeTrip ? diveDelegateItem.height : 0 + visible: dive.tripMeta == activeTrip ? true : false property real detailsOpacity : 0 property int horizontalPadding: MobileComponents.Units.gridUnit / 2 - MobileComponents.Units.smallSpacing + 1 @@ -113,10 +113,8 @@ MobileComponents.Page { id: tripHeading Item { width: page.width - MobileComponents.Units.gridUnit - height: (section !== "--") ? - childrenRect.height + MobileComponents.Units.smallSpacing * 2 + Math.max(2, MobileComponents.Units.gridUnit / 2) : - Math.max(2, MobileComponents.Units.gridUnit / 2) - visible: section !== "---" + height: childrenRect.height + MobileComponents.Units.smallSpacing * 2 + Math.max(2, MobileComponents.Units.gridUnit / 2) + MobileComponents.Heading { id: sectionText text: { @@ -139,23 +137,19 @@ MobileComponents.Page { leftMargin: MobileComponents.Units.gridUnit / 2 right: parent.right } - color: subsurfaceTheme.accentColor + color: textColor level: 2 MouseArea { anchors.fill: sectionText - enabled: section !== "--" onClicked: { - if (activeTrip != section) - activeTrip = section - else - activeTrip = "" + activeTrip = section } } } Rectangle { height: Math.max(2, MobileComponents.Units.gridUnit / 12) // we want a thicker line anchors { - top: section !== "--" ? sectionText.bottom : sectionText.top + top: sectionText.bottom left: parent.left leftMargin: MobileComponents.Units.gridUnit * -2 rightMargin: MobileComponents.Units.gridUnit * -2 |