on xenial help sign in
Show "Pull to refresh" in white when overlaid in low luminance colors
commitc40431f5f0155ffab4c10cdcb635e718574c3a83 authorAlbert Astals Cid <albert.astals@canonical.com> dateTue 16 Aug 2016, 16:06 (10 years ago) parent38f19ac
3 files changed+4
qml/Dash/DashPageHeader.qml+2 qml/Dash/GenericScopeView.qml+1 qml/Dash/PullToRefreshScopeStyle.qml+1
qml/Dash/DashPageHeader.qml+2
@@ -18,6 +18,7 @@ import QtQuick 2.4
1818import Ubuntu.Components 1.3
1919import Ubuntu.Components.Popups 1.3
2020import Ubuntu.Components.ListItems 1.3
21+import Utils 0.1
2122import "../Components"
2223
2324Item {
@@ -25,6 +26,7 @@ Item {
2526 objectName: "pageHeader"
2627 implicitHeight: headerContainer.height + signatureLineHeight
2728 readonly property real signatureLineHeight: showSignatureLine ? units.gu(2) : 0
29+ readonly property real headerDividerLuminance: Style.luminance(bottomBorder.color)
2830
2931 property int activeFiltersCount: 0
3032 property bool scopeHasFilters: false
qml/Dash/GenericScopeView.qml+1
@@ -722,6 +722,7 @@ FocusScope {
722722 target: categoryView
723723
724724 readonly property real contentY: categoryView.contentY - categoryView.originY
725+ readonly property real headerDividerLuminance: categoryView.pageHeader.headerDividerLuminance
725726 y: -contentY - units.gu(5)
726727
727728 onRefresh: {
qml/Dash/PullToRefreshScopeStyle.qml+1
@@ -48,6 +48,7 @@ PullToRefreshStyle {
4848 anchors.horizontalCenter: parent.horizontalCenter
4949 horizontalAlignment: Text.AlignHCenter
5050 verticalAlignment: Text.AlignVCenter
51+ color: styledItem.headerDividerLuminance < 0.3 ? "white" : theme.palette.normal.baseText
5152 states: [
5253 State {
5354 name: "pulling"