Merge lp:~dpm/ubuntu-filemanager-app/kill-purple into lp:ubuntu-filemanager-app

Proposed by David Planella
Status: Merged
Approved by: Arto Jalkanen
Approved revision: 315
Merged at revision: 315
Proposed branch: lp:~dpm/ubuntu-filemanager-app/kill-purple
Merge into: lp:ubuntu-filemanager-app
Diff against target: 186 lines (+2/-161)
2 files modified
src/app/qml/components/SuruSheetStyle.qml (+0/-151)
src/app/qml/filemanager.qml (+2/-10)
To merge this branch: bzr merge lp:~dpm/ubuntu-filemanager-app/kill-purple
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Arto Jalkanen Approve
Review via email: mp+239860@code.launchpad.net

Commit message

Work around a toolkit bug that makes purple to be shown in header actions if a gradient is set.

Description of the change

Work around a toolkit bug that makes purple to be shown in header actions if a gradient is set. Removed gradient from the app and removed an unused style file.

To post a comment you must log in.
Revision history for this message
Arto Jalkanen (ajalkane) wrote :

Looks good to me.

review: Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== removed file 'src/app/qml/components/SuruSheetStyle.qml'
2--- src/app/qml/components/SuruSheetStyle.qml 2014-09-20 10:49:51 +0000
3+++ src/app/qml/components/SuruSheetStyle.qml 1970-01-01 00:00:00 +0000
4@@ -1,151 +0,0 @@
5-/*
6- * Copyright 2012 Canonical Ltd.
7- *
8- * This program is free software; you can redistribute it and/or modify
9- * it under the terms of the GNU Lesser General Public License as published by
10- * the Free Software Foundation; version 3.
11- *
12- * This program is distributed in the hope that it will be useful,
13- * but WITHOUT ANY WARRANTY; without even the implied warranty of
14- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15- * GNU Lesser General Public License for more details.
16- *
17- * You should have received a copy of the GNU Lesser General Public License
18- * along with this program. If not, see <http://www.gnu.org/licenses/>.
19- */
20-
21-import QtQuick 2.3
22-import Ubuntu.Components 1.1
23-import Ubuntu.Components.ListItems 1.0 as ListItem
24-
25-Item {
26- id: visuals
27- // styling properties
28- property color backgroundColor: Qt.rgba(0.2,0.2,0.2,0.97)
29- property color headerColor: Qt.rgba(0,0,0,0.2)
30- property real headerHeight: units.gu(6)
31- property real buttonContainerWidth: units.gu(14)
32-
33- implicitWidth: MathUtils.clamp(styledItem.contentsWidth, styledItem.minWidth, styledItem.maxWidth)
34- implicitHeight: header.height + containerItem.height
35-
36- property alias contentItem: containerItem
37-
38- property bool maximized: styledItem.contentsWidth > styledItem.maxWidth
39-
40- UbuntuShape {
41- id: background
42- color: backgroundColor
43- visible: !maximized
44- anchors {
45- left: parent.left
46- right: parent.right
47- top: header.top
48- bottom: containerItem.bottom
49- }
50- }
51-
52- Rectangle {
53- color: backgroundColor
54- visible: maximized
55- anchors {
56- left: parent.left
57- right: parent.right
58- top: header.top
59- bottom: containerItem.bottom
60- }
61- }
62-
63- Item {
64- id: header
65- height: visuals.headerHeight
66- clip: true
67-
68- anchors {
69- top: parent.top
70- left: parent.left
71- right: parent.right
72- }
73-
74- UbuntuShape {
75- anchors {
76- fill: parent
77- bottomMargin: -units.gu(2)
78- }
79-
80- visible: !maximized
81- color: visuals.headerColor
82- }
83-
84- Rectangle {
85- anchors {
86- fill: parent
87- }
88-
89- visible: maximized
90- color: visuals.headerColor
91- }
92-
93- Label {
94- id: headerText
95- anchors {
96- verticalCenter: parent.verticalCenter
97- left: leftButtonContainer.right
98- right: rightButtonContainer.left
99- }
100- width: headerText.implicitWidth + units.gu(4)
101- elide: Text.ElideRight
102- horizontalAlignment: Text.AlignHCenter
103- text: styledItem.title
104- fontSize: "large"
105- color: "#F3F3E7"
106- }
107-
108- Item {
109- id: leftButtonContainer
110- anchors {
111- left: parent.left
112- top: parent.top
113- bottom: parent.bottom
114- }
115- width: visuals.buttonContainerWidth
116- Component.onCompleted: header.updateButton(styledItem.leftButton, leftButtonContainer)
117- }
118-
119- Item {
120- id: rightButtonContainer
121- anchors {
122- right: parent.right
123- top: parent.top
124- bottom: parent.bottom
125- }
126- width: visuals.buttonContainerWidth
127- Component.onCompleted: header.updateButton(styledItem.rightButton, rightButtonContainer)
128- }
129-
130- function updateButton(button, container) {
131- if (!button) return;
132- button.parent = container;
133- button.anchors.left = container.left;
134- button.anchors.right = container.right;
135- button.anchors.verticalCenter = container.verticalCenter;
136- button.anchors.margins = units.gu(1);
137- }
138-
139- Connections {
140- target: styledItem
141- onLeftButtonChanged: header.updateButton(styledItem.leftButton, leftButtonContainer)
142- onRightButtonChanged: header.updateButton(styledItem.rightButton, rightButtonContainer)
143- }
144- }
145-
146- Item {
147- id: containerItem
148- height: false ? styledItem.maxHeight - header.height : MathUtils.clamp(styledItem.contentsHeight, styledItem.minHeight - header.height, styledItem.maxHeight - header.height)
149- anchors {
150- top: header.bottom
151- left: parent.left
152- right: parent.right
153- }
154- }
155-}
156
157=== modified file 'src/app/qml/filemanager.qml'
158--- src/app/qml/filemanager.qml 2014-10-24 03:00:16 +0000
159+++ src/app/qml/filemanager.qml 2014-10-28 14:31:53 +0000
160@@ -27,12 +27,6 @@
161
162 import "ui"
163
164-/*!
165- \brief MainView with Tabs element.
166- First Tab has a single Label and
167- second Tab has a single ToolbarAction.
168-*/
169-
170 MainView {
171 id: mainView
172 // objectName for functional testing purposes (autopilot-qt5)
173@@ -58,11 +52,9 @@
174
175 property bool showSidebar: width >= units.gu(50)
176
177- property bool showToolbar: width >= units.gu(80)
178-
179 headerColor: "#464646"
180- backgroundColor: "#797979"
181- footerColor: "#808080"
182+ backgroundColor: "#464646"
183+ footerColor: "#464646"
184
185 QtObject {
186 id: fileSelector

Subscribers

People subscribed via source and target branches