Merge lp:~bzoltan/ubuntu-ui-toolkit/landing_2015-04-17 into lp:ubuntu-ui-toolkit

Proposed by Zoltan Balogh
Status: Merged
Approved by: Zoltan Balogh
Approved revision: 1483
Merged at revision: 1178
Proposed branch: lp:~bzoltan/ubuntu-ui-toolkit/landing_2015-04-17
Merge into: lp:ubuntu-ui-toolkit
Diff against target: 22179 lines (+7468/-9004)
235 files modified
.bzrignore (+8/-4)
components.api (+40/-15)
debian/changelog (+56/-0)
debian/control (+0/-12)
debian/copyright (+23/-0)
debian/rules (+1/-0)
debian/ubuntu-ui-toolkit-autopilot.install (+0/-1)
documentation/overview.qdoc (+8/-0)
documentation/ubuntu-theming.qdoc (+438/-0)
documentation/ubuntu-ui-toolkit-common.qdocconf (+4/-1)
examples/customtheme/customtheme.pro (+18/-0)
examples/customtheme/main.qml (+12/-41)
examples/customtheme/theme/Palette.qml (+5/-3)
examples/examples.pro (+2/-1)
examples/locale/locale.qml (+4/-4)
examples/ubuntu-ui-toolkit-gallery/ListItems.qml (+3/-3)
examples/ubuntu-ui-toolkit-gallery/Pickers.qml (+4/-4)
examples/ubuntu-ui-toolkit-gallery/Styles.qml (+4/-3)
examples/ubuntu-ui-toolkit-gallery/UbuntuShape.qml (+9/-9)
examples/ubuntu-ui-toolkit-gallery/WebLink.qml (+5/-0)
modules/Ubuntu/Components/10/Button.qml (+3/-3)
modules/Ubuntu/Components/11/Button.qml (+3/-3)
modules/Ubuntu/Components/ActivityIndicator.qml (+2/-2)
modules/Ubuntu/Components/AnimatedItem.qml (+2/-1)
modules/Ubuntu/Components/AppHeader.qml (+108/-19)
modules/Ubuntu/Components/CheckBox.qml (+2/-2)
modules/Ubuntu/Components/ComboButton.qml (+2/-2)
modules/Ubuntu/Components/Label.qml (+2/-2)
modules/Ubuntu/Components/ListItems/Caption.qml (+3/-3)
modules/Ubuntu/Components/ListItems/Empty.qml (+3/-3)
modules/Ubuntu/Components/ListItems/ItemSelector.qml (+4/-4)
modules/Ubuntu/Components/ListItems/LabelVisual.qml (+4/-4)
modules/Ubuntu/Components/ListItems/ProgressionVisual.qml (+3/-3)
modules/Ubuntu/Components/ListItems/Standard.qml (+4/-4)
modules/Ubuntu/Components/ListItems/ThinDivider.qml (+3/-3)
modules/Ubuntu/Components/ListItems/ValueSelector.qml (+3/-3)
modules/Ubuntu/Components/MainView.qml (+2/-1)
modules/Ubuntu/Components/MainView12.qml (+18/-8)
modules/Ubuntu/Components/MainViewBase.qml (+17/-10)
modules/Ubuntu/Components/OptionSelector.qml (+5/-5)
modules/Ubuntu/Components/Page10.qml (+3/-31)
modules/Ubuntu/Components/Page11.qml (+5/-3)
modules/Ubuntu/Components/Page13.qml (+84/-0)
modules/Ubuntu/Components/PageHeadConfiguration.qdoc (+202/-0)
modules/Ubuntu/Components/PageHeadConfiguration11.qml (+5/-157)
modules/Ubuntu/Components/PageHeadConfiguration13.qml (+30/-0)
modules/Ubuntu/Components/PageTreeNode.qml (+2/-1)
modules/Ubuntu/Components/Panel.qml (+5/-5)
modules/Ubuntu/Components/Pickers/DatePicker.qml (+3/-3)
modules/Ubuntu/Components/Pickers/Dialer.qml (+4/-3)
modules/Ubuntu/Components/Pickers/DialerHand.qml (+5/-4)
modules/Ubuntu/Components/Pickers/Picker.qml (+3/-3)
modules/Ubuntu/Components/Pickers/PickerDelegate.qml (+3/-3)
modules/Ubuntu/Components/Pickers/PickerPanel.qml (+3/-3)
modules/Ubuntu/Components/Popups/ActionSelectionPopover.qml (+3/-3)
modules/Ubuntu/Components/Popups/Dialog.qml (+3/-3)
modules/Ubuntu/Components/Popups/Popover.qml (+4/-4)
modules/Ubuntu/Components/Popups/SheetBase.qml (+4/-3)
modules/Ubuntu/Components/ProgressBar10.qml (+2/-2)
modules/Ubuntu/Components/PullToRefresh.qml (+3/-3)
modules/Ubuntu/Components/Scrollbar.qml (+4/-3)
modules/Ubuntu/Components/Slider.qml (+4/-3)
modules/Ubuntu/Components/StyledItem.qml (+0/-71)
modules/Ubuntu/Components/Styles/PageHeadStyle.qml (+3/-3)
modules/Ubuntu/Components/Styles/PullToRefreshStyle.qml (+2/-1)
modules/Ubuntu/Components/Switch.qml (+2/-2)
modules/Ubuntu/Components/Tab.qml (+20/-2)
modules/Ubuntu/Components/TabBar.qml (+4/-3)
modules/Ubuntu/Components/Tabs.qml (+4/-1)
modules/Ubuntu/Components/TextArea.qml (+6/-6)
modules/Ubuntu/Components/TextCursor.qml (+3/-3)
modules/Ubuntu/Components/TextField.qml (+5/-5)
modules/Ubuntu/Components/TextInputPopover.qml (+3/-3)
modules/Ubuntu/Components/Themes/Ambiance/BubbleShape.qml (+4/-4)
modules/Ubuntu/Components/Themes/Ambiance/ButtonStyle.qml (+4/-4)
modules/Ubuntu/Components/Themes/Ambiance/CheckBoxStyle.qml (+6/-6)
modules/Ubuntu/Components/Themes/Ambiance/DialerHandStyle.qml (+3/-3)
modules/Ubuntu/Components/Themes/Ambiance/HeadDividerStyle.qml (+3/-0)
modules/Ubuntu/Components/Themes/Ambiance/HeaderStyle.qml (+3/-3)
modules/Ubuntu/Components/Themes/Ambiance/ListItemStyle.qml (+8/-11)
modules/Ubuntu/Components/Themes/Ambiance/OverflowPanel.qml (+119/-1)
modules/Ubuntu/Components/Themes/Ambiance/PageHeadButton.qml (+4/-4)
modules/Ubuntu/Components/Themes/Ambiance/PageHeadStyle.qml (+73/-181)
modules/Ubuntu/Components/Themes/Ambiance/Palette.qml (+4/-4)
modules/Ubuntu/Components/Themes/Ambiance/PickerStyle.qml (+3/-3)
modules/Ubuntu/Components/Themes/Ambiance/ProgressBarStyle.qml (+4/-4)
modules/Ubuntu/Components/Themes/Ambiance/ScrollbarStyle.qml (+3/-3)
modules/Ubuntu/Components/Themes/Ambiance/SliderStyle.qml (+5/-5)
modules/Ubuntu/Components/Themes/Ambiance/SwitchStyle.qml (+5/-5)
modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml (+5/-5)
modules/Ubuntu/Components/Themes/Ambiance/TextAreaStyle.qml (+6/-6)
modules/Ubuntu/Components/Themes/Ambiance/ToolbarStyle.qml (+3/-3)
modules/Ubuntu/Components/Themes/Palette.qml (+8/-8)
modules/Ubuntu/Components/Themes/PaletteValues.qml (+2/-2)
modules/Ubuntu/Components/Themes/SuruDark/MainViewStyle.qml (+3/-2)
modules/Ubuntu/Components/Themes/SuruDark/Palette.qml (+8/-6)
modules/Ubuntu/Components/Themes/qmldir (+4/-0)
modules/Ubuntu/Components/Toolbar.qml (+4/-3)
modules/Ubuntu/Components/ToolbarButton.qml (+2/-2)
modules/Ubuntu/Components/pageUtils.js (+47/-0)
modules/Ubuntu/Components/plugin/plugin.cpp (+14/-6)
modules/Ubuntu/Components/plugin/plugin.pro (+6/-4)
modules/Ubuntu/Components/plugin/privates/listitemdragarea.cpp (+3/-3)
modules/Ubuntu/Components/plugin/privates/listitemdraghandler.cpp (+1/-1)
modules/Ubuntu/Components/plugin/shaders/shape.frag (+47/-11)
modules/Ubuntu/Components/plugin/shaders/shape.vert (+2/-2)
modules/Ubuntu/Components/plugin/shaders/shapeoverlay.frag (+48/-11)
modules/Ubuntu/Components/plugin/shaders/shapeoverlay.vert (+2/-2)
modules/Ubuntu/Components/plugin/ucdefaulttheme.cpp (+8/-8)
modules/Ubuntu/Components/plugin/ucdefaulttheme.h (+6/-6)
modules/Ubuntu/Components/plugin/ucdeprecatedtheme.cpp (+135/-0)
modules/Ubuntu/Components/plugin/ucdeprecatedtheme.h (+56/-0)
modules/Ubuntu/Components/plugin/uclistitem.cpp (+60/-142)
modules/Ubuntu/Components/plugin/uclistitem.h (+2/-7)
modules/Ubuntu/Components/plugin/uclistitem_p.h (+11/-13)
modules/Ubuntu/Components/plugin/uclistitemstyle.cpp (+30/-5)
modules/Ubuntu/Components/plugin/uclistitemstyle.h (+6/-0)
modules/Ubuntu/Components/plugin/ucstyleditembase.cpp (+399/-6)
modules/Ubuntu/Components/plugin/ucstyleditembase.h (+14/-2)
modules/Ubuntu/Components/plugin/ucstyleditembase_p.h (+41/-1)
modules/Ubuntu/Components/plugin/uctheme.cpp (+471/-135)
modules/Ubuntu/Components/plugin/uctheme.h (+92/-20)
modules/Ubuntu/Components/plugin/ucubuntushape.cpp (+309/-301)
modules/Ubuntu/Components/plugin/ucubuntushape.h (+37/-25)
modules/Ubuntu/Components/plugin/ucubuntushapeoverlay.cpp (+85/-176)
modules/Ubuntu/Components/plugin/ucubuntushapeoverlay.h (+2/-2)
modules/Ubuntu/Components/plugin/ucubuntushapetexture.h (+268/-6519)
modules/Ubuntu/Components/qmldir (+5/-4)
modules/Ubuntu/Components/tools/3rd_party/edtaa3func.c (+570/-0)
modules/Ubuntu/Components/tools/createshapeimage.cpp (+231/-0)
modules/Ubuntu/Components/tools/shape.svg (+77/-0)
modules/Ubuntu/Components/tools/tools.pro (+5/-0)
modules/Ubuntu/Test/UbuntuTestCase.qml (+20/-2)
modules/Ubuntu/Test/plugin/uctestcase.h (+0/-1)
push_to_phone.sh (+0/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_common.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_flickable.py (+18/-10)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_header.py (+5/-2)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_mainview.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/_textfield.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/_custom_proxy_objects/popups.py (+0/-3)
tests/autopilot/ubuntuuitoolkit/base.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/fixture_setup.py (+10/-10)
tests/autopilot/ubuntuuitoolkit/tests/__init__.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/components/test_header.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/components/test_popover.py (+1/-4)
tests/autopilot/ubuntuuitoolkit/tests/components/test_textinput.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/components/test_units.py (+61/-0)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_checkbox.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_common.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_date_picker.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_dialog.py (+1/-4)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_flickable.py (+46/-6)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_header.py (+4/-4)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_listitem.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_listitems.py (+3/-6)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_main_view.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_optionselector.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_popups.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_pull_to_refresh.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_qquicklistview.py (+4/-7)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_tabs.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_textarea.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_textfield.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/custom_proxy_objects/test_toolbar.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/tests/gallery/__init__.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/gallery/test_buttons.py (+1/-1)
tests/autopilot/ubuntuuitoolkit/tests/gallery/test_optionselector.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/gallery/test_scrollbar.py (+2/-2)
tests/autopilot/ubuntuuitoolkit/tests/gallery/test_textinput.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/gallery/test_toggles.py (+3/-3)
tests/autopilot/ubuntuuitoolkit/tests/test_fixture_setup.py (+4/-9)
tests/autopilot/ubuntuuitoolkit/tests/test_launcher.py (+1/-7)
tests/autopilot/ubuntuuitoolkit/tests/test_ubuntu_scenarios.py (+2/-5)
tests/autopilot/ubuntuuitoolkit/units.py (+38/-0)
tests/license/checklicense.sh (+16/-21)
tests/resources/header/actions.qml (+0/-47)
tests/resources/header/backButton.qml (+0/-59)
tests/resources/header/lockedToolbar.deprecated.qml (+0/-52)
tests/resources/header/sections.qml (+0/-41)
tests/resources/listitems/ListItemDragging.qml (+1/-1)
tests/resources/navigation/simpleTabs.qml (+0/-60)
tests/resources/subtheming/Simple.qml (+87/-0)
tests/resources/ubuntushape/UbuntuShapeOverlayTest.qml (+44/-37)
tests/resources/ubuntushape/UbuntuShapeTest.qml (+14/-8)
tests/tests.pro (+1/-4)
tests/uitk_test_plan.sh (+3/-1)
tests/unit/tst_components/tst_styleditem13.qml (+35/-0)
tests/unit/tst_performance/PaletteConfigurationAllColors.qml (+58/-0)
tests/unit/tst_performance/PaletteConfigurationOneColor.qml (+33/-0)
tests/unit/tst_performance/StyledItemNewTheming.qml (+72/-0)
tests/unit/tst_performance/StyledItemOldTheming.qml (+72/-0)
tests/unit/tst_performance/Styling.qml (+76/-0)
tests/unit/tst_performance/tst_performance.cpp (+39/-4)
tests/unit/tst_performance/tst_performance.pro (+6/-1)
tests/unit_x11/tst_components/tst_app_theming.qml (+54/-0)
tests/unit_x11/tst_components/tst_components.pro (+2/-2)
tests/unit_x11/tst_components/tst_header_back_action.qml (+64/-21)
tests/unit_x11/tst_components/tst_header_contents_width.qml (+5/-10)
tests/unit_x11/tst_components/tst_header_sections.qml (+65/-56)
tests/unit_x11/tst_components/tst_header_visible.qml (+288/-0)
tests/unit_x11/tst_components/tst_listitem.qml (+3/-9)
tests/unit_x11/tst_components/tst_page11.qml (+1/-1)
tests/unit_x11/tst_components/tst_page13.qml (+126/-0)
tests/unit_x11/tst_components/tst_pagestack.new_header.qml (+32/-40)
tests/unit_x11/tst_components/tst_theming.qml (+5/-7)
tests/unit_x11/tst_deprecated_theme_engine/Parent.qml (+14/-4)
tests/unit_x11/tst_deprecated_theme_engine/SimpleItem.qml (+20/-0)
tests/unit_x11/tst_deprecated_theme_engine/themes/CustomTheme/TestStyle.qml (+0/-1)
tests/unit_x11/tst_deprecated_theme_engine/themes/TestModule/TestTheme/TestStyle.qml (+0/-1)
tests/unit_x11/tst_deprecated_theme_engine/tst_deprecated_theme_engine.cpp (+114/-113)
tests/unit_x11/tst_deprecated_theme_engine/tst_deprecated_theme_engine.pro (+9/-2)
tests/unit_x11/tst_subtheming/ChangeDefaultPaletteInChildren.qml (+38/-0)
tests/unit_x11/tst_subtheming/ChangePaletteValueWhenParentChanges.qml (+34/-0)
tests/unit_x11/tst_subtheming/DifferentThemes.qml (+46/-0)
tests/unit_x11/tst_subtheming/DynamicAssignment.qml (+38/-0)
tests/unit_x11/tst_subtheming/DynamicPalette.qml (+47/-0)
tests/unit_x11/tst_subtheming/InvalidPalette.qml (+23/-0)
tests/unit_x11/tst_subtheming/MultiplePaletteInstances.qml (+38/-0)
tests/unit_x11/tst_subtheming/ParentChanges.qml (+37/-0)
tests/unit_x11/tst_subtheming/SameNamedPaletteSettings.qml (+39/-0)
tests/unit_x11/tst_subtheming/SimpleItem.qml (+30/-0)
tests/unit_x11/tst_subtheming/TestMain.qml (+39/-0)
tests/unit_x11/tst_subtheming/TestModule/TestTheme/TestStyle.qml (+20/-0)
tests/unit_x11/tst_subtheming/TestStyleChange.qml (+69/-0)
tests/unit_x11/tst_subtheming/themes/CustomTheme/Palette.qml (+29/-0)
tests/unit_x11/tst_subtheming/themes/CustomTheme/TestStyle.qml (+22/-0)
tests/unit_x11/tst_subtheming/themes/CustomTheme/parent_theme (+1/-0)
tests/unit_x11/tst_subtheming/themes/TestModule/TestTheme/TestStyle.qml (+22/-0)
tests/unit_x11/tst_subtheming/themes/TestModule/TestTheme/parent_theme (+1/-0)
tests/unit_x11/tst_subtheming/themes/TestModule/TestTheme/qmldir (+2/-0)
tests/unit_x11/tst_subtheming/tst_subtheming.cpp (+576/-0)
tests/unit_x11/tst_subtheming/tst_subtheming.pro (+26/-0)
tests/unit_x11/tst_theme_engine/TestApp.qml (+0/-29)
tests/unit_x11/unit_x11.pro (+3/-2)
To merge this branch: bzr merge lp:~bzoltan/ubuntu-ui-toolkit/landing_2015-04-17
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Needs Fixing
Ubuntu SDK team Pending
Review via email: mp+256647@code.launchpad.net

Commit message

Landing branch 2015-04-17

Description of the change

Landing branch 2015-04-17

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
1483. By Zoltan Balogh

Pull from the staging #1485

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file '.bzrignore'
2--- .bzrignore 2015-02-27 13:47:29 +0000
3+++ .bzrignore 2015-04-17 15:45:47 +0000
4@@ -1,8 +1,12 @@
5-Makefile
6-modules/Makefile.ubuntu-ui-toolkit
7-modules/Ubuntu/Components/Makefile.ubuntu-ui-toolkit
8-modules/Ubuntu/Components/plugin/Makefile.ubuntu-ui-toolkit
9+Makefile*
10+modules/Makefile*
11+modules/Ubuntu/Components/Makefile*
12+modules/Ubuntu/Components/plugin/Makefile*
13 modules/Ubuntu/Components/plugin/qrc_plugin.cpp
14+modules/Ubuntu/Components/Themes/Makefile*
15+modules/Ubuntu/Components/Layouts/Makefile*
16+modules/Ubuntu/Components/PerformanceMetrics/Makefile*
17+modules/Ubuntu/Test/Makefile*
18 documentation/html/*
19 *.moc
20 moc_*.cpp
21
22=== modified file 'components.api'
23--- components.api 2015-03-10 13:58:52 +0000
24+++ components.api 2015-04-17 15:45:47 +0000
25@@ -246,7 +246,12 @@
26 property Flickable flickable
27 property list<Action> actions
28 Page 1.1
29-Page10
30+Toolkit10.Page
31+ readonly property PageHeadConfiguration head
32+Page 1.3
33+PageTreeNode
34+ property string title
35+ property Flickable flickable
36 readonly property PageHeadConfiguration head
37 PageHeadConfiguration 1.1
38 Object
39@@ -256,6 +261,10 @@
40 property string preset
41 readonly property PageHeadSections sections
42 property color foregroundColor
43+PageHeadConfiguration 1.3
44+Toolkit12.PageHeadConfiguration
45+ property bool locked
46+ property bool visible
47 PageHeadSections 1.1
48 QtObject
49 property bool enabled
50@@ -420,13 +429,13 @@
51 property bool refreshing
52 signal refresh()
53 Scrollbar 0.1 1.0
54-StyledItem
55+Toolkit.StyledItem
56 property Flickable flickableItem
57 property int align
58 property bool __interactive
59 property internal __private
60 Slider 0.1 1.0
61-StyledItem
62+Toolkit.StyledItem
63 property real minimumValue
64 property real maximumValue
65 property real value
66@@ -435,10 +444,6 @@
67 signal touched(bool onThumb)
68 function formatValue(v)
69 property internal __internals
70-StyledItem 0.1 1.0 1.1
71-StyledItemBase
72- property Component style
73- readonly property Item __styleInstance
74 ComboButtonStyle 1.1
75 Item
76 property real dropDownWidth
77@@ -475,7 +480,7 @@
78 readonly property int index
79 property internal __protected
80 TabBar 0.1 1.0
81-StyledItem
82+Toolkit.StyledItem
83 property Item tabsItem
84 property var model
85 readonly property bool pressed
86@@ -494,7 +499,7 @@
87 signal modelChanged()
88 property var __model
89 TextArea 0.1 1.0
90-StyledItem
91+Ubuntu.StyledItem
92 property bool highlighted
93 property string placeholderText
94 readonly property string displayText
95@@ -617,11 +622,11 @@
96 function undo()
97 function remove(start, end)
98 function getText(start, end)
99-Palette 0.1
100+Palette 0.1 1.0
101 QtObject
102 property PaletteValues normal
103 property PaletteValues selected
104-PaletteValues 0.1
105+PaletteValues 0.1 1.0
106 QtObject
107 property color background
108 property color backgroundText
109@@ -692,6 +697,7 @@
110 function tryCompareFunction(func, expectedResult, timeout)
111 function typeString(string)
112 function warningFormat(line, column, message)
113+ function waitForHeaderAnimation(mainView)
114 plugins.qmltypes
115 name: "FilterBehavior"
116 prototype: "QObject"
117@@ -943,8 +949,6 @@
118 Property { name: "action"; type: "UCAction"; isPointer: true }
119 Property { name: "listItemData"; type: "QObject"; isList: true; isReadonly: true }
120 Property { name: "listItemChildren"; type: "QQuickItem"; isList: true; isReadonly: true }
121- Property { name: "style"; type: "QQmlComponent"; isPointer: true }
122- Property { name: "__styleInstance"; type: "QQuickItem"; isReadonly: true; isPointer: true }
123 Signal { name: "clicked" }
124 Signal { name: "pressAndHold" }
125 Signal { name: "contentMovementStarted" }
126@@ -961,11 +965,13 @@
127 Property { name: "colorTo"; type: "QColor" }
128 name: "UCListItemStyle"
129 prototype: "QQuickItem"
130- exports: ["Ubuntu.Components.Styles/ListItemStyle 1.2"]
131+ exports: [
132 Property { name: "snapAnimation"; type: "QQuickAbstractAnimation"; isPointer: true }
133 Property { name: "dropAnimation"; type: "QQuickPropertyAnimation"; isPointer: true }
134 Property { name: "animatePanels"; type: "bool"; isReadonly: true }
135 Property { name: "dragPanel"; type: "QQuickItem"; isPointer: true }
136+ Property { name: "listItemIndex"; revision: 1; type: "int"; isReadonly: true }
137+ Signal { name: "listItemIndexChanged"; revision: 1 }
138 Method {
139 name: "swipeEvent"
140 Parameter { name: "event"; type: "UCSwipeEvent"; isPointer: true }
141@@ -1045,6 +1051,12 @@
142 prototype: "QQuickItem"
143 exports: [
144 Property { name: "activeFocusOnPress"; revision: 1; type: "bool" }
145+ Property { name: "style"; type: "QQmlComponent"; isPointer: true }
146+ Property { name: "__styleInstance"; type: "QQuickItem"; isReadonly: true; isPointer: true }
147+ Property { name: "theme"; revision: 2; type: "UCTheme"; isPointer: true }
148+ Signal { name: "styleInstanceChanged" }
149+ Signal { name: "activeFocusOnPressChanged"; revision: 1 }
150+ Signal { name: "themeChanged"; revision: 2 }
151 Method {
152 name: "requestFocus"
153 Parameter { name: "reason"; type: "Qt::FocusReason" }
154@@ -1057,6 +1069,16 @@
155 Property { name: "from"; type: "QPointF"; isReadonly: true }
156 Property { name: "content"; type: "QPointF" }
157 Property { name: "status"; type: "Status"; isReadonly: true }
158+ name: "UCTheme"
159+ prototype: "QObject"
160+ exports: ["ThemeSettings 1.3"]
161+ Property { name: "parentTheme"; type: "UCTheme"; isReadonly: true; isPointer: true }
162+ Property { name: "name"; type: "string" }
163+ Property { name: "palette"; type: "QObject"; isPointer: true }
164+ Method {
165+ name: "createStyleComponent"
166+ Parameter { name: "styleName"; type: "string" }
167+ Parameter { name: "parent"; type: "QObject"; isPointer: true }
168 name: "UCUbuntuAnimation"
169 prototype: "QObject"
170 exports: ["UbuntuAnimation 0.1", "UbuntuAnimation 1.0"]
171@@ -1070,13 +1092,14 @@
172 name: "UCUbuntuShape"
173 prototype: "QQuickItem"
174 exports: [
175+ name: "Aspect"
176 name: "BackgroundMode"
177 name: "HAlignment"
178 name: "VAlignment"
179 name: "FillMode"
180 name: "WrapMode"
181 Property { name: "radius"; type: "string" }
182- Property { name: "borderSource"; type: "string" }
183+ Property { name: "aspect"; revision: 1; type: "Aspect" }
184 Property { name: "source"; revision: 1; type: "QVariant" }
185 Property { name: "sourceOpacity"; revision: 1; type: "double" }
186 Property { name: "sourceFillMode"; revision: 1; type: "FillMode" }
187@@ -1089,12 +1112,14 @@
188 Property { name: "backgroundColor"; revision: 1; type: "QColor" }
189 Property { name: "secondaryBackgroundColor"; revision: 1; type: "QColor" }
190 Property { name: "backgroundMode"; revision: 1; type: "BackgroundMode" }
191+ Property { name: "borderSource"; type: "string" }
192 Property { name: "color"; type: "QColor" }
193 Property { name: "gradientColor"; type: "QColor" }
194 Property { name: "image"; type: "QVariant" }
195 Property { name: "stretched"; type: "bool" }
196 Property { name: "horizontalAlignment"; type: "HAlignment" }
197 Property { name: "verticalAlignment"; type: "VAlignment" }
198+ Signal { name: "aspectChanged"; revision: 1 }
199 Signal { name: "sourceChanged"; revision: 1 }
200 Signal { name: "sourceOpacityChanged"; revision: 1 }
201 Signal { name: "sourceFillModeChanged"; revision: 1 }
202
203=== modified file 'debian/changelog'
204--- debian/changelog 2015-03-27 12:35:56 +0000
205+++ debian/changelog 2015-04-17 15:45:47 +0000
206@@ -1,3 +1,59 @@
207+ubuntu-ui-toolkit (1.2.1485+15.04.20150327-0ubuntu1) UNRELEASED; urgency=medium
208+
209+ [ Christian Dywan]
210+ * Use activeFocus rather than focus to determine that Text* has focus.
211+ Fixes LP: #1378231
212+
213+ [ Leo Arias ]
214+ * Added a grids unit helper for autopilot tests.
215+ * Make it possible to overwrite the bottom margin for the flickable autopilot
216+ helper. Fixes LP: #1401517.
217+ * Removed python2 support from autopilot tests and helpers. Fixes LP: #1429163
218+
219+ [ Loïc Molinari ]
220+ * Bumped matrix precision in vertex shaders. mediump, which should actually be
221+ enough, was interpreted as lowp on arale (PowerVR Rogue G6200).
222+ * Fixed build.
223+ * Synchronized license checking script with PBuilder Jenkins.
224+ Fixes LP: #1441580.
225+ * [UbuntuShape] Added support for resolution independent rendering.
226+ Fixes LP: #1427253.
227+ * Updated unknown Makefiles in .bzrignore.
228+
229+ [ Sebastien Bacher ]
230+ * Change cursor when over the documentation urls to show they can be clicked.
231+
232+ [ Timo Jyrinki ]
233+ * Clean up cruft from build dependencies. Fixes LP: #1441499.
234+ * uitk_test_plan.sh: Remove terminal app before trying to run the tests.
235+ Fixes LP: #1434537.
236+
237+ [ Tim Peeters ]
238+ * Add UbuntuTestCase.waitForHeaderAnimation().
239+ * Add visible and locked properties to Page.head.
240+ Fixes LP: #1402054, LP: #1424592.
241+ * Create Page 1.3.
242+ * Merge header tests in resources with header unit tests.
243+ * Move duplicate code for the overflows that was in PageHeadStyle twice
244+ (for Tabs and Actions overflows) into OverflowPanel.
245+ * New header visuals.
246+ * Re-introduce the panel color properties to Ambience PageHeadStyle.
247+
248+ [ Zsombor Egri ]
249+ * Applying sub-theming on toolkit.
250+ * Introducing StyledItem.theme and ThemeSettings.parentTheme properties
251+ into v1.3.
252+ * Introducing ThemeSettings component, exported to UI Toolkit version 1.3.
253+ * Make ThemeSettings.palette writable to configure individual colors as well
254+ as Palette as a whole.
255+ * Separating Theme context property from theme engine, giving the possibility
256+ to use the theming engine by multiple instances. Preparations for deprecation.
257+ Theming unit tests fixed. Fixes LP: #1248982.
258+ * Theming tutorial
259+ * Remove extra StyledItem.qml layer for styled items, keep only UCStyledItemBase.
260+
261+ -- Zoltán Balogh <zoltan@bakter.hu> Fri, 17 Apr 2015 14:06:27 +0300
262+
263 ubuntu-ui-toolkit (1.2.1458+15.04.20150327-0ubuntu1) vivid; urgency=medium
264
265 [ By Tim Peeters ]
266
267=== modified file 'debian/control'
268--- debian/control 2015-03-24 10:24:18 +0000
269+++ debian/control 2015-04-17 15:45:47 +0000
270@@ -7,13 +7,10 @@
271 libgles2-mesa-dev,
272 libglib2.0-dev,
273 python3:any,
274- python:any,
275 qml-module-qtgraphicaleffects | libqt5qml-graphicaleffects,
276- qt5-default,
277 qtbase5-dev,
278 qtbase5-private-dev,
279 qttools5-dev-tools,
280- qtbase5-dev-tools,
281 libqt5sql5-sqlite,
282 qtdeclarative5-dev-tools,
283 qtdeclarative5-private-dev,
284@@ -34,7 +31,6 @@
285 qtmultimedia5-doc-html,
286 unity-action-doc,
287 devscripts,
288- libqt5organizer5,
289 qtpim5-dev,
290 language-pack-en-base,
291 libdbus-1-dev,
292@@ -47,7 +43,6 @@
293 locales,
294 suru-icon-theme,
295 uuid-runtime,
296- python-autopilot (>= 1.4),
297 python3-sphinx,
298 Standards-Version: 3.9.4
299 Homepage: https://launchpad.net/ubuntu-ui-toolkit
300@@ -144,13 +139,6 @@
301 dpkg-dev,
302 libqt5test5,
303 libqt5widgets5,
304- python-autopilot (>= 1.4),
305- python-fixtures,
306- python-gi,
307- python-mock,
308- python-testscenarios,
309- python-testtools,
310- python-autopilot-trace,
311 python3-fixtures,
312 python3-gi,
313 python3-testscenarios,
314
315=== modified file 'debian/copyright'
316--- debian/copyright 2013-07-30 09:12:35 +0000
317+++ debian/copyright 2015-04-17 15:45:47 +0000
318@@ -334,3 +334,26 @@
319 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
320 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
321 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
322+
323+Files: modules/Ubuntu/Components/tools/3rd_party/edtaa3func.c
324+Copyright: 2009-2012, Stefan Gustavson <stefan.gustavson@gmail.com>
325+License: MIT
326+
327+License: MIT
328+ Permission is hereby granted, free of charge, to any person obtaining a copy
329+ of this software and associated documentation files (the "Software"), to deal
330+ in the Software without restriction, including without limitation the rights
331+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
332+ copies of the Software, and to permit persons to whom the Software is
333+ furnished to do so, subject to the following conditions:
334+ .
335+ The above copyright notice and this permission notice shall be included in
336+ all copies or substantial portions of the Software.
337+ .
338+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
339+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
340+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
341+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
342+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
343+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
344+ THE SOFTWARE.
345
346=== modified file 'debian/rules'
347--- debian/rules 2015-01-23 18:11:22 +0000
348+++ debian/rules 2015-04-17 15:45:47 +0000
349@@ -4,6 +4,7 @@
350 # export DH_VERBOSE=1
351 export DPKG_GENSYMBOLS_CHECK_LEVEL=4
352 export QMAKEFEATURES=$(CURDIR)/features
353+export QT_SELECT := qt5
354 DEB_HOST_MULTI_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_MULTIARCH)
355 DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
356
357
358=== modified file 'debian/ubuntu-ui-toolkit-autopilot.install'
359--- debian/ubuntu-ui-toolkit-autopilot.install 2014-06-17 07:12:49 +0000
360+++ debian/ubuntu-ui-toolkit-autopilot.install 2015-04-17 15:45:47 +0000
361@@ -1,3 +1,2 @@
362 usr/lib/python3
363 usr/lib/*/ubuntu-ui-toolkit/launcher
364-usr/lib/python2.7
365
366=== added file 'documentation/images/surudark-theme.png'
367Binary files documentation/images/surudark-theme.png 1970-01-01 00:00:00 +0000 and documentation/images/surudark-theme.png 2015-04-17 15:45:47 +0000 differ
368=== modified file 'documentation/overview.qdoc'
369--- documentation/overview.qdoc 2015-03-04 09:09:39 +0000
370+++ documentation/overview.qdoc 2015-04-17 15:45:47 +0000
371@@ -21,6 +21,7 @@
372 \part General Topics
373 \list
374 \li \l{ubuntu-whatsnew.html}{What's new in version 1.2?}
375+ \li \l{ubuntu-theming.html}{Styling} components
376 \li \l{ubuntu-layouts.html}{Layouts} describes a flexible layouting engine
377 to ease the development of responsive user interfaces.
378 \li \l {Resolution Independence} describes the facilities that should be
379@@ -84,6 +85,13 @@
380 \endcode
381 \annotatedlist theming
382
383+ \part Theme module
384+ Available through:
385+ \code
386+ import Ubuntu.Components.Themes 1.0
387+ \endcode
388+ \annotatedlist theme-module
389+
390 \part Style API
391 The Style API defines the interface components use to style the visuals.
392 Themes must make sure that these interfaces are all implemented.
393
394=== added file 'documentation/ubuntu-theming.qdoc'
395--- documentation/ubuntu-theming.qdoc 1970-01-01 00:00:00 +0000
396+++ documentation/ubuntu-theming.qdoc 2015-04-17 15:45:47 +0000
397@@ -0,0 +1,438 @@
398+/*
399+ * Copyright 2015 Canonical Ltd.
400+ *
401+ * This program is free software; you can redistribute it and/or modify
402+ * it under the terms of the GNU Lesser General Public License as published by
403+ * the Free Software Foundation; version 3.
404+ *
405+ * This program is distributed in the hope that it will be useful,
406+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
407+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
408+ * GNU Lesser General Public License for more details.
409+ *
410+ * You should have received a copy of the GNU Lesser General Public License
411+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
412+ */
413+
414+/*!
415+ * \page ubuntu-theming.html
416+ * \title Styling - Introduction
417+ * \nextpage Component styles, Style API
418+ *
419+ * The style defines the visuals, the implicit size of the component and may provide
420+ * additional logic for a given component. Some components have fixed style API the
421+ * component relies on, and yet some others do not have any restriction on hwat the
422+ * style contains or does. Components relying on a well defined API provide these
423+ * interfaces through Ubuntu.Components.Styles module, and styles must implement these
424+ * interfaces.
425+ *
426+ * The implicit size of a component is driven by the style as well, but it is not
427+ * mandatory for a style to provide those values, and components can override these
428+ * values at any time. However each style component is anchor filled to the styled
429+ * component and positioned to be under child components declared within the component
430+ * itself.
431+ *
432+ * Styles can be declared as Components (like delegates), in a separate document
433+ * loaded dynamically using a Loader or Qt.createComponent(), or can be grouped
434+ * in themes. When declared in themes, with some exceptions, each component's style
435+ * document name is compound of the component name having the \e Style word as postfix,
436+ * followed by the typical QML file name extension. In this way the Button component's
437+ * style is ButtonStyle. In addition to styles, themes can also provide custom palette
438+ * values. There are two themes in Ubuntu, Ambiance and SuruDark themes, Ambiance
439+ * being the default theme. Both themes are declared in separate modules, in \c
440+ * Ubuntu.Components.Themes.Ambiance ans well as \c Ubuntu.Components.Themes.SuruDark.
441+ * Application should define the theme name using this dotted name format.
442+ *
443+ * Applications can decide which theme they want to use or they can provide their
444+ * own themes. Also, applications can use multiple themes or set custom palette values.
445+ *
446+ * \qml
447+ * import QtQuick 2.4
448+ * import Ubuntu.Components 1.3
449+ *
450+ * MainView {
451+ * width: units,gu(40)
452+ * height: units.gu(71)
453+ *
454+ * theme.name: "Ubuntu.Components.Themes.SuruDark"
455+ * }
456+ * \endqml
457+ */
458+
459+/*!
460+ * \page ubuntu-theming-styles.html
461+ * \title Component styles, Style API
462+ * \nextpage Themes, theme types, theme structure
463+ *
464+ * \section2 Naming conventions
465+ * With few exception, each toolkit component is having StyledItem as its base
466+ * component. The component is aimed to be the base component for all styled
467+ * elements in the toolkit. Modules providing additional components to UI Toolkit
468+ * can also use this component as base, especially if they want to provide styling
469+ * capabilities.
470+ *
471+ * As mentioned, each styled component is having a style pair in a theme which is
472+ * implemented in a document named using the component name adding the \e Style word.
473+ * The \l {Button}'s style is implemented by \c ButtonStyle.qml document in the theme, and
474+ * \l Button is loading this style from the theme:
475+ * \qml
476+ * import QtQuick 2.4
477+ * import Ubuntu.Components 1.3
478+ *
479+ * AbstractButton {
480+ * id: button
481+ * // [...]
482+ * style: theme.createStyleComponent("ButtonStyle.qml", button)
483+ * }
484+ * \endqml
485+ * Developers can override the style in two ways, depending on how they want to style
486+ * the component:
487+ * \list
488+ * \li 1. by overriding the style using an other style component from the theme, or
489+ * \li 2. by overriding the style with a custom style component.
490+ * \endlist
491+ * But let's see first how the styles are implemented.
492+ *
493+ * \section2 Creating styles
494+ * As mentioned before, styles are not restricted to only provide visuals to a component or
495+ * set of components, but can have also logic which drives the component functionality.
496+ * These kind of styles must implement the given component's style API, listed in
497+ * \c Ubuntu.Components.Styles module.
498+ *
499+ * A good example of such a style is the ListItemStyle. The ListItem drives the style
500+ * animation through the \l ListItemStyle::animatePanels property, value being false when
501+ * the style is loaded during component creation, i.e. when the component requires some
502+ * visuals to be present at creation time. Also, ListItem informs the style when to
503+ * execute leading or trailing panel \l {ListItemStyle::rebound}{rebound}s and provides
504+ * the style the ability to overrule the \l {ListItemStyle::swipeEvent}{swipe} coordinates
505+ * calculated by the ListItem. On the other hand, the style must inform the component
506+ * about the position of the \l {ListItemStyle::dragPanel}{drag panel} so dragging
507+ * (reordering of list items in a ListView) hot spot can be detected. A style implementation
508+ * must use the API provided by ListItemStyle, otherwise ListItem will fail to function
509+ * properly.
510+ *
511+ * Other styles are requested to provide additional \e content elements, which are then
512+ * positioned by the styled component separately from the main visuals given by the style.
513+ * A typical example of such a style API is the PullToRefresh component's style:
514+ * \snippet Styles/PullToRefreshStyle.qml 0
515+ * The default style implementation can be found under Ubuntu.Components.Themes.Ambiance
516+ * theme \l {http://bazaar.launchpad.net/~ubuntu-sdk-team/ubuntu-ui-toolkit/trunk/view/head:/modules/Ubuntu/Components/Themes/Ambiance/PullToRefreshStyle.qml}
517+ * {PullToRefreshStyle.qml}.
518+ *
519+ * Beside these, component styles may provide default values for colors, fonts, widths,
520+ * margins, thicknesses.
521+ *
522+ * Each style component has a \c styledItem context property defined by the StyledItem,
523+ * which points to the StyledItem instance that uses the style. Style implementations can
524+ * access the actual styled item through this property.
525+ *
526+ * \section2 Overriding the default component style
527+ *
528+ * \section3 Override with a different style from the theme
529+ * Returning back to the ways to override a component's style, overriding by using a different
530+ * style from the theme can simply be done by calling the theme's \l{Theme::createStyleComponent}
531+ * {createStyleComponent()} function with the alternative style document name as follows:
532+ * \qml
533+ * Button {
534+ * id: button
535+ * style: theme.createStyleComponent("SquaryButton.qml", button)
536+ * }
537+ * \endqml
538+ * \note This assumes that the \c SquaryButton.qml document is present in the theme.
539+ * This type of component styling makes sure the style will always have theme specific implementation
540+ * or coloring, however it also requires the style document to be present in all the themes
541+ * used by the application.
542+ *
543+ * \section3 Override with a custom component
544+ * The other way is to override the style with a local component not present in any theme.
545+ * The style component can be in-source (Component) or declared in a separate document,
546+ * loaded dynamically with Loader or Qt.createComponent(). This kind of override will make
547+ * sure the component will use the custom style no matter of the theme used. These styles
548+ * however can still use the theme palette to be in sync with the theme coloring.
549+ * \qml
550+ * Button {
551+ * id: button
552+ * style: Rectangle {
553+ * implicitWidth: units.gu(12)
554+ * implicitHeight: units.gu(5)
555+ * color: styledItem.color
556+ * border {
557+ * width: units.dp(1)
558+ * color: styledItem.strokeColor
559+ * }
560+ * Label {
561+ * text: styledItem.text
562+ * font: styledItem.font
563+ * }
564+ * }
565+ * }
566+ * \endqml
567+ */
568+
569+/*!
570+ * \page ubuntu-theming-themes.html
571+ * \title Themes, theme types, theme structure
572+ * \nextpage Sub-theming
573+ *
574+ * A theme is a collection of style implementations. The style component names are
575+ * typically built using the component name and the Style word, exceptions being
576+ * documented per component.
577+ *
578+ * In addition to the styles the theme can provide palette values used by the style
579+ * and components. The palette values are defined in \c Palette.qml file, which must
580+ * either be derived from \l Palette component or from a parent theme's Palette.
581+ *
582+ * There are two types of themes, shared themes and application themes. These themes
583+ * do not differ in structure but in the way they are exposed. Shared themes are
584+ * located either under \b QML2_IMPORT_PATH or \b XDG_DATA_DIR. Application themes
585+ * are located under the application's private folder, therefore they are typically
586+ * serving the application styling needs, and cannot be shared. Shared themes are also
587+ * presented as QML extension modules, giving the possibility for application themes
588+ * to extend them.
589+ *
590+ * \note Yet there is no possibility to install shared themes into the system through
591+ * app store, only by providing them as part of the system image.
592+ *
593+ * The system provides two shared themes, \b Ambiance and \b SuruDark, the latest derived
594+ * from Ambiance theme. Both themes can be used as base theme in application themes,
595+ * by importing the modules defining them. If you decide to create a shared theme
596+ * that can be used also as base for custom or application themes, it is recommended
597+ * to do the same approach as the system themes do.
598+ *
599+ * \section2 Theme structure
600+ * \image surudark-theme.png
601+ * The theme structure is similar to a QML extension module structure, and this applies
602+ * to both shared and application themes. Contains component style documents, palette
603+ * description document, \c qmldir file and a special file called \c parent_theme. All
604+ * these files are optional in a theme depending on context.
605+ *
606+ * \c parent_theme is a special file which defines the theme the current one is derifed from.
607+ * The parent theme must be a shared theme and its name must be specified in dotted format.
608+ * For example SuruDark theme is located under \c{$QML2_IMPORT_PATH/Ubuntu/Components/Themes/SuruDark}
609+ * folder. This means that the theme name is identified by the \b Ubuntu.Components.Themes.SuruDark
610+ * dotted format.
611+ *
612+ * In addition to the files mentioned, themes can provide components supporting the styling
613+ * (i.e. components providing common visuals in the style implementations). Style implementations
614+ * can also provide additional APIs alongside the standard style API. These additional APIs are
615+ * typically there to configure the style itself, or to turn on/off features provided by styles
616+ * in derived themes.
617+ *
618+ * \section3 Standalone theme
619+ * A standalone theme is a theme which defines all style documents and theme palette,
620+ * and it is not derived from any theme. The only standalone theme UI Toolkit provides is
621+ * the Ambiance theme. Both shared and application themes can be standalone themes, however
622+ * Applications should make sure they implement all the styles used by the toolkit components
623+ * used in the application. \c qmldir file presence is mandatory only if the theme is
624+ * shared.
625+ *
626+ * \section3 Derived themes
627+ * As the name suggests derived themes are themes which use other themes (standalone or derived ones)
628+ * as base theme. These themes must have the \c parent_theme file to be present and to contain the
629+ * name of the theme they are derived from. These themes do not have to provide palette configuration
630+ * as long as they use the derived theme's palette values.
631+ *
632+ * Derived themes should only list those style components which overrule the derived style or
633+ * extend the derived style. The only requirement is to use the same document name as the paren theme
634+ * is having.
635+ *
636+ * Let's take SuruDark theme as en example. The theme is derived from Ambiance theme, and only
637+ * extends few style components. When theming engine loads the style components, it looks
638+ * after the styles starting from the current theme. If the style is not found there, it
639+ * tries to look after the style in the parent themes until it finds one.
640+ *
641+ * The extended (or even overridden) style component documents must follow the naming
642+ * convention, and must have the names implied by the components styled.
643+ *
644+ * SuruDark theme overrides the Ambiance theme's MainViewStyle, therefore declares the
645+ * MainViewStyle.qml document, with the following content:
646+ * \snippet Themes/SuruDark/MainViewStyle.qml 0
647+ *
648+ * The style imports the Ambiance theme module, and extends the Ambiance MainViewStyle
649+ * component. The same is done in the other style components. However, Palette defines
650+ * own values, and does not resuse Ambiance palette values.
651+ * \snippet Themes/SuruDark/Palette.qml 0
652+ *
653+ * The same is done with TabBarStyle and OptionSelectorStyle components.
654+ *
655+ * \note If a theme derived from SuruDark wants to override style components not present
656+ * in SuruDark, they must import the SuruDark's parent theme in the style component.
657+ * As example, if FancyTheme would want to override the SwitchStyle, it would need to
658+ * import Ambiance module in the component as SuruDark doesn't have that style component
659+ * defined.
660+ * \qml
661+ * import QtQuick 2.4
662+ * import Ubuntu.Components 1.3
663+ * import Ubuntu.Components.Themes.Ambiance 1.2 as Ambiance
664+ * Ambiance.SwitchStyle {
665+ * // [...]
666+ * }
667+ * \endqml
668+ *
669+ * \section2 Application themes
670+ * Application themes can also be standalone or derived themes. Usually applications
671+ * need slight differences on certain component styles, colors. These can be configured
672+ * in multiple ways, depending on the needs of the application. Applications can decide
673+ * to have their own theme, and override the palette value in the theme, or to use the
674+ * system themes and override few color values from the theme palette.
675+ *
676+ * Let's take an example of an application which changes some palette values of SuruDark
677+ * theme.
678+ *
679+ * First, the application has to define the theme, preferably in a separate folder (e.g.
680+ * theme). The folder should contain a \c parent_theme file with the content
681+ * \code
682+ * Ubuntu.Components.Themes.SuruDark
683+ * \endcode
684+ * This will make sure theme engine will look after the style components that are not
685+ * defined by the application theme inside the parent theme. Remember, the parent themes
686+ * can have parent themes (in SuruDark case it is) in which case the style components
687+ * will be looked up in all these themes.
688+ *
689+ * As next, the application can define the palette.
690+ * \snippet customtheme/theme/Palette.qml 0
691+ * Note that the palette uses the SuruDark palette as base, and changes few colors from it.
692+ *
693+ * The application can use its own theme in the following way:
694+ * \snippet customtheme/main.qml 0
695+ */
696+
697+/*!
698+ * \page ubuntu-theming-subtheming.html
699+ * \title Sub-theming
700+ *
701+ * There can be situations when an application has a design which combines styles from different
702+ * themes, which would not be possible or would be hard to be combined in a theme. In these
703+ * situations developers can use different themes in the components and its child components.
704+ * This is called sub-theming, which was introduced in Ubuntu.Components v1.3.
705+ * The only thing the application has to do is to define a ThemeSettings instance for the
706+ * component which is desired to use a different theme.
707+ * \qml
708+ * import QtQuick 2.4
709+ * import Ubuntu.Componenst 1.3
710+ * MainView {
711+ * width: units.gu(40)
712+ * height: units.gu(71)
713+ *
714+ * applicationName: "subthemed"
715+ *
716+ * // make sure the main theme is Ambiance
717+ * theme.name: "Ubuntu.Components.Themes.Ambiance"
718+ *
719+ * Component {
720+ * id: dialogComponent
721+ * Dialog {
722+ * id: dialog
723+ * title: "Input dialog"
724+ * // the dialog and its children will use SuruDark
725+ * theme: ThemeSettings {
726+ * name: "Ubuntu.Components.Themes.SuruDark"
727+ * }
728+ * TextField {
729+ * placeholderText: "enter text"
730+ * }
731+ * Button {
732+ * text: "Close"
733+ * onClicked: PopupUtils.close(dialog)
734+ * }
735+ * }
736+ * }
737+ *
738+ * Button {
739+ * text: "Open dialog"
740+ * onClicked: PopupUtils.open(dialogComponent)
741+ * }
742+ * }
743+ * \endqml
744+ *
745+ * Another use-case is when a different palette set is needed in the application.
746+ * One way to achieve that is to define a custom theme for the application, however
747+ * that theme must be derived from one particular theme, so the application will be
748+ * nailed to one given theme. If we want to have the same palette values to be used
749+ * no matter of the component shape, we can override the palette values we want to
750+ * change, by setting the theme palette to a \l Palette instance where only the desired
751+ * palette values are changed. This can be combined with sub-theming, which will make
752+ * sure that the palette values are applied only on a certain component sub-tree.
753+ *
754+ * The following example makes sure the Dialog and is child components will use a given
755+ * palette value:
756+ * \qml
757+ * import QtQuick 2.4
758+ * import Ubuntu.Components 1.3
759+ * import Ubuntu.Components.Themes 1.0
760+ *
761+ * MainView {
762+ * width: units.gu(40)
763+ * height: units.gu(71)
764+ *
765+ * applicationName: "subthemed"
766+ *
767+ * Component {
768+ * id: dialogComponent
769+ * Dialog {
770+ * id: dialog
771+ * title: "Input dialog"
772+ * // make sure the dialog and its children will use the same
773+ * // theme as the rest of the application
774+ * theme: ThemeSettings {
775+ * name: parentTheme.name
776+ * palette: Palette {
777+ * id: config
778+ * normal {
779+ * foregroundText: UbuntuColors.blue
780+ * overlayText: "#BAFEDC"
781+ * }
782+ * selected {
783+ * fieldText: "brown"
784+ * foregroundText: Qt.rgba(0, 0, 1, 1)
785+ * overlayText: config.normal.overlayText
786+ * foreground: UbuntuColors.green
787+ * }
788+ * }
789+ * }
790+ * TextField {
791+ * placeholderText: "enter text"
792+ * }
793+ * Button {
794+ * text: "Close"
795+ * onClicked: PopupUtils.close(dialog)
796+ * }
797+ * }
798+ * }
799+ *
800+ * Column {
801+ * spacing: units.gu(1)
802+ * Button {
803+ * text: "Set Ambiance theme"
804+ * onClicked: theme.name = "Ubuntu.Components.Themes.Ambiance"
805+ * }
806+ * Button {
807+ * text: "Set SuruDark theme"
808+ * onClicked: theme.name = "Ubuntu.Components.Themes.SuruDark"
809+ * }
810+ * Button {
811+ * text: "Open dialog"
812+ * onClicked: PopupUtils.open(dialogComponent)
813+ * }
814+ * }
815+ * }
816+ * \endqml
817+ * \note Note the way the theme is changed! The first two buttons actually change the
818+ * name of the theme they inherit, which is the application's theme. This means that
819+ * the theme will actually be changed on the entire application, not only on the Button
820+ * itself.
821+ *
822+ * The Dialog uses the \l {ThemeSettings::parentTheme}{parentTheme} property to load
823+ * the same theme as its parent styled item is using, meaning that the Dialog will
824+ * also load the same theme as the application does, and will change the loaded palette
825+ * values with the ones defined in the \c config Palette instance, namely the \c
826+ * foregroundText and \c overlayText of \c normal, as well as \c fieldText, \c foregroundText,
827+ * \c overlayText and \c foreground on \c selected groups.
828+ *
829+ * \section1 That's it
830+ * By now you should have learned what the styling means, what are the themes, what
831+ * kind of themes toolkit has, how can you create shared or application themes, where should
832+ * you store them, how to extend styles, how to use multiple themes in an application
833+ * and how to set custom palette values runtime. If you have questions or need guidance,
834+ * you can contact us on \b{#ubuntu-app-devel} IRC channel on freenode.
835+ */
836
837=== modified file 'documentation/ubuntu-ui-toolkit-common.qdocconf'
838--- documentation/ubuntu-ui-toolkit-common.qdocconf 2015-03-03 13:47:48 +0000
839+++ documentation/ubuntu-ui-toolkit-common.qdocconf 2015-04-17 15:45:47 +0000
840@@ -11,7 +11,10 @@
841 sourcedirs += ../modules/Ubuntu/Test
842 headerdirs += ../modules/Ubuntu/Test/plugin
843 exampledirs += snippets
844-excludedirs = ../modules/Ubuntu/Components/Themes
845+exampledirs += ../examples
846+exampledirs += ../modules/Ubuntu/Components
847+excludedirs += ../modules/Ubuntu/Components/Themes/Ambiance
848+excludedirs += ../modules/Ubuntu/Components/Themes/SuruDark
849 imagedirs = images
850 sources.fileextensions = "*.qml *.qdoc *.cpp"
851 headers.fileextensions = "*.h"
852
853=== added file 'examples/customtheme/customtheme.pro'
854--- examples/customtheme/customtheme.pro 1970-01-01 00:00:00 +0000
855+++ examples/customtheme/customtheme.pro 2015-04-17 15:45:47 +0000
856@@ -0,0 +1,18 @@
857+TEMPLATE = aux
858+
859+filetypes = qml png svg js jpg qmlproject desktop
860+
861+OTHER_FILES = theme/parent_theme
862+
863+for(filetype, filetypes) {
864+ OTHER_FILES += *.$$filetype
865+ OTHER_FILES += theme/*.$$filetype
866+}
867+
868+desktop_files.path = /usr/share/applications
869+desktop_files.files = customtheme.desktop
870+
871+other_files.path = /usr/lib/ubuntu-ui-toolkit/examples/customtheme
872+other_files.files = $$OTHER_FILES
873+
874+INSTALLS += other_files desktop_files
875
876=== modified file 'examples/customtheme/main.qml'
877--- examples/customtheme/main.qml 2015-03-03 13:47:48 +0000
878+++ examples/customtheme/main.qml 2015-04-17 15:45:47 +0000
879@@ -1,5 +1,5 @@
880 /*
881- * Copyright 2014 Canonical Ltd.
882+ * Copyright 2015 Canonical Ltd.
883 *
884 * This program is free software; you can redistribute it and/or modify
885 * it under the terms of the GNU Lesser General Public License as published by
886@@ -13,32 +13,19 @@
887 * You should have received a copy of the GNU Lesser General Public License
888 * along with this program. If not, see <http://www.gnu.org/licenses/>.
889 */
890-
891-import QtQuick 2.0
892-import Ubuntu.Components 1.2
893-
894-/*!
895- \brief MainView with a Label and Button elements.
896-*/
897+//![0]
898+import QtQuick 2.4
899+import Ubuntu.Components 1.3
900
901 MainView {
902 id: mainView
903- // objectName for functional testing purposes (autopilot-qt5)
904 objectName: "mainView"
905-
906- // Note! applicationName needs to match the "name" field of the click manifest
907 applicationName: "customtheme"
908
909- /*
910- This property enables the application to change orientation
911- when the device is rotated. The default is false.
912- */
913- //automaticOrientation: true
914-
915 width: units.gu(100)
916 height: units.gu(75)
917
918- Component.onCompleted: Theme.name = "theme"
919+ theme.name: "theme"
920
921 Page {
922 title: i18n.tr("Theme sample")
923@@ -51,31 +38,15 @@
924 }
925
926 Label {
927- text: i18n.tr("Theme.name:") + " " + Theme.name
928- }
929-
930- Button {
931- width: parent.width
932- text: i18n.tr("Light background")
933-
934- onClicked: {
935- mainView.backgroundColor = "white";
936- }
937- }
938- Button {
939- width: parent.width
940- text: i18n.tr("Dark background")
941-
942- onClicked: {
943- mainView.backgroundColor = "blue";
944- }
945- }
946+ text: i18n.tr("Theme.name:") + " " + theme.name
947+ }
948+
949 Button {
950 width: parent.width
951 text: i18n.tr("Set Ambiance theme")
952
953 onClicked: {
954- Theme.name = "Ubuntu.Components.Themes.Ambiance";
955+ theme.name = "Ubuntu.Components.Themes.Ambiance";
956 }
957 }
958 Button {
959@@ -83,7 +54,7 @@
960 text: i18n.tr("Set SuruDark theme")
961
962 onClicked: {
963- Theme.name = "Ubuntu.Components.Themes.SuruDark";
964+ theme.name = "Ubuntu.Components.Themes.SuruDark";
965 }
966 }
967 Button {
968@@ -91,10 +62,10 @@
969 text: i18n.tr("Application theme")
970
971 onClicked: {
972- Theme.name = "theme";
973+ theme.name = "theme";
974 }
975 }
976 }
977 }
978 }
979-
980+//![0]
981
982=== modified file 'examples/customtheme/theme/Palette.qml'
983--- examples/customtheme/theme/Palette.qml 2015-03-03 13:47:48 +0000
984+++ examples/customtheme/theme/Palette.qml 2015-04-17 15:45:47 +0000
985@@ -1,5 +1,5 @@
986 /*
987- * Copyright 2014 Canonical Ltd.
988+ * Copyright 2015 Canonical Ltd.
989 *
990 * This program is free software; you can redistribute it and/or modify
991 * it under the terms of the GNU Lesser General Public License as published by
992@@ -14,11 +14,13 @@
993 * along with this program. If not, see <http://www.gnu.org/licenses/>.
994 */
995
996-import QtQuick 2.0
997-import Ubuntu.Components 1.2
998+//![0]
999+import QtQuick 2.4
1000+import Ubuntu.Components 1.3
1001 import Ubuntu.Components.Themes.SuruDark 1.1 as Suru
1002
1003 Suru.Palette {
1004 normal.background: "#A21E1C"
1005 selected.backgroundText: "lightblue"
1006 }
1007+//![0]
1008
1009=== modified file 'examples/examples.pro'
1010--- examples/examples.pro 2013-09-12 06:14:08 +0000
1011+++ examples/examples.pro 2015-04-17 15:45:47 +0000
1012@@ -4,7 +4,8 @@
1013 ubuntu-ui-toolkit-gallery\
1014 locale \
1015 unit-converter \
1016- calculator
1017+ calculator \
1018+ customtheme
1019
1020
1021 #examples = jokes unit-converter
1022
1023=== modified file 'examples/locale/locale.qml'
1024--- examples/locale/locale.qml 2015-03-03 13:47:48 +0000
1025+++ examples/locale/locale.qml 2015-04-17 15:45:47 +0000
1026@@ -1,5 +1,5 @@
1027 /*
1028- * Copyright 2012 Canonical Ltd.
1029+ * Copyright 2015 Canonical Ltd.
1030 *
1031 * This program is free software; you can redistribute it and/or modify
1032 * it under the terms of the GNU Lesser General Public License as published by
1033@@ -16,7 +16,7 @@
1034 */
1035
1036 import QtQuick 2.0
1037-import Ubuntu.Components 1.2
1038+import Ubuntu.Components 1.3
1039 import Ubuntu.Components.ListItems 1.0 as ListItem
1040
1041 /*!
1042@@ -89,7 +89,7 @@
1043 highlight: Rectangle {
1044 height: units.gu(2)
1045 width: view.width
1046- color: Theme.palette.selected.background
1047+ color: theme.palette.selected.background
1048 }
1049 }
1050 }
1051@@ -100,7 +100,7 @@
1052 leftMargin: units.gu(0.5)
1053 bottom: parent.bottom
1054 }
1055- color: Theme.palette.normal.base
1056+ color: theme.palette.normal.base
1057 width: parent.width
1058 Column {
1059 anchors.fill: parent
1060
1061=== modified file 'examples/ubuntu-ui-toolkit-gallery/ListItems.qml'
1062--- examples/ubuntu-ui-toolkit-gallery/ListItems.qml 2015-03-11 17:10:20 +0000
1063+++ examples/ubuntu-ui-toolkit-gallery/ListItems.qml 2015-04-17 15:45:47 +0000
1064@@ -1,5 +1,5 @@
1065 /*
1066- * Copyright 2013 Canonical Ltd.
1067+ * Copyright 2015 Canonical Ltd.
1068 *
1069 * This program is free software; you can redistribute it and/or modify
1070 * it under the terms of the GNU Lesser General Public License as published by
1071@@ -15,7 +15,7 @@
1072 */
1073
1074 import QtQuick 2.4
1075-import Ubuntu.Components 1.2 as Toolkit
1076+import Ubuntu.Components 1.3 as Toolkit
1077 import Ubuntu.Components.ListItems 1.0 as ListItem
1078
1079 Template {
1080@@ -207,7 +207,7 @@
1081 confirmRemoval: (index % 2)
1082 backgroundIndicator: Rectangle {
1083 anchors.fill: parent
1084- color: Theme.palette.normal.base
1085+ color: theme.palette.normal.base
1086 }
1087 }
1088
1089
1090=== modified file 'examples/ubuntu-ui-toolkit-gallery/Pickers.qml'
1091--- examples/ubuntu-ui-toolkit-gallery/Pickers.qml 2015-03-11 17:10:20 +0000
1092+++ examples/ubuntu-ui-toolkit-gallery/Pickers.qml 2015-04-17 15:45:47 +0000
1093@@ -1,5 +1,5 @@
1094 /*
1095- * Copyright 2013 Canonical Ltd.
1096+ * Copyright 2015 Canonical Ltd.
1097 *
1098 * This program is free software; you can redistribute it and/or modify
1099 * it under the terms of the GNU Lesser General Public License as published by
1100@@ -15,8 +15,8 @@
1101 */
1102
1103 import QtQuick 2.0
1104-import Ubuntu.Components 0.1
1105-import Ubuntu.Components.Pickers 0.1
1106+import Ubuntu.Components 1.3
1107+import Ubuntu.Components.Pickers 1.0
1108
1109 Template {
1110 objectName: "pickersTemplate"
1111@@ -158,7 +158,7 @@
1112 width: height
1113 height: units.gu(3)
1114 radius: width / 2
1115- color: Theme.palette.normal.background
1116+ color: theme.palette.normal.background
1117 antialiasing: true
1118 Label {
1119 text: Math.round(selector.value)
1120
1121=== modified file 'examples/ubuntu-ui-toolkit-gallery/Styles.qml'
1122--- examples/ubuntu-ui-toolkit-gallery/Styles.qml 2015-03-03 13:47:48 +0000
1123+++ examples/ubuntu-ui-toolkit-gallery/Styles.qml 2015-04-17 15:45:47 +0000
1124@@ -1,5 +1,5 @@
1125 /*
1126- * Copyright 2014 Canonical Ltd.
1127+ * Copyright 2015 Canonical Ltd.
1128 *
1129 * This program is free software; you can redistribute it and/or modify
1130 * it under the terms of the GNU Lesser General Public License as published by
1131@@ -15,7 +15,7 @@
1132 */
1133
1134 import QtQuick 2.4
1135-import Ubuntu.Components 1.1
1136+import Ubuntu.Components 1.3
1137
1138 Template {
1139 objectName: "stylesTemplate"
1140@@ -43,6 +43,7 @@
1141 OptionSelector {
1142 model: [ 'Ambiance', 'SuruDark' ]
1143 expanded: true
1144- onSelectedIndexChanged: Theme.name = 'Ubuntu.Components.Themes.%1'.arg(model[selectedIndex])
1145+ selectedIndex: (theme.name == 'Ubuntu.Components.Themes.SuruDark')
1146+ onSelectedIndexChanged: theme.name = 'Ubuntu.Components.Themes.%1'.arg(model[selectedIndex])
1147 }
1148 }
1149
1150=== modified file 'examples/ubuntu-ui-toolkit-gallery/UbuntuShape.qml'
1151--- examples/ubuntu-ui-toolkit-gallery/UbuntuShape.qml 2015-03-03 16:21:20 +0000
1152+++ examples/ubuntu-ui-toolkit-gallery/UbuntuShape.qml 2015-04-17 15:45:47 +0000
1153@@ -1,5 +1,5 @@
1154 /*
1155- * Copyright 2013 Canonical Ltd.
1156+ * Copyright 2015 Canonical Ltd.
1157 *
1158 * This program is free software; you can redistribute it and/or modify
1159 * it under the terms of the GNU Lesser General Public License as published by
1160@@ -14,8 +14,8 @@
1161 * along with this program. If not, see <http://www.gnu.org/licenses/>.
1162 */
1163
1164-import QtQuick 2.2
1165-import Ubuntu.Components 1.2
1166+import QtQuick 2.4
1167+import Ubuntu.Components 1.3
1168
1169 Template {
1170 objectName: "ubuntuShapesTemplate"
1171@@ -71,27 +71,27 @@
1172 UbuntuShape {
1173 objectName: "ubuntushape_radius_small"
1174
1175- backgroundColor: Theme.palette.normal.foreground
1176+ backgroundColor: theme.palette.normal.foreground
1177 radius: "small"
1178
1179 Label {
1180 anchors.centerIn: parent
1181 text: "small"
1182 fontSize: "x-small"
1183- color: Theme.palette.normal.foregroundText
1184+ color: theme.palette.normal.foregroundText
1185 }
1186 }
1187
1188 UbuntuShape {
1189 objectName: "ubuntushape_radius_medium"
1190- backgroundColor: Theme.palette.normal.foreground
1191+ backgroundColor: theme.palette.normal.foreground
1192 radius: "medium"
1193
1194 Label {
1195 anchors.centerIn: parent
1196 text: "medium"
1197 fontSize: "x-small"
1198- color: Theme.palette.normal.foregroundText
1199+ color: theme.palette.normal.foregroundText
1200 }
1201 }
1202 }
1203@@ -103,7 +103,7 @@
1204
1205 UbuntuShape {
1206 objectName: "ubuntushape_sizes_15_6"
1207- backgroundColor: Theme.palette.normal.foreground
1208+ backgroundColor: theme.palette.normal.foreground
1209 width: units.gu(15)
1210 height: units.gu(6)
1211 anchors.verticalCenter: parent.verticalCenter
1212@@ -111,7 +111,7 @@
1213
1214 UbuntuShape {
1215 objectName: "ubuntushape_sizes_10_14"
1216- backgroundColor: Theme.palette.normal.foreground
1217+ backgroundColor: theme.palette.normal.foreground
1218 width: units.gu(10)
1219 height: units.gu(14)
1220 }
1221
1222=== modified file 'examples/ubuntu-ui-toolkit-gallery/WebLink.qml'
1223--- examples/ubuntu-ui-toolkit-gallery/WebLink.qml 2015-03-03 13:20:06 +0000
1224+++ examples/ubuntu-ui-toolkit-gallery/WebLink.qml 2015-04-17 15:45:47 +0000
1225@@ -27,4 +27,9 @@
1226 text: "<a href=\"%1\">%2</a>".arg(webLink.url).arg(webLink.label)
1227 linkColor: UbuntuColors.orange
1228 onLinkActivated: Qt.openUrlExternally(link)
1229+ MouseArea {
1230+ anchors.fill: webLink
1231+ cursorShape: Qt.PointingHandCursor
1232+ acceptedButtons: Qt.NoButton
1233+ }
1234 }
1235
1236=== modified file 'modules/Ubuntu/Components/10/Button.qml'
1237--- modules/Ubuntu/Components/10/Button.qml 2015-03-03 13:47:48 +0000
1238+++ modules/Ubuntu/Components/10/Button.qml 2015-04-17 15:45:47 +0000
1239@@ -1,5 +1,5 @@
1240 /*
1241- * Copyright 2012 Canonical Ltd.
1242+ * Copyright 2015 Canonical Ltd.
1243 *
1244 * This program is free software; you can redistribute it and/or modify
1245 * it under the terms of the GNU Lesser General Public License as published by
1246@@ -15,7 +15,7 @@
1247 */
1248
1249 import QtQuick 2.4
1250-import Ubuntu.Components 1.2
1251+import Ubuntu.Components 1.3
1252
1253 /*!
1254 \internal
1255@@ -32,5 +32,5 @@
1256
1257 property string iconPosition: "left"
1258
1259- style: Theme.createStyleComponent("ButtonStyle.qml", button)
1260+ style: theme.createStyleComponent("ButtonStyle.qml", button)
1261 }
1262
1263=== modified file 'modules/Ubuntu/Components/11/Button.qml'
1264--- modules/Ubuntu/Components/11/Button.qml 2015-03-03 13:47:48 +0000
1265+++ modules/Ubuntu/Components/11/Button.qml 2015-04-17 15:45:47 +0000
1266@@ -1,5 +1,5 @@
1267 /*
1268- * Copyright 2014 Canonical Ltd.
1269+ * Copyright 2015 Canonical Ltd.
1270 *
1271 * This program is free software; you can redistribute it and/or modify
1272 * it under the terms of the GNU Lesser General Public License as published by
1273@@ -15,7 +15,7 @@
1274 */
1275
1276 import QtQuick 2.4
1277-import Ubuntu.Components 1.2
1278+import Ubuntu.Components 1.3
1279
1280 /*!
1281 \qmltype Button
1282@@ -121,5 +121,5 @@
1283 */
1284 property string iconPosition: "left"
1285
1286- style: Theme.createStyleComponent("ButtonStyle.qml", button)
1287+ style: theme.createStyleComponent("ButtonStyle.qml", button)
1288 }
1289
1290=== modified file 'modules/Ubuntu/Components/ActivityIndicator.qml'
1291--- modules/Ubuntu/Components/ActivityIndicator.qml 2015-03-03 13:47:48 +0000
1292+++ modules/Ubuntu/Components/ActivityIndicator.qml 2015-04-17 15:45:47 +0000
1293@@ -1,5 +1,5 @@
1294 /*
1295- * Copyright 2012 Canonical Ltd.
1296+ * Copyright 2015 Canonical Ltd.
1297 *
1298 * This program is free software; you can redistribute it and/or modify
1299 * it under the terms of the GNU Lesser General Public License as published by
1300@@ -55,5 +55,5 @@
1301 implicitWidth: units.gu(3)
1302 implicitHeight: units.gu(3)
1303
1304- style: Theme.createStyleComponent("ActivityIndicatorStyle.qml", indicator)
1305+ style: theme.createStyleComponent("ActivityIndicatorStyle.qml", indicator)
1306 }
1307
1308=== modified file 'modules/Ubuntu/Components/AnimatedItem.qml'
1309--- modules/Ubuntu/Components/AnimatedItem.qml 2015-03-03 13:47:48 +0000
1310+++ modules/Ubuntu/Components/AnimatedItem.qml 2015-04-17 15:45:47 +0000
1311@@ -25,8 +25,9 @@
1312 */
1313
1314 import QtQuick 2.4
1315+import Ubuntu.Components 1.3 as Toolkit
1316
1317-StyledItem {
1318+Toolkit.StyledItem {
1319 id: root
1320 /*!
1321 \deprecated
1322
1323=== modified file 'modules/Ubuntu/Components/AppHeader.qml'
1324--- modules/Ubuntu/Components/AppHeader.qml 2015-03-03 13:47:48 +0000
1325+++ modules/Ubuntu/Components/AppHeader.qml 2015-04-17 15:45:47 +0000
1326@@ -1,5 +1,5 @@
1327 /*
1328- * Copyright 2013-2014 Canonical Ltd.
1329+ * Copyright 2015 Canonical Ltd.
1330 *
1331 * This program is free software; you can redistribute it and/or modify
1332 * it under the terms of the GNU Lesser General Public License as published by
1333@@ -15,7 +15,7 @@
1334 */
1335
1336 import QtQuick 2.4
1337-import Ubuntu.Components 1.2 as Components
1338+import Ubuntu.Components 1.3 as Components
1339
1340 /*!
1341 \internal
1342@@ -23,7 +23,7 @@
1343 \inqmlmodule Ubuntu.Components 1.1
1344 \ingroup ubuntu
1345 */
1346-StyledItem {
1347+Components.StyledItem {
1348 id: header
1349
1350 anchors {
1351@@ -60,7 +60,8 @@
1352 internal.movementEnded();
1353 }
1354
1355- visible: title || contents || tabsModel
1356+ // with PageHeadConfiguration 1.2, always be visible.
1357+ visible: title || contents || tabsModel || internal.newConfig
1358 onVisibleChanged: {
1359 internal.checkFlickableMargins();
1360 }
1361@@ -69,6 +70,9 @@
1362 Show the header
1363 */
1364 function show() {
1365+ if (internal.newConfig) {
1366+ header.config.visible = true;
1367+ }
1368 header.y = 0;
1369 }
1370
1371@@ -76,7 +80,10 @@
1372 Hide the header
1373 */
1374 function hide() {
1375- header.y = - header.height;
1376+ if (internal.newConfig) {
1377+ header.config.visible = false;
1378+ }
1379+ header.y = -header.height;
1380 }
1381
1382 /*!
1383@@ -84,15 +91,22 @@
1384 */
1385 property string title: ""
1386 onTitleChanged: {
1387- header.show();
1388+ // deprecated for new versions of PageHeadConfiguration
1389+ if (!internal.newConfig) {
1390+ header.show();
1391+ }
1392 }
1393
1394 /*!
1395 The contents of the header. If this is set, \l title will be ignored.
1396+ DEPRECATED and replaced by Page.head.contents.
1397 */
1398 property Item contents: null
1399 onContentsChanged: {
1400- header.show();
1401+ // deprecated for new versions of PageHeadConfiguration
1402+ if (!internal.newConfig) {
1403+ header.show();
1404+ }
1405 }
1406
1407 /*!
1408@@ -151,9 +165,10 @@
1409 */
1410 property Flickable flickable: null
1411 onFlickableChanged: {
1412- internal.checkFlickableMargins();
1413 internal.connectFlickable();
1414- header.show();
1415+ if (!internal.newConfig || !header.config.locked) {
1416+ header.show();
1417+ }
1418 }
1419
1420 /*!
1421@@ -163,12 +178,68 @@
1422
1423 /*!
1424 Configuration of the header.
1425+ FIXME: Must be of type PageHeadConfiguration. Setting that as the property type
1426+ however will use the latest version (1.3) and a Page that uses an older
1427+ version (1.1) will no longer work.
1428 */
1429- property PageHeadConfiguration config: null
1430+ property Object config: null
1431+ onConfigChanged: {
1432+ // set internal.newConfig because when we rely on the binding,
1433+ // the value of newConfig may be updated after executing the code below.
1434+ internal.newConfig = config && config.hasOwnProperty("visible") &&
1435+ config.hasOwnProperty("locked");
1436+ internal.connectFlickable();
1437+
1438+ if (internal.newConfig && header.config.locked &&!header.config.visible) {
1439+ header.hide();
1440+ } else {
1441+ header.show();
1442+ }
1443+ }
1444+ Connections {
1445+ target: header.config
1446+ ignoreUnknownSignals: true // PageHeadConfiguration <1.2 lacks the signals below
1447+ onVisibleChanged: {
1448+ if (header.config.visible) {
1449+ header.show();
1450+ } else {
1451+ header.hide();
1452+ }
1453+ internal.checkFlickableMargins();
1454+ }
1455+ onLockedChanged: {
1456+ internal.connectFlickable();
1457+ if (!header.config.locked) {
1458+ internal.movementEnded();
1459+ }
1460+ }
1461+ }
1462+
1463+ /*!
1464+ The header is not fully opened or fully closed.
1465+
1466+ This property is true if the header is animating towards a fully
1467+ opened or fully closed state, or if the header is moving due to user
1468+ interaction with the flickable.
1469+
1470+ The value of moving is always false when using an old version of
1471+ PageHeadConfiguration (which does not have the visible property).
1472+
1473+ Used in tst_header_locked_visible.qml.
1474+ */
1475+ readonly property bool moving: internal.newConfig &&
1476+ ((config.visible && header.y !== 0) ||
1477+ (!config.visible && header.y !== -header.height))
1478
1479 QtObject {
1480 id: internal
1481
1482+ // This property is updated in header.onConfigChanged to ensure it
1483+ // is updated before other functions are called in onConfigChanged.
1484+ property bool newConfig: header.config &&
1485+ header.config.hasOwnProperty("locked") &&
1486+ header.config.hasOwnProperty("visible")
1487+
1488 /*!
1489 Track the y-position inside the flickable.
1490 */
1491@@ -183,20 +254,26 @@
1492 Disconnect previous flickable, and connect the new one.
1493 */
1494 function connectFlickable() {
1495+ // Finish the current header movement in case the current
1496+ // flickable is disconnected while scrolling:
1497+ internal.movementEnded();
1498+
1499 if (previousFlickable) {
1500 previousFlickable.contentYChanged.disconnect(internal.scrollContents);
1501 previousFlickable.movementEnded.disconnect(internal.movementEnded);
1502 previousFlickable.interactiveChanged.disconnect(internal.interactiveChanged);
1503+ previousFlickable = null;
1504 }
1505- if (flickable) {
1506+ if (flickable && !(internal.newConfig && header.config.locked)) {
1507 // Connect flicking to movements of the header
1508 previousContentY = flickable.contentY;
1509 flickable.contentYChanged.connect(internal.scrollContents);
1510 flickable.movementEnded.connect(internal.movementEnded);
1511 flickable.interactiveChanged.connect(internal.interactiveChanged);
1512 flickable.contentHeightChanged.connect(internal.contentHeightChanged);
1513+ previousFlickable = flickable;
1514 }
1515- previousFlickable = flickable;
1516+ internal.checkFlickableMargins();
1517 }
1518
1519 /*!
1520@@ -216,9 +293,14 @@
1521 Fully show or hide the header, depending on its current y.
1522 */
1523 function movementEnded() {
1524- if (flickable && flickable.contentY < 0) header.show();
1525- else if (header.y < -header.height/2) header.hide();
1526- else header.show();
1527+ if (!(internal.newConfig && header.config.locked)) {
1528+ if ( (flickable && flickable.contentY < 0) ||
1529+ (header.y > -header.height/2)) {
1530+ header.show();
1531+ } else {
1532+ header.hide();
1533+ }
1534+ }
1535 }
1536
1537 /*
1538@@ -241,18 +323,25 @@
1539 */
1540 function checkFlickableMargins() {
1541 if (header.flickable) {
1542- var headerHeight = header.visible ? header.height : 0
1543+ var headerHeight = 0;
1544+ if (header.visible && !(internal.newConfig &&
1545+ header.config.locked &&
1546+ !header.config.visible)) {
1547+ headerHeight = header.height;
1548+ }
1549+
1550 if (flickable.topMargin !== headerHeight) {
1551+ var oldContentY = flickable.contentY;
1552 var previousHeaderHeight = flickable.topMargin;
1553 flickable.topMargin = headerHeight;
1554 // push down contents when header grows,
1555 // pull up contents when header shrinks.
1556- flickable.contentY -= headerHeight - previousHeaderHeight;
1557+ flickable.contentY = oldContentY - headerHeight + previousHeaderHeight;
1558 }
1559 }
1560 }
1561 }
1562
1563- style: header.useDeprecatedToolbar ? Theme.createStyleComponent("HeaderStyle.qml", header) :
1564- Theme.createStyleComponent("PageHeadStyle.qml", header)
1565+ style: header.useDeprecatedToolbar ? theme.createStyleComponent("HeaderStyle.qml", header) :
1566+ theme.createStyleComponent("PageHeadStyle.qml", header)
1567 }
1568
1569=== modified file 'modules/Ubuntu/Components/CheckBox.qml'
1570--- modules/Ubuntu/Components/CheckBox.qml 2015-03-05 09:35:06 +0000
1571+++ modules/Ubuntu/Components/CheckBox.qml 2015-04-17 15:45:47 +0000
1572@@ -1,5 +1,5 @@
1573 /*
1574- * Copyright 2012 Canonical Ltd.
1575+ * Copyright 2015 Canonical Ltd.
1576 *
1577 * This program is free software; you can redistribute it and/or modify
1578 * it under the terms of the GNU Lesser General Public License as published by
1579@@ -49,5 +49,5 @@
1580 */
1581 onTriggered: checked = !checked
1582
1583- style: Theme.createStyleComponent("CheckBoxStyle.qml", checkBox)
1584+ style: theme.createStyleComponent("CheckBoxStyle.qml", checkBox)
1585 }
1586
1587=== modified file 'modules/Ubuntu/Components/ComboButton.qml'
1588--- modules/Ubuntu/Components/ComboButton.qml 2015-03-03 13:47:48 +0000
1589+++ modules/Ubuntu/Components/ComboButton.qml 2015-04-17 15:45:47 +0000
1590@@ -1,5 +1,5 @@
1591 /*
1592- * Copyright 2014 Canonical Ltd.
1593+ * Copyright 2015 Canonical Ltd.
1594 *
1595 * This program is free software; you can redistribute it and/or modify
1596 * it under the terms of the GNU Lesser General Public License as published by
1597@@ -248,7 +248,7 @@
1598 property color dropdownColor: __styleInstance ? __styleInstance.defaultDropdownColor : color
1599
1600
1601- style: Theme.createStyleComponent("ComboButtonStyle.qml", combo)
1602+ style: theme.createStyleComponent("ComboButtonStyle.qml", combo)
1603
1604 Component.onCompleted: {
1605 // update mouse area to report clicks only on the main button area
1606
1607=== modified file 'modules/Ubuntu/Components/Label.qml'
1608--- modules/Ubuntu/Components/Label.qml 2015-03-03 13:47:48 +0000
1609+++ modules/Ubuntu/Components/Label.qml 2015-04-17 15:45:47 +0000
1610@@ -1,5 +1,5 @@
1611 /*
1612- * Copyright 2012 Canonical Ltd.
1613+ * Copyright 2015 Canonical Ltd.
1614 *
1615 * This program is free software; you can redistribute it and/or modify
1616 * it under the terms of the GNU Lesser General Public License as published by
1617@@ -55,5 +55,5 @@
1618 property string fontSize: "medium"
1619
1620 font.pixelSize: FontUtils.sizeToPixels(fontSize)
1621- color: Theme.palette.selected.backgroundText
1622+ color: theme.palette.selected.backgroundText
1623 }
1624
1625=== modified file 'modules/Ubuntu/Components/ListItems/Caption.qml'
1626--- modules/Ubuntu/Components/ListItems/Caption.qml 2015-03-03 13:47:48 +0000
1627+++ modules/Ubuntu/Components/ListItems/Caption.qml 2015-04-17 15:45:47 +0000
1628@@ -1,5 +1,5 @@
1629 /*
1630- * Copyright 2012 Canonical Ltd.
1631+ * Copyright 2015 Canonical Ltd.
1632 *
1633 * This program is free software; you can redistribute it and/or modify
1634 * it under the terms of the GNU Lesser General Public License as published by
1635@@ -15,7 +15,7 @@
1636 */
1637
1638 import QtQuick 2.4
1639-import Ubuntu.Components 1.2
1640+import Ubuntu.Components 1.3
1641
1642 /*!
1643 \qmltype Caption
1644@@ -52,7 +52,7 @@
1645 anchors.centerIn: parent
1646 width: parent.width - units.gu(1)
1647 wrapMode: Text.Wrap
1648- color: Theme.palette.normal.backgroundText
1649+ color: theme.palette.normal.backgroundText
1650 horizontalAlignment: Text.AlignLeft
1651 fontSize: "small"
1652 }
1653
1654=== modified file 'modules/Ubuntu/Components/ListItems/Empty.qml'
1655--- modules/Ubuntu/Components/ListItems/Empty.qml 2015-03-03 13:47:48 +0000
1656+++ modules/Ubuntu/Components/ListItems/Empty.qml 2015-04-17 15:45:47 +0000
1657@@ -1,5 +1,5 @@
1658 /*
1659- * Copyright 2012, 2013, 2014 Canonical Ltd.
1660+ * Copyright 2015 Canonical Ltd.
1661 *
1662 * This program is free software; you can redistribute it and/or modify
1663 * it under the terms of the GNU Lesser General Public License as published by
1664@@ -15,7 +15,7 @@
1665 */
1666
1667 import QtQuick 2.4
1668-import Ubuntu.Components 1.2
1669+import Ubuntu.Components 1.3
1670
1671 /*!
1672 \qmltype Empty
1673@@ -291,7 +291,7 @@
1674 top: parent.top
1675 }
1676 height: emptyListItem.height - bottomDividerLine.height
1677- color: Theme.palette.selected.background
1678+ color: theme.palette.selected.background
1679 }
1680
1681 ThinDivider {
1682
1683=== modified file 'modules/Ubuntu/Components/ListItems/ItemSelector.qml'
1684--- modules/Ubuntu/Components/ListItems/ItemSelector.qml 2015-03-03 13:47:48 +0000
1685+++ modules/Ubuntu/Components/ListItems/ItemSelector.qml 2015-04-17 15:45:47 +0000
1686@@ -1,5 +1,5 @@
1687 /*
1688- * Copyright 2012 Canonical Ltd.
1689+ * Copyright 2015 Canonical Ltd.
1690 *
1691 * This program is free software; you can redistribute it and/or modify
1692 * it under the terms of the GNU Lesser General Public License as published by
1693@@ -16,7 +16,7 @@
1694
1695 import QtQuick 2.4
1696 import "." as ListItem
1697-import Ubuntu.Components 1.2
1698+import Ubuntu.Components 1.3
1699
1700 /*!
1701 \qmltype ItemSelector
1702@@ -207,7 +207,7 @@
1703
1704 readonly property url chevron: __styleInstance.chevron
1705 readonly property url tick: __styleInstance.tick
1706- readonly property color themeColour: Theme.palette.selected.fieldText
1707+ readonly property color themeColour: theme.palette.selected.fieldText
1708 readonly property alias colourImage: itemSelector.colourImage
1709 property bool currentlyExpanded: expanded || multiSelection
1710
1711@@ -216,7 +216,7 @@
1712 right: parent.right
1713 }
1714 state: itemSelector.expanded ? "expanded" : "collapsed"
1715- style: Theme.createStyleComponent("ListItemOptionSelectorStyle.qml", listContainer)
1716+ style: theme.createStyleComponent("ListItemOptionSelectorStyle.qml", listContainer)
1717
1718 states: [ State {
1719 name: "expanded"
1720
1721=== modified file 'modules/Ubuntu/Components/ListItems/LabelVisual.qml'
1722--- modules/Ubuntu/Components/ListItems/LabelVisual.qml 2015-03-03 13:47:48 +0000
1723+++ modules/Ubuntu/Components/ListItems/LabelVisual.qml 2015-04-17 15:45:47 +0000
1724@@ -1,5 +1,5 @@
1725 /*
1726- * Copyright 2012 Canonical Ltd.
1727+ * Copyright 2015 Canonical Ltd.
1728 *
1729 * This program is free software; you can redistribute it and/or modify
1730 * it under the terms of the GNU Lesser General Public License as published by
1731@@ -15,7 +15,7 @@
1732 */
1733
1734 import QtQuick 2.4
1735-import Ubuntu.Components 1.2
1736+import Ubuntu.Components 1.3
1737
1738 // internal helper class for text inside the list items.
1739 Label {
1740@@ -32,7 +32,7 @@
1741
1742 fontSize: "medium"
1743 elide: Text.ElideRight
1744- color: selected ? UbuntuColors.orange : secondary ? overlay ? Theme.palette.normal.overlayText : Theme.palette.normal.backgroundText
1745- : overlay ? Theme.palette.selected.overlayText : Theme.palette.selected.backgroundText
1746+ color: selected ? UbuntuColors.orange : secondary ? overlay ? theme.palette.normal.overlayText : theme.palette.normal.backgroundText
1747+ : overlay ? theme.palette.selected.overlayText : theme.palette.selected.backgroundText
1748 opacity: label.enabled ? 1.0 : 0.5
1749 }
1750
1751=== modified file 'modules/Ubuntu/Components/ListItems/ProgressionVisual.qml'
1752--- modules/Ubuntu/Components/ListItems/ProgressionVisual.qml 2015-03-03 13:47:48 +0000
1753+++ modules/Ubuntu/Components/ListItems/ProgressionVisual.qml 2015-04-17 15:45:47 +0000
1754@@ -1,5 +1,5 @@
1755 /*
1756- * Copyright 2012 Canonical Ltd.
1757+ * Copyright 2015 Canonical Ltd.
1758 *
1759 * This program is free software; you can redistribute it and/or modify
1760 * it under the terms of the GNU Lesser General Public License as published by
1761@@ -15,7 +15,7 @@
1762 */
1763
1764 import QtQuick 2.4
1765-import Ubuntu.Components 1.2
1766+import Ubuntu.Components 1.3
1767
1768 // Internal helper class for the visuals of
1769 // the progression symbol.
1770@@ -25,5 +25,5 @@
1771 property bool showSplit: false
1772 property real splitMargin
1773
1774- style: Theme.createStyleComponent("ProgressionVisualStyle.qml", progressionVisual)
1775+ style: theme.createStyleComponent("ProgressionVisualStyle.qml", progressionVisual)
1776 }
1777
1778=== modified file 'modules/Ubuntu/Components/ListItems/Standard.qml'
1779--- modules/Ubuntu/Components/ListItems/Standard.qml 2015-03-03 13:47:48 +0000
1780+++ modules/Ubuntu/Components/ListItems/Standard.qml 2015-04-17 15:45:47 +0000
1781@@ -1,5 +1,5 @@
1782 /*
1783- * Copyright 2012 Canonical Ltd.
1784+ * Copyright 2015 Canonical Ltd.
1785 *
1786 * This program is free software; you can redistribute it and/or modify
1787 * it under the terms of the GNU Lesser General Public License as published by
1788@@ -15,7 +15,7 @@
1789 */
1790
1791 import QtQuick 2.4
1792-import Ubuntu.Components 1.2
1793+import Ubuntu.Components 1.3
1794
1795 /*!
1796 \qmltype Standard
1797@@ -172,7 +172,7 @@
1798 bottom: parent.bottom
1799 left: parent.left
1800 }
1801- color: Theme.palette.selected.background
1802+ color: theme.palette.selected.background
1803 }
1804
1805 Rectangle {
1806@@ -185,7 +185,7 @@
1807 bottom: parent.bottom
1808 right: parent.right
1809 }
1810- color: Theme.palette.selected.background
1811+ color: theme.palette.selected.background
1812 }
1813
1814 IconVisual {
1815
1816=== modified file 'modules/Ubuntu/Components/ListItems/ThinDivider.qml'
1817--- modules/Ubuntu/Components/ListItems/ThinDivider.qml 2015-03-03 13:47:48 +0000
1818+++ modules/Ubuntu/Components/ListItems/ThinDivider.qml 2015-04-17 15:45:47 +0000
1819@@ -1,5 +1,5 @@
1820 /*
1821- * Copyright 2012 Canonical Ltd.
1822+ * Copyright 2015 Canonical Ltd.
1823 *
1824 * This program is free software; you can redistribute it and/or modify
1825 * it under the terms of the GNU Lesser General Public License as published by
1826@@ -15,7 +15,7 @@
1827 */
1828
1829 import QtQuick 2.4
1830-import Ubuntu.Components 1.2
1831+import Ubuntu.Components 1.3
1832
1833 /*!
1834 \qmltype ThinDivider
1835@@ -53,7 +53,7 @@
1836 // a private property to catch theme background color change
1837 // use private property instead of embedding it into a QtObject to avoid further
1838 // performance decrease
1839- property bool __lightBackground: ColorUtils.luminance(Theme.palette.normal.background) > 0.85
1840+ property bool __lightBackground: ColorUtils.luminance(theme.palette.normal.background) > 0.85
1841 // use a gradient of 4 steps instead of instantiating two Rectangles for performance reasons
1842 gradient: Gradient {
1843 GradientStop { position: 0.0; color: __lightBackground ? Qt.rgba(0, 0, 0, 0.1) : Qt.rgba(0, 0, 0, 0.4) }
1844
1845=== modified file 'modules/Ubuntu/Components/ListItems/ValueSelector.qml'
1846--- modules/Ubuntu/Components/ListItems/ValueSelector.qml 2015-03-03 13:47:48 +0000
1847+++ modules/Ubuntu/Components/ListItems/ValueSelector.qml 2015-04-17 15:45:47 +0000
1848@@ -1,5 +1,5 @@
1849 /*
1850- * Copyright 2012 Canonical Ltd.
1851+ * Copyright 2015 Canonical Ltd.
1852 *
1853 * This program is free software; you can redistribute it and/or modify
1854 * it under the terms of the GNU Lesser General Public License as published by
1855@@ -15,7 +15,7 @@
1856 */
1857
1858 import QtQuick 2.4
1859-import Ubuntu.Components 1.2
1860+import Ubuntu.Components 1.3
1861
1862 /*!
1863 ****DEPRECATED! PLEASE USE ITEM SELECTOR OR FOR THE UBUNTU SHAPE VERSION THE OPTION SELECTOR.****
1864@@ -262,7 +262,7 @@
1865
1866 model: selector.values
1867 Rectangle {
1868- color: Qt.lighter(Theme.palette.normal.base)
1869+ color: Qt.lighter(theme.palette.normal.base)
1870 height: valueRepeater.valueHeight
1871 width: parent.width
1872
1873
1874=== modified file 'modules/Ubuntu/Components/MainView.qml'
1875--- modules/Ubuntu/Components/MainView.qml 2015-03-03 13:47:48 +0000
1876+++ modules/Ubuntu/Components/MainView.qml 2015-04-17 15:45:47 +0000
1877@@ -125,6 +125,7 @@
1878 AppHeader {
1879 // This objectName is used in the MainView autopilot custom proxy object
1880 // in order to select the application header.
1881+ // Also used in tst_header_locked_visible.qml.
1882 objectName: "MainView_Header"
1883 id: headerItem
1884 property real bottomY: headerItem.y + headerItem.height
1885@@ -136,7 +137,7 @@
1886 flickable: internal.activePage ? internal.activePage.flickable : null
1887 pageStack: internal.activePage ? internal.activePage.pageStack : null
1888
1889- PageHeadConfiguration {
1890+ Toolkit.PageHeadConfiguration {
1891 id: headerConfig
1892 // for backwards compatibility with deprecated tools property
1893 actions: internal.activePage ?
1894
1895=== modified file 'modules/Ubuntu/Components/MainView12.qml'
1896--- modules/Ubuntu/Components/MainView12.qml 2015-03-03 12:53:42 +0000
1897+++ modules/Ubuntu/Components/MainView12.qml 2015-04-17 15:45:47 +0000
1898@@ -69,6 +69,7 @@
1899 AppHeader {
1900 // This objectName is used in the MainView autopilot custom proxy object
1901 // in order to select the application header.
1902+ // Also used in tst_header_locked_visible.qml.
1903 objectName: "MainView_Header"
1904 id: headerItem
1905 property real bottomY: headerItem.y + headerItem.height
1906@@ -80,10 +81,11 @@
1907 flickable: internal.activePage ? internal.activePage.flickable : null
1908 pageStack: internal.activePage ? internal.activePage.pageStack : null
1909
1910- contents: internal.activePage ?
1911+ contents: internal.activePage &&
1912+ internal.activePage.hasOwnProperty("__customHeaderContents") ?
1913 internal.activePage.__customHeaderContents : null
1914
1915- PageHeadConfiguration {
1916+ Toolkit.PageHeadConfiguration {
1917 id: defaultConfig
1918 // Used when there is no active Page, or a Page 1.0 is used which
1919 // does not have a PageHeadConfiguration.
1920@@ -114,9 +116,13 @@
1921 target: Qt.application
1922 onActiveChanged: {
1923 if (Qt.application.active) {
1924- headerItem.animate = false;
1925- headerItem.show();
1926- headerItem.animate = true;
1927+ if (!(headerItem.config &&
1928+ headerItem.config.hasOwnProperty("locked") &&
1929+ headerItem.locked)) {
1930+ headerItem.animate = false;
1931+ headerItem.show();
1932+ headerItem.animate = true;
1933+ }
1934 }
1935 }
1936 }
1937@@ -127,11 +133,15 @@
1938
1939 // Even when using MainView 1.1, we still support Page 1.0.
1940 // PageBase (=Page 1.0) is the superclass of Page 1.1.
1941- property PageBase activePage: isPage(mainView.activeLeafNode) ? mainView.activeLeafNode : null
1942+ property Item activePage: isPage(mainView.activeLeafNode) ? mainView.activeLeafNode : null
1943
1944 function isPage(item) {
1945- return item && item.hasOwnProperty("__isPageTreeNode") && item.__isPageTreeNode &&
1946- item.hasOwnProperty("title") && item.hasOwnProperty("tools");
1947+ return item && item.hasOwnProperty("__isPageTreeNode") &&
1948+ item.__isPageTreeNode &&
1949+ item.hasOwnProperty("title") &&
1950+ item.hasOwnProperty("flickable") &&
1951+ item.hasOwnProperty("active") &&
1952+ item.hasOwnProperty("pageStack")
1953 }
1954 }
1955
1956
1957=== modified file 'modules/Ubuntu/Components/MainViewBase.qml'
1958--- modules/Ubuntu/Components/MainViewBase.qml 2015-03-03 13:47:48 +0000
1959+++ modules/Ubuntu/Components/MainViewBase.qml 2015-04-17 15:45:47 +0000
1960@@ -1,5 +1,5 @@
1961 /*
1962- * Copyright 2012-2015 Canonical Ltd.
1963+ * Copyright 2015 Canonical Ltd.
1964 *
1965 * This program is free software; you can redistribute it and/or modify
1966 * it under the terms of the GNU Lesser General Public License as published by
1967@@ -15,7 +15,7 @@
1968 */
1969
1970 import QtQuick 2.4
1971-import Ubuntu.Components 1.2 as Toolkit
1972+import Ubuntu.Components 1.3 as Toolkit
1973 import Ubuntu.PerformanceMetrics 1.0
1974 import QtQuick.Window 2.0
1975
1976@@ -32,13 +32,13 @@
1977 // FIXME: Make sure that the theming is only in the background, and the style
1978 // should not occlude contents of the MainView. When making changes here, make
1979 // sure that bug https://bugs.launchpad.net/manhattan/+bug/1124076 does not come back.
1980- StyledItem {
1981+ Toolkit.StyledItem {
1982 id: background
1983 anchors.fill: parent
1984- style: Theme.createStyleComponent("MainViewStyle.qml", background)
1985+ style: theme.createStyleComponent("MainViewStyle.qml", background)
1986
1987 property color headerColor: backgroundColor
1988- property color backgroundColor: Theme.palette.normal.background
1989+ property color backgroundColor: theme.palette.normal.background
1990 property color footerColor: backgroundColor
1991
1992 /*
1993@@ -48,12 +48,19 @@
1994
1995 Qt bug: https://bugreports.qt-project.org/browse/QTBUG-11712
1996 */
1997- property string theme: (ColorUtils.luminance(backgroundColor) >= 0.85) ?
1998- "Ambiance" : "SuruDark"
1999- onThemeChanged: {
2000+
2001+ onBackgroundColorChanged: {
2002+ if (backgroundColor != theme.palette.normal.background) {
2003+ // custom color, proceed with auto-theming
2004+ autoThemeName = (ColorUtils.luminance(backgroundColor) >= 0.85) ?
2005+ "Ambiance" : "SuruDark";
2006+ }
2007+ }
2008+ property string autoThemeName
2009+ onAutoThemeNameChanged: {
2010 // only change the theme if the current one is a system one.
2011- if (theme !== "" && (Theme.name.search("Ubuntu.Components.Themes") >= 0)) {
2012- Theme.name = "Ubuntu.Components.Themes.%1".arg(theme);
2013+ if (autoThemeName !== "" && (theme.name.search("Ubuntu.Components.Themes") == 0)) {
2014+ mainView.theme.name = "Ubuntu.Components.Themes.%1".arg(autoThemeName);
2015 }
2016 }
2017 }
2018
2019=== modified file 'modules/Ubuntu/Components/OptionSelector.qml'
2020--- modules/Ubuntu/Components/OptionSelector.qml 2015-03-03 13:47:48 +0000
2021+++ modules/Ubuntu/Components/OptionSelector.qml 2015-04-17 15:45:47 +0000
2022@@ -1,5 +1,5 @@
2023 /*
2024- * Copyright 2012 Canonical Ltd.
2025+ * Copyright 2015 Canonical Ltd.
2026 *
2027 * This program is free software; you can redistribute it and/or modify
2028 * it under the terms of the GNU Lesser General Public License as published by
2029@@ -16,7 +16,7 @@
2030
2031 import QtQuick 2.4
2032 import "ListItems" as ListItem
2033-import Ubuntu.Components 1.2 as Toolkit
2034+import Ubuntu.Components 1.3 as Toolkit
2035
2036 /*!
2037 \qmltype OptionSelector
2038@@ -209,14 +209,14 @@
2039 visible: optionSelector.text !== "" ? true : false
2040 }
2041
2042- StyledItem {
2043+ Toolkit.StyledItem {
2044 id: listContainer
2045 objectName: "listContainer"
2046 activeFocusOnPress: true
2047
2048 readonly property url chevron: __styleInstance.chevron
2049 readonly property url tick: __styleInstance.tick
2050- readonly property color themeColour: Theme.palette.selected.fieldText
2051+ readonly property color themeColour: theme.palette.selected.fieldText
2052 readonly property alias colourImage: optionSelector.colourImage
2053 property bool currentlyExpanded: expanded || multiSelection
2054
2055@@ -225,7 +225,7 @@
2056 right: parent.right
2057 }
2058 state: optionSelector.expanded ? "expanded" : "collapsed"
2059- style: Theme.createStyleComponent("OptionSelectorStyle.qml", listContainer)
2060+ style: theme.createStyleComponent("OptionSelectorStyle.qml", listContainer)
2061 states: [ State {
2062 name: "expanded"
2063 when: listContainer.currentlyExpanded
2064
2065=== modified file 'modules/Ubuntu/Components/Page10.qml'
2066--- modules/Ubuntu/Components/Page10.qml 2015-03-03 13:47:48 +0000
2067+++ modules/Ubuntu/Components/Page10.qml 2015-04-17 15:45:47 +0000
2068@@ -15,7 +15,8 @@
2069 */
2070
2071 import QtQuick 2.4
2072-import Ubuntu.Components 1.2 as Toolkit
2073+import Ubuntu.Components 1.0 as Toolkit
2074+import "pageUtils.js" as Utils
2075
2076 /*!
2077 \internal
2078@@ -53,7 +54,7 @@
2079 */
2080 property Item __customHeaderContents: null
2081
2082- property Flickable flickable: internal.getFlickableChild(page)
2083+ property Flickable flickable: Utils.getFlickableChild(page)
2084
2085 /*! \internal */
2086 onActiveChanged: {
2087@@ -95,34 +96,5 @@
2088 when: internal.header && !internal.header.useDeprecatedToolbar &&
2089 page.tools !== null
2090 }
2091-
2092- function isVerticalFlickable(object) {
2093- if (object && object.hasOwnProperty("flickableDirection") && object.hasOwnProperty("contentHeight")) {
2094- var direction = object.flickableDirection;
2095- if ( ((direction === Flickable.AutoFlickDirection) && (object.contentHeight !== object.height) )
2096- || direction === Flickable.VerticalFlick
2097- || direction === Flickable.HorizontalAndVerticalFlick) {
2098- return true;
2099- }
2100- }
2101- return false;
2102- }
2103-
2104- /*!
2105- Return the first flickable child of this page.
2106- */
2107- function getFlickableChild(item) {
2108- if (item && item.hasOwnProperty("children")) {
2109- for (var i=0; i < item.children.length; i++) {
2110- var child = item.children[i];
2111- if (internal.isVerticalFlickable(child)) {
2112- if (child.anchors.top === page.top || child.anchors.fill === page) {
2113- return item.children[i];
2114- }
2115- }
2116- }
2117- }
2118- return null;
2119- }
2120 }
2121 }
2122
2123=== modified file 'modules/Ubuntu/Components/Page11.qml'
2124--- modules/Ubuntu/Components/Page11.qml 2015-03-03 12:53:42 +0000
2125+++ modules/Ubuntu/Components/Page11.qml 2015-04-17 15:45:47 +0000
2126@@ -15,16 +15,18 @@
2127 */
2128
2129 import QtQuick 2.4
2130+import Ubuntu.Components 1.0 as Toolkit10
2131+import Ubuntu.Components 1.1 as Toolkit11
2132
2133 /*! \internal */
2134 // Documentation in Page.qdoc
2135-Page10 {
2136+Toolkit10.Page {
2137 id: page
2138 /*!
2139 \qmlproperty PageHeadConfiguration head
2140 */
2141 readonly property alias head: headerConfig
2142- PageHeadConfiguration {
2143+ Toolkit11.PageHeadConfiguration {
2144 id: headerConfig
2145 }
2146
2147@@ -32,7 +34,7 @@
2148 print("Page.tools is a deprecated property. Please use Page.head instead.");
2149 }
2150
2151- Object {
2152+ Toolkit11.Object {
2153 id: internal
2154
2155 // Note: The bindings below need to check whether headerConfig.contents
2156
2157=== added file 'modules/Ubuntu/Components/Page13.qml'
2158--- modules/Ubuntu/Components/Page13.qml 1970-01-01 00:00:00 +0000
2159+++ modules/Ubuntu/Components/Page13.qml 2015-04-17 15:45:47 +0000
2160@@ -0,0 +1,84 @@
2161+/*
2162+ * Copyright 2015 Canonical Ltd.
2163+ *
2164+ * This program is free software; you can redistribute it and/or modify
2165+ * it under the terms of the GNU Lesser General Public License as published by
2166+ * the Free Software Foundation; version 3.
2167+ *
2168+ * This program is distributed in the hope that it will be useful,
2169+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2170+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2171+ * GNU Lesser General Public License for more details.
2172+ *
2173+ * You should have received a copy of the GNU Lesser General Public License
2174+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
2175+ */
2176+
2177+import QtQuick 2.4
2178+import Ubuntu.Components 1.3 as Toolkit13
2179+import "pageUtils.js" as Utils
2180+
2181+/*!
2182+ \internal
2183+ Documentation is in Page.qdoc
2184+*/
2185+PageTreeNode {
2186+ id: page
2187+ anchors {
2188+ left: parent ? parent.left : undefined
2189+ bottom: parent ? parent.bottom : undefined
2190+ }
2191+ // Set width and height so that a parent Loader can be automatically resized
2192+ // to the size of the loaded Page.
2193+ width: parentNode ? parentNode.width - page.x : undefined
2194+ height: parentNode ? page.flickable ? parentNode.height : parentNode.height - internal.headerHeight : undefined
2195+
2196+ isLeaf: true
2197+ property string title: parentNode && parentNode.hasOwnProperty("title") ? parentNode.title : ""
2198+ property Flickable flickable: Utils.getFlickableChild(page)
2199+
2200+ /*!
2201+ \qmlproperty PageHeadConfiguration head
2202+ */
2203+ readonly property alias head: headerConfig
2204+ Toolkit13.PageHeadConfiguration {
2205+ id: headerConfig
2206+ }
2207+
2208+ Object {
2209+ id: internal
2210+
2211+ property AppHeader header: page.__propagated && page.__propagated.header ? page.__propagated.header : null
2212+ // Used to position the Page when there is no flickable.
2213+ // When there is a flickable, the header will automatically position it.
2214+ property real headerHeight: internal.header && internal.header.visible ? internal.header.height : 0
2215+
2216+ // Note: The bindings below need to check whether headerConfig.contents
2217+ // is valid in the "value", even when that is required in the Binding's "when"
2218+ // property, to avoid TypeErrors while/after a page becomes (in)active.
2219+ //
2220+ // Note 2: contents.parent binding is made by PageHeadStyle.
2221+ property bool hasParent: headerConfig.contents &&
2222+ headerConfig.contents.parent
2223+
2224+ Binding {
2225+ target: headerConfig.contents
2226+ property: "visible"
2227+ value: page.active
2228+ when: headerConfig.contents
2229+ }
2230+ Binding {
2231+ target: headerConfig.contents
2232+ property: "anchors.verticalCenter"
2233+ value: internal.hasParent ? headerConfig.contents.parent.verticalCenter :
2234+ undefined
2235+ when: headerConfig.contents
2236+ }
2237+ Binding {
2238+ target: headerConfig.contents
2239+ property: "anchors.left"
2240+ value: internal.hasParent ? headerConfig.contents.parent.left : undefined
2241+ when: headerConfig.contents
2242+ }
2243+ }
2244+}
2245
2246=== added file 'modules/Ubuntu/Components/PageHeadConfiguration.qdoc'
2247--- modules/Ubuntu/Components/PageHeadConfiguration.qdoc 1970-01-01 00:00:00 +0000
2248+++ modules/Ubuntu/Components/PageHeadConfiguration.qdoc 2015-04-17 15:45:47 +0000
2249@@ -0,0 +1,202 @@
2250+/*
2251+ * Copyright 2014-2015 Canonical Ltd.
2252+ *
2253+ * This program is free software; you can redistribute it and/or modify
2254+ * it under the terms of the GNU Lesser General Public License as published by
2255+ * the Free Software Foundation; version 3.
2256+ *
2257+ * This program is distributed in the hope that it will be useful,
2258+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2259+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2260+ * GNU Lesser General Public License for more details.
2261+ *
2262+ * You should have received a copy of the GNU Lesser General Public License
2263+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
2264+ */
2265+
2266+/*!
2267+ \qmltype PageHeadConfiguration
2268+ \inqmlmodule Ubuntu.Components 1.1
2269+ \ingroup ubuntu
2270+ \since Ubuntu.Components 1.1
2271+ \brief Page.head is used to configure the header for a \l Page.
2272+
2273+ For examples how to use Page.head, see \l Page.
2274+ */
2275+
2276+/*!
2277+ List of actions to show in the header.
2278+
2279+ Example:
2280+ \qml
2281+ Page {
2282+ title: "Custom header actions"
2283+ head.actions: [
2284+ Action {
2285+ iconName: "save"
2286+ text: i18n.tr("Save")
2287+ },
2288+ Action {
2289+ iconName: "add"
2290+ text: i18n.tr("Add")
2291+ }
2292+ ]
2293+ }
2294+ \endqml
2295+ \qmlproperty list<Action> PageHeadConfiguration::actions
2296+ */
2297+
2298+/*!
2299+ \qmlproperty Action PageHeadConfiguration::backAction
2300+ Overrides the default \l PageStack back button and the
2301+ \l Tabs drawer button in the header.
2302+
2303+ Example:
2304+ \qml
2305+ Page {
2306+ title: "Back Action Page"
2307+ head.backAction: Action {
2308+ iconName: "close"
2309+ onTriggered: {
2310+ console.log("Run custom back action")
2311+ }
2312+ }
2313+ }
2314+ \endqml
2315+ */
2316+
2317+/*!
2318+ \qmlproperty Item PageHeadConfiguration::contents
2319+ Set this property to show this Item in the header instead of
2320+ the title. Use a \l TextField here for implementing search in header.
2321+
2322+ The parent of this Item will be binded while the \l Page is active.
2323+ The header contents will automatically be anchored to the left and
2324+ vertically centered inside the header.
2325+
2326+ Example:
2327+ \qml
2328+ Page {
2329+ title: "Invisible title"
2330+ head.contents: Rectangle {
2331+ color: UbuntuColors.orange
2332+ height: units.gu(5)
2333+ width: parent ? parent.width - units.gu(2) : undefined
2334+ }
2335+ }
2336+ \endqml
2337+
2338+ See \l PageHeadState for an example that shows how search mode can
2339+ be implemented.
2340+ */
2341+
2342+// FIXME: The example below can be much simplified using PageHeadState
2343+// when bug #1345775 has been fixed.
2344+/*!
2345+ \qmlproperty string PageHeadConfiguration::preset
2346+ Choose a preset for the header visuals and behavior.
2347+ The default is an empty string "".
2348+ By setting this to "select", title will be hidden and
2349+ actions will be represented by icons with a label.
2350+
2351+ Example:
2352+ \qml
2353+ import QtQuick 2.4
2354+ import Ubuntu.Components 1.2
2355+
2356+ MainView {
2357+ id: mainView
2358+ width: units.gu(40)
2359+ height: units.gu(50)
2360+
2361+ Page {
2362+ id: page
2363+ title: "Demo"
2364+
2365+ state: "default"
2366+ states: [
2367+ PageHeadState {
2368+ name: "default"
2369+ head: page.head
2370+ actions: [
2371+ Action {
2372+ iconName: "contact"
2373+ text: "Contact"
2374+ }
2375+ ]
2376+ },
2377+ State {
2378+ id: selectState
2379+ name: "select"
2380+
2381+ property Action leaveSelect: Action {
2382+ iconName: "back"
2383+ text: "Back"
2384+ onTriggered: page.state = "default"
2385+ }
2386+ property list<Action> actions: [
2387+ Action {
2388+ iconName: "select"
2389+ text: "Select All"
2390+ },
2391+ Action {
2392+ iconName: "delete"
2393+ text: "Delete"
2394+ }
2395+ ]
2396+ PropertyChanges {
2397+ target: page.head
2398+ backAction: selectState.leaveSelect
2399+ actions: selectState.actions
2400+ preset: "select"
2401+ }
2402+ }
2403+ ]
2404+
2405+ Label {
2406+ anchors.centerIn: parent
2407+ text: "Use back button to leave selection mode."
2408+ visible: page.state == "select"
2409+ }
2410+
2411+ Button {
2412+ anchors.centerIn: parent
2413+ onClicked: page.state = "select"
2414+ visible: page.state != "select"
2415+ text: "selection mode"
2416+ }
2417+ }
2418+ }
2419+ \endqml
2420+ */
2421+
2422+/*!
2423+ \qmlproperty PageHeadSections PageHeadConfiguration::sections
2424+ Defines the sections in the page header divider.
2425+ */
2426+
2427+/*!
2428+ \qmlproperty color PageHeadConfiguration::foregroundColor
2429+ The color of the text and icons.
2430+ */
2431+
2432+/*!
2433+ \qmlproperty bool PageHeadConfiguration::locked
2434+ \since 1.2
2435+ When the \l Page is active, the locked property controls the behavior
2436+ of the header. A locked header stays visible or invisible, depending
2437+ on the value of the \l visible property. An unlocked header automatically
2438+ shows and hides if the \l Page has a flickable in which the user
2439+ scrolls up or down.
2440+ Default value: false
2441+ */
2442+
2443+/*!
2444+ \qmlproperty bool PageHeadConfiguration::visible
2445+ \since 1.2
2446+ Update the value of the visible property to show or hide the header.
2447+ This works both when the header is \l locked and unlocked. An unlocked
2448+ header can also become visible or hidden when the user scrolls the
2449+ active \l Page's flickable. The value of the visible property will be
2450+ updated at the end of the showing/hiding animation of the header.
2451+ */
2452
2453=== renamed file 'modules/Ubuntu/Components/PageHeadConfiguration.qml' => 'modules/Ubuntu/Components/PageHeadConfiguration11.qml'
2454--- modules/Ubuntu/Components/PageHeadConfiguration.qml 2015-03-03 13:47:48 +0000
2455+++ modules/Ubuntu/Components/PageHeadConfiguration11.qml 2015-04-17 15:45:47 +0000
2456@@ -1,5 +1,5 @@
2457 /*
2458- * Copyright 2014-2015 Canonical Ltd.
2459+ * Copyright 2015 Canonical Ltd.
2460 *
2461 * This program is free software; you can redistribute it and/or modify
2462 * it under the terms of the GNU Lesser General Public License as published by
2463@@ -15,92 +15,24 @@
2464 */
2465
2466 import QtQuick 2.4
2467-import Ubuntu.Components 1.2
2468+import Ubuntu.Components 1.3
2469
2470 /*!
2471- \qmltype PageHeadConfiguration
2472- \inqmlmodule Ubuntu.Components 1.1
2473- \ingroup ubuntu
2474- \since Ubuntu.Components 1.1
2475- \brief Page.head is used to configure the header for a \l Page.
2476-
2477- For examples how to use Page.head, see \l Page.
2478+ \internal
2479+ Documented in PageHeadConfiguration.qdoc
2480 */
2481 Object {
2482 // To be used inside a Page only.
2483 id: headerConfig
2484
2485- /*!
2486- List of actions to show in the header.
2487-
2488- Example:
2489- \qml
2490- Page {
2491- title: "Custom header actions"
2492- head.actions: [
2493- Action {
2494- iconName: "save"
2495- text: i18n.tr("Save")
2496- },
2497- Action {
2498- iconName: "add"
2499- text: i18n.tr("Add")
2500- }
2501- ]
2502- }
2503- \endqml
2504- */
2505 property list<Action> actions
2506-
2507- /*!
2508- Overrides the default \l PageStack back button and the
2509- \l Tabs drawer button in the header.
2510-
2511- Example:
2512- \qml
2513- Page {
2514- title: "Back Action Page"
2515- head.backAction: Action {
2516- iconName: "close"
2517- onTriggered: {
2518- console.log("Run custom back action")
2519- }
2520- }
2521- }
2522- \endqml
2523- */
2524 property Action backAction: null
2525-
2526- /*!
2527- Set this property to show this Item in the header instead of
2528- the title. Use a \l TextField here for implementing search in header.
2529-
2530- The parent of this Item will be binded while the \l Page is active.
2531- The header contents will automatically be anchored to the left and
2532- vertically centered inside the header.
2533-
2534- Example:
2535- \qml
2536- Page {
2537- title: "Invisible title"
2538- head.contents: Rectangle {
2539- color: UbuntuColors.orange
2540- height: units.gu(5)
2541- width: parent ? parent.width - units.gu(2) : undefined
2542- }
2543- }
2544- \endqml
2545-
2546- See \l PageHeadState for an example that shows how search mode can
2547- be implemented.
2548- */
2549 property Item contents: null
2550
2551 QtObject {
2552 id: internal
2553 property Item oldContents: null
2554 }
2555-
2556 onContentsChanged: {
2557 if (internal.oldContents) {
2558 // FIX: bug #1341814 and #1400297
2559@@ -111,97 +43,13 @@
2560 internal.oldContents = contents;
2561 }
2562
2563- // FIXME: The example below can be much simplified using PageHeadState
2564- // when bug #1345775 has been fixed.
2565- /*!
2566- Choose a preset for the header visuals and behavior.
2567- The default is an empty string "".
2568- By setting this to "select", title will be hidden and
2569- actions will be represented by icons with a label.
2570-
2571- Example:
2572- \qml
2573- import QtQuick 2.4
2574- import Ubuntu.Components 1.2
2575-
2576- MainView {
2577- id: mainView
2578- width: units.gu(40)
2579- height: units.gu(50)
2580-
2581- Page {
2582- id: page
2583- title: "Demo"
2584-
2585- state: "default"
2586- states: [
2587- PageHeadState {
2588- name: "default"
2589- head: page.head
2590- actions: [
2591- Action {
2592- iconName: "contact"
2593- text: "Contact"
2594- }
2595- ]
2596- },
2597- State {
2598- id: selectState
2599- name: "select"
2600-
2601- property Action leaveSelect: Action {
2602- iconName: "back"
2603- text: "Back"
2604- onTriggered: page.state = "default"
2605- }
2606- property list<Action> actions: [
2607- Action {
2608- iconName: "select"
2609- text: "Select All"
2610- },
2611- Action {
2612- iconName: "delete"
2613- text: "Delete"
2614- }
2615- ]
2616- PropertyChanges {
2617- target: page.head
2618- backAction: selectState.leaveSelect
2619- actions: selectState.actions
2620- preset: "select"
2621- }
2622- }
2623- ]
2624-
2625- Label {
2626- anchors.centerIn: parent
2627- text: "Use back button to leave selection mode."
2628- visible: page.state == "select"
2629- }
2630-
2631- Button {
2632- anchors.centerIn: parent
2633- onClicked: page.state = "select"
2634- visible: page.state != "select"
2635- text: "selection mode"
2636- }
2637- }
2638- }
2639- \endqml
2640- */
2641 property string preset: ""
2642-
2643 /*!
2644 \qmlproperty PageHeadSections sections
2645- Defines the sections in the page header divider.
2646 */
2647 readonly property alias sections: headSections
2648 PageHeadSections {
2649 id: headSections
2650 }
2651-
2652- /*!
2653- The color of the text and icons.
2654- */
2655- property color foregroundColor: Theme.palette.selected.backgroundText
2656+ property color foregroundColor: theme.palette.selected.backgroundText
2657 }
2658
2659=== added file 'modules/Ubuntu/Components/PageHeadConfiguration13.qml'
2660--- modules/Ubuntu/Components/PageHeadConfiguration13.qml 1970-01-01 00:00:00 +0000
2661+++ modules/Ubuntu/Components/PageHeadConfiguration13.qml 2015-04-17 15:45:47 +0000
2662@@ -0,0 +1,30 @@
2663+/*
2664+ * Copyright 2015 Canonical Ltd.
2665+ *
2666+ * This program is free software; you can redistribute it and/or modify
2667+ * it under the terms of the GNU Lesser General Public License as published by
2668+ * the Free Software Foundation; version 3.
2669+ *
2670+ * This program is distributed in the hope that it will be useful,
2671+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2672+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2673+ * GNU Lesser General Public License for more details.
2674+ *
2675+ * You should have received a copy of the GNU Lesser General Public License
2676+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
2677+ */
2678+
2679+import Ubuntu.Components 1.2 as Toolkit12
2680+
2681+/*!
2682+ \internal
2683+ documented in PageHeadConfiguration.qdoc
2684+ */
2685+Toolkit12.PageHeadConfiguration {
2686+ id: headerConfig
2687+
2688+ property bool locked: false
2689+
2690+ // auto-updated by AppHeader, but may be set by the developer
2691+ property bool visible
2692+}
2693
2694=== modified file 'modules/Ubuntu/Components/PageTreeNode.qml'
2695--- modules/Ubuntu/Components/PageTreeNode.qml 2015-03-03 13:47:48 +0000
2696+++ modules/Ubuntu/Components/PageTreeNode.qml 2015-04-17 15:45:47 +0000
2697@@ -15,6 +15,7 @@
2698 */
2699
2700 import QtQuick 2.4
2701+import Ubuntu.Components 1.3 as Toolkit
2702
2703 /*!
2704 \internal
2705@@ -26,7 +27,7 @@
2706 It is used to propagate properties such as \l header and \l toolbar from a
2707 \l MainView (the root node) to each \l Page (leaf node) in the tree.
2708 */
2709-StyledItem {
2710+Toolkit.StyledItem {
2711 id: node
2712
2713 /*!
2714
2715=== modified file 'modules/Ubuntu/Components/Panel.qml'
2716--- modules/Ubuntu/Components/Panel.qml 2015-03-03 13:47:48 +0000
2717+++ modules/Ubuntu/Components/Panel.qml 2015-04-17 15:45:47 +0000
2718@@ -1,5 +1,5 @@
2719 /*
2720- * Copyright (C) 2013 Canonical Ltd.
2721+ * Copyright (C) 2015 Canonical Ltd.
2722 *
2723 * This program is free software; you can redistribute it and/or modify
2724 * it under the terms of the GNU Lesser General Public License as published by
2725@@ -15,7 +15,7 @@
2726 */
2727
2728 import QtQuick 2.4
2729-import Ubuntu.Components 1.2 as Toolkit
2730+import Ubuntu.Components 1.3 as Toolkit
2731
2732 /*!
2733 \qmltype Panel
2734@@ -55,7 +55,7 @@
2735
2736 Rectangle {
2737 anchors.fill: parent
2738- color: Theme.palette.normal.overlay
2739+ color: theme.palette.normal.overlay
2740
2741 Button {
2742 anchors.centerIn: parent
2743@@ -109,7 +109,7 @@
2744 import Ubuntu.Components 1.2
2745
2746 Rectangle {
2747- color: Theme.palette.normal.background
2748+ color: theme.palette.normal.background
2749 width: units.gu(40)
2750 height: units.gu(40)
2751
2752@@ -123,7 +123,7 @@
2753 height: units.gu(8)
2754
2755 Rectangle {
2756- color: Theme.palette.normal.overlay
2757+ color: theme.palette.normal.overlay
2758 anchors.fill: parent
2759 Rectangle {
2760 width: units.gu(8)
2761
2762=== modified file 'modules/Ubuntu/Components/Pickers/DatePicker.qml'
2763--- modules/Ubuntu/Components/Pickers/DatePicker.qml 2015-03-03 13:47:48 +0000
2764+++ modules/Ubuntu/Components/Pickers/DatePicker.qml 2015-04-17 15:45:47 +0000
2765@@ -1,5 +1,5 @@
2766 /*
2767- * Copyright 2013 Canonical Ltd.
2768+ * Copyright 2015 Canonical Ltd.
2769 *
2770 * This program is free software; you can redistribute it and/or modify
2771 * it under the terms of the GNU Lesser General Public License as published by
2772@@ -15,7 +15,7 @@
2773 */
2774
2775 import QtQuick 2.4
2776-import Ubuntu.Components 1.2
2777+import Ubuntu.Components 1.3
2778
2779 /*!
2780 \qmltype DatePicker
2781@@ -420,7 +420,7 @@
2782 }
2783 }
2784
2785- style: Theme.createStyleComponent("DatePickerStyle.qml", datePicker)
2786+ style: theme.createStyleComponent("DatePickerStyle.qml", datePicker)
2787 Binding {
2788 target: __styleInstance
2789 property: "view"
2790
2791=== modified file 'modules/Ubuntu/Components/Pickers/Dialer.qml'
2792--- modules/Ubuntu/Components/Pickers/Dialer.qml 2015-03-03 13:47:48 +0000
2793+++ modules/Ubuntu/Components/Pickers/Dialer.qml 2015-04-17 15:45:47 +0000
2794@@ -1,5 +1,5 @@
2795 /*
2796- * Copyright 2013 Canonical Ltd.
2797+ * Copyright 2015 Canonical Ltd.
2798 *
2799 * This program is free software; you can redistribute it and/or modify
2800 * it under the terms of the GNU Lesser General Public License as published by
2801@@ -15,13 +15,14 @@
2802 */
2803
2804 import QtQuick 2.4
2805-import Ubuntu.Components 1.2
2806+import Ubuntu.Components 1.3
2807
2808 /*!
2809 \qmltype Dialer
2810 \inqmlmodule Ubuntu.Components.Pickers 1.0
2811 \ingroup ubuntu-pickers
2812 \brief Dialer is a phone dialer style picker component.
2813+ \deprecated
2814
2815 The Dialer component is dedicated for value selection where the value is
2816 compound of several sections, i.e. hour, minute and second, or integral and
2817@@ -144,7 +145,7 @@
2818 implicitHeight: size
2819 activeFocusOnPress: true
2820
2821- style: Theme.createStyleComponent("DialerStyle.qml", dialer)
2822+ style: theme.createStyleComponent("DialerStyle.qml", dialer)
2823
2824 Item {
2825 id: internal
2826
2827=== modified file 'modules/Ubuntu/Components/Pickers/DialerHand.qml'
2828--- modules/Ubuntu/Components/Pickers/DialerHand.qml 2015-03-03 13:47:48 +0000
2829+++ modules/Ubuntu/Components/Pickers/DialerHand.qml 2015-04-17 15:45:47 +0000
2830@@ -1,5 +1,5 @@
2831 /*
2832- * Copyright 2013 Canonical Ltd.
2833+ * Copyright 2015 Canonical Ltd.
2834 *
2835 * This program is free software; you can redistribute it and/or modify
2836 * it under the terms of the GNU Lesser General Public License as published by
2837@@ -15,13 +15,14 @@
2838 */
2839
2840 import QtQuick 2.4
2841-import Ubuntu.Components 1.2
2842+import Ubuntu.Components 1.3
2843
2844 /*!
2845 \qmltype DialerHand
2846 \inqmlmodule Ubuntu.Components.Pickers 1.0
2847 \ingroup ubuntu-pickers
2848 \brief DialerHand represents a value selector on a Dialer.
2849+ \deprecated
2850
2851 DialerHand components have meaning only if those are placed inside Dialer
2852 components. The dialer hand presents a value selection from the given dialer's
2853@@ -65,7 +66,7 @@
2854 width: height
2855 height: units.gu(3)
2856 radius: width / 2
2857- color: Theme.palette.normal.background
2858+ color: theme.palette.normal.background
2859 antialiasing: true
2860 Label {
2861 text: Math.round(selector.value)
2862@@ -142,7 +143,7 @@
2863 width: parent.width
2864 height: parent.height
2865 activeFocusOnPress: true
2866- style: Theme.createStyleComponent("DialerHandStyle.qml", dialerHand)
2867+ style: theme.createStyleComponent("DialerHandStyle.qml", dialerHand)
2868
2869 /*! \internal */
2870 onParentChanged: {
2871
2872=== modified file 'modules/Ubuntu/Components/Pickers/Picker.qml'
2873--- modules/Ubuntu/Components/Pickers/Picker.qml 2015-03-03 13:47:48 +0000
2874+++ modules/Ubuntu/Components/Pickers/Picker.qml 2015-04-17 15:45:47 +0000
2875@@ -1,5 +1,5 @@
2876 /*
2877- * Copyright 2013 Canonical Ltd.
2878+ * Copyright 2015 Canonical Ltd.
2879 *
2880 * This program is free software; you can redistribute it and/or modify
2881 * it under the terms of the GNU Lesser General Public License as published by
2882@@ -15,7 +15,7 @@
2883 */
2884
2885 import QtQuick 2.4
2886-import Ubuntu.Components 1.2
2887+import Ubuntu.Components 1.3
2888
2889 /*!
2890 \qmltype Picker
2891@@ -159,7 +159,7 @@
2892 implicitHeight: units.gu(20)
2893 activeFocusOnPress: true
2894
2895- style: Theme.createStyleComponent("PickerStyle.qml", picker)
2896+ style: theme.createStyleComponent("PickerStyle.qml", picker)
2897
2898 /*! \internal */
2899 property int __clickedIndex: -1
2900
2901=== modified file 'modules/Ubuntu/Components/Pickers/PickerDelegate.qml'
2902--- modules/Ubuntu/Components/Pickers/PickerDelegate.qml 2015-03-03 13:47:48 +0000
2903+++ modules/Ubuntu/Components/Pickers/PickerDelegate.qml 2015-04-17 15:45:47 +0000
2904@@ -1,5 +1,5 @@
2905 /*
2906- * Copyright 2013 Canonical Ltd.
2907+ * Copyright 2015 Canonical Ltd.
2908 *
2909 * This program is free software; you can redistribute it and/or modify
2910 * it under the terms of the GNU Lesser General Public License as published by
2911@@ -15,7 +15,7 @@
2912 */
2913
2914 import QtQuick 2.4
2915-import Ubuntu.Components 1.2
2916+import Ubuntu.Components 1.3
2917
2918 /*!
2919 \qmltype PickerDelegate
2920@@ -47,7 +47,7 @@
2921 internal.itemList.currentIndex = index;
2922 }
2923
2924- style: Theme.createStyleComponent("PickerDelegateStyle.qml", pickerDelegate)
2925+ style: theme.createStyleComponent("PickerDelegateStyle.qml", pickerDelegate)
2926
2927 QtObject {
2928 id: internal
2929
2930=== modified file 'modules/Ubuntu/Components/Pickers/PickerPanel.qml'
2931--- modules/Ubuntu/Components/Pickers/PickerPanel.qml 2015-03-03 13:47:48 +0000
2932+++ modules/Ubuntu/Components/Pickers/PickerPanel.qml 2015-04-17 15:45:47 +0000
2933@@ -1,5 +1,5 @@
2934 /*
2935- * Copyright 2014 Canonical Ltd.
2936+ * Copyright 2015 Canonical Ltd.
2937 *
2938 * This program is free software; you can redistribute it and/or modify
2939 * it under the terms of the GNU Lesser General Public License as published by
2940@@ -17,7 +17,7 @@
2941 pragma Singleton
2942 import QtQuick 2.4
2943 import QtQuick.Window 2.0
2944-import Ubuntu.Components 1.2
2945+import Ubuntu.Components 1.3
2946 import Ubuntu.Components.ListItems 1.0
2947 import Ubuntu.Components.Popups 1.0
2948
2949@@ -200,7 +200,7 @@
2950
2951 id: panel
2952 // no additional styling is needed
2953- color: Theme.palette.normal.overlay
2954+ color: theme.palette.normal.overlay
2955 width: parent.width
2956 height: Qt.inputMethod.keyboardRectangle.height > 0 ? Qt.inputMethod.keyboardRectangle.height : units.gu(26)
2957 y: parent.height
2958
2959=== modified file 'modules/Ubuntu/Components/Popups/ActionSelectionPopover.qml'
2960--- modules/Ubuntu/Components/Popups/ActionSelectionPopover.qml 2015-03-03 13:47:48 +0000
2961+++ modules/Ubuntu/Components/Popups/ActionSelectionPopover.qml 2015-04-17 15:45:47 +0000
2962@@ -1,5 +1,5 @@
2963 /*
2964- * Copyright 2012 Canonical Ltd.
2965+ * Copyright 2015 Canonical Ltd.
2966 *
2967 * This program is free software; you can redistribute it and/or modify
2968 * it under the terms of the GNU Lesser General Public License as published by
2969@@ -15,7 +15,7 @@
2970 */
2971
2972 import QtQuick 2.4
2973-import Ubuntu.Components 1.2
2974+import Ubuntu.Components 1.3
2975 import Ubuntu.Components.ListItems 1.0
2976
2977 /*!
2978@@ -116,7 +116,7 @@
2979 horizontalCenter: parent.horizontalCenter
2980 }
2981 wrapMode: Text.Wrap
2982- color: Theme.palette.normal.overlayText
2983+ color: theme.palette.normal.overlayText
2984 }
2985 /*! \internal */
2986 onTriggered: popover.hide()
2987
2988=== modified file 'modules/Ubuntu/Components/Popups/Dialog.qml'
2989--- modules/Ubuntu/Components/Popups/Dialog.qml 2015-03-03 13:47:48 +0000
2990+++ modules/Ubuntu/Components/Popups/Dialog.qml 2015-04-17 15:45:47 +0000
2991@@ -1,5 +1,5 @@
2992 /*
2993- * Copyright 2012 Canonical Ltd.
2994+ * Copyright 2015 Canonical Ltd.
2995 *
2996 * This program is free software; you can redistribute it and/or modify
2997 * it under the terms of the GNU Lesser General Public License as published by
2998@@ -15,7 +15,7 @@
2999 */
3000
3001 import QtQuick 2.4
3002-import Ubuntu.Components 1.2
3003+import Ubuntu.Components 1.3
3004 import "internalPopupUtils.js" as InternalPopupUtils
3005
3006 /*!
3007@@ -213,6 +213,6 @@
3008 }
3009 }
3010
3011- style: Theme.createStyleComponent("DialogForegroundStyle.qml", foreground)
3012+ style: theme.createStyleComponent("DialogForegroundStyle.qml", foreground)
3013 }
3014 }
3015
3016=== modified file 'modules/Ubuntu/Components/Popups/Popover.qml'
3017--- modules/Ubuntu/Components/Popups/Popover.qml 2015-03-05 09:35:06 +0000
3018+++ modules/Ubuntu/Components/Popups/Popover.qml 2015-04-17 15:45:47 +0000
3019@@ -1,5 +1,5 @@
3020 /*
3021- * Copyright 2012 Canonical Ltd.
3022+ * Copyright 2015 Canonical Ltd.
3023 *
3024 * This program is free software; you can redistribute it and/or modify
3025 * it under the terms of the GNU Lesser General Public License as published by
3026@@ -16,7 +16,7 @@
3027
3028 import QtQuick 2.4
3029 import "internalPopupUtils.js" as InternalPopupUtils
3030-import Ubuntu.Components 1.2
3031+import Ubuntu.Components 1.3
3032
3033 /*!
3034 \qmltype Popover
3035@@ -37,7 +37,7 @@
3036 import Ubuntu.Components.Popups 1.0
3037
3038 Rectangle {
3039- color: Theme.palette.normal.background
3040+ color: theme.palette.normal.background
3041 width: units.gu(80)
3042 height: units.gu(80)
3043 Component {
3044@@ -237,7 +237,7 @@
3045 signal showCompleted()
3046 signal hideCompleted()
3047
3048- style: Theme.createStyleComponent("PopoverForegroundStyle.qml", foreground)
3049+ style: theme.createStyleComponent("PopoverForegroundStyle.qml", foreground)
3050 }
3051
3052 QtObject {
3053
3054=== modified file 'modules/Ubuntu/Components/Popups/SheetBase.qml'
3055--- modules/Ubuntu/Components/Popups/SheetBase.qml 2015-03-03 13:47:48 +0000
3056+++ modules/Ubuntu/Components/Popups/SheetBase.qml 2015-04-17 15:45:47 +0000
3057@@ -1,5 +1,5 @@
3058 /*
3059- * Copyright 2012 Canonical Ltd.
3060+ * Copyright 2015 Canonical Ltd.
3061 *
3062 * This program is free software; you can redistribute it and/or modify
3063 * it under the terms of the GNU Lesser General Public License as published by
3064@@ -15,7 +15,7 @@
3065 */
3066
3067 import QtQuick 2.4
3068-import Ubuntu.Components 1.2
3069+import Ubuntu.Components 1.3
3070
3071 /*!
3072 \qmltype SheetBase
3073@@ -23,6 +23,7 @@
3074 \inqmlmodule Ubuntu.Components.Popups 1.0
3075 \ingroup ubuntu-popups
3076 \brief Parent class of different types of sheets. Not to be used directly.
3077+ \deprecated
3078
3079 Examples: See subclasses.
3080 \b{Sheets are deprecated. Consider using \l Dialog, \l Popover or \l PageStack instead.}
3081@@ -108,6 +109,6 @@
3082 }
3083 }
3084
3085- style: Theme.createStyleComponent("SheetForegroundStyle.qml", sheet)
3086+ style: theme.createStyleComponent("SheetForegroundStyle.qml", sheet)
3087 }
3088 }
3089
3090=== modified file 'modules/Ubuntu/Components/ProgressBar10.qml'
3091--- modules/Ubuntu/Components/ProgressBar10.qml 2015-03-03 13:47:48 +0000
3092+++ modules/Ubuntu/Components/ProgressBar10.qml 2015-04-17 15:45:47 +0000
3093@@ -1,5 +1,5 @@
3094 /*
3095- * Copyright 2013 Canonical Ltd.
3096+ * Copyright 2015 Canonical Ltd.
3097 *
3098 * This program is free software; you can redistribute it and/or modify
3099 * it under the terms of the GNU Lesser General Public License as published by
3100@@ -64,5 +64,5 @@
3101 */
3102 property real value: 0.5
3103
3104- style: Theme.createStyleComponent("ProgressBarStyle.qml", progressBar)
3105+ style: theme.createStyleComponent("ProgressBarStyle.qml", progressBar)
3106 }
3107
3108=== modified file 'modules/Ubuntu/Components/PullToRefresh.qml'
3109--- modules/Ubuntu/Components/PullToRefresh.qml 2015-03-03 13:47:48 +0000
3110+++ modules/Ubuntu/Components/PullToRefresh.qml 2015-04-17 15:45:47 +0000
3111@@ -1,5 +1,5 @@
3112 /*
3113- * Copyright 2014 Canonical Ltd.
3114+ * Copyright 2015 Canonical Ltd.
3115 *
3116 * This program is free software; you can redistribute it and/or modify
3117 * it under the terms of the GNU Lesser General Public License as published by
3118@@ -15,7 +15,7 @@
3119 */
3120
3121 import QtQuick 2.4
3122-import Ubuntu.Components 1.2
3123+import Ubuntu.Components 1.3
3124
3125 /*!
3126 \qmltype PullToRefresh
3127@@ -222,7 +222,7 @@
3128 */
3129 signal refresh()
3130
3131- style: Theme.createStyleComponent("PullToRefreshStyle.qml", control)
3132+ style: theme.createStyleComponent("PullToRefreshStyle.qml", control)
3133 implicitHeight: __styleInstance.implicitHeight
3134 anchors {
3135 left: target.left
3136
3137=== modified file 'modules/Ubuntu/Components/Scrollbar.qml'
3138--- modules/Ubuntu/Components/Scrollbar.qml 2015-03-03 13:47:48 +0000
3139+++ modules/Ubuntu/Components/Scrollbar.qml 2015-04-17 15:45:47 +0000
3140@@ -1,5 +1,5 @@
3141 /*
3142- * Copyright 2012 Canonical Ltd.
3143+ * Copyright 2015 Canonical Ltd.
3144 *
3145 * This program is free software; you can redistribute it and/or modify
3146 * it under the terms of the GNU Lesser General Public License as published by
3147@@ -15,6 +15,7 @@
3148 */
3149
3150 import QtQuick 2.4
3151+import Ubuntu.Components 1.3 as Toolkit
3152
3153 /*!
3154 \qmltype ScrollBar
3155@@ -58,7 +59,7 @@
3156 \endqml
3157 */
3158
3159-StyledItem {
3160+Toolkit.StyledItem {
3161 id: scrollbar
3162
3163 /*!
3164@@ -145,5 +146,5 @@
3165 }
3166 }
3167
3168- style: Theme.createStyleComponent("ScrollbarStyle.qml", scrollbar)
3169+ style: theme.createStyleComponent("ScrollbarStyle.qml", scrollbar)
3170 }
3171
3172=== modified file 'modules/Ubuntu/Components/Slider.qml'
3173--- modules/Ubuntu/Components/Slider.qml 2015-03-05 09:35:06 +0000
3174+++ modules/Ubuntu/Components/Slider.qml 2015-04-17 15:45:47 +0000
3175@@ -1,5 +1,5 @@
3176 /*
3177- * Copyright 2013 Canonical Ltd.
3178+ * Copyright 2015 Canonical Ltd.
3179 *
3180 * This program is free software; you can redistribute it and/or modify
3181 * it under the terms of the GNU Lesser General Public License as published by
3182@@ -18,6 +18,7 @@
3183
3184 import QtQuick 2.4
3185 import "mathUtils.js" as MathUtils
3186+import Ubuntu.Components 1.3 as Toolkit
3187
3188 /*!
3189 \qmltype Slider
3190@@ -45,7 +46,7 @@
3191 }
3192 \endqml
3193 */
3194-StyledItem {
3195+Toolkit.StyledItem {
3196 id: slider
3197
3198 /*!
3199@@ -206,5 +207,5 @@
3200 onLiveValueChanged: if (isPressed) slider.requestFocus(Qt.MouseFocusReason)
3201 }
3202
3203- style: Theme.createStyleComponent("SliderStyle.qml", slider)
3204+ style: theme.createStyleComponent("SliderStyle.qml", slider)
3205 }
3206
3207=== removed file 'modules/Ubuntu/Components/StyledItem.qml'
3208--- modules/Ubuntu/Components/StyledItem.qml 2015-03-03 13:47:48 +0000
3209+++ modules/Ubuntu/Components/StyledItem.qml 1970-01-01 00:00:00 +0000
3210@@ -1,71 +0,0 @@
3211-/*
3212- * Copyright 2013 Canonical Ltd.
3213- *
3214- * This program is free software; you can redistribute it and/or modify
3215- * it under the terms of the GNU Lesser General Public License as published by
3216- * the Free Software Foundation; version 3.
3217- *
3218- * This program is distributed in the hope that it will be useful,
3219- * but WITHOUT ANY WARRANTY; without even the implied warranty of
3220- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3221- * GNU Lesser General Public License for more details.
3222- *
3223- * You should have received a copy of the GNU Lesser General Public License
3224- * along with this program. If not, see <http://www.gnu.org/licenses/>.
3225- */
3226-
3227-import QtQuick 2.4
3228-import Ubuntu.Components 1.2
3229-
3230-/*!
3231- \qmlabstract StyledItem
3232- \inqmlmodule Ubuntu.Components 1.1
3233- \ingroup theming
3234- \brief The StyledItem class allows items to be styled by the theme.
3235-
3236- StyledItem provides facilities for making an Item stylable by the theme.
3237-
3238- In order to make an Item stylable by the theme, it is enough to make the Item
3239- inherit from StyledItem and set its \l style property to be the result of the
3240- appropriate call to Theme.createStyleComponent().
3241-
3242- Example definition of a custom Item MyItem.qml:
3243- \qml
3244- StyledItem {
3245- id: myItem
3246- style: Theme.createStyleComponent("MyItemStyle.qml", myItem)
3247- }
3248- \endqml
3249-
3250- The Component set on \l style is instantiated and placed below everything else
3251- that the Item contains.
3252-
3253- A reference to the Item being styled is accessible from the style and named
3254- 'styledItem'.
3255-
3256- \sa {Theme}
3257-*/
3258-StyledItemBase {
3259- id: styledItem
3260-
3261- /*!
3262- Component instantiated immediately and placed below everything else.
3263- */
3264- property Component style
3265-
3266- /*!
3267- \internal
3268- Instance of the \l style.
3269- */
3270- readonly property Item __styleInstance: styleLoader.status == Loader.Ready ? styleLoader.item : null
3271-
3272- implicitWidth: __styleInstance ? __styleInstance.implicitWidth : 0
3273- implicitHeight: __styleInstance ? __styleInstance.implicitHeight : 0
3274-
3275- Loader {
3276- id: styleLoader
3277- anchors.fill: parent
3278- sourceComponent: style
3279- property Item styledItem: styledItem
3280- }
3281-}
3282
3283=== modified file 'modules/Ubuntu/Components/Styles/PageHeadStyle.qml'
3284--- modules/Ubuntu/Components/Styles/PageHeadStyle.qml 2015-03-03 13:47:48 +0000
3285+++ modules/Ubuntu/Components/Styles/PageHeadStyle.qml 2015-04-17 15:45:47 +0000
3286@@ -1,5 +1,5 @@
3287 /*
3288- * Copyright 2014 Canonical Ltd.
3289+ * Copyright 2014-2015 Canonical Ltd.
3290 *
3291 * This program is free software; you can redistribute it and/or modify
3292 * it under the terms of the GNU Lesser General Public License as published by
3293@@ -25,8 +25,8 @@
3294 */
3295 Item {
3296 /*!
3297- The height of the headercontents, which is the full height of
3298- the header minus the separators shown at the bottom of it.
3299+ The height of the header excluding the height of the bottom divider and
3300+ the (optional) row that displays the sections.
3301 */
3302 property real contentHeight
3303
3304
3305=== modified file 'modules/Ubuntu/Components/Styles/PullToRefreshStyle.qml'
3306--- modules/Ubuntu/Components/Styles/PullToRefreshStyle.qml 2015-03-03 12:53:42 +0000
3307+++ modules/Ubuntu/Components/Styles/PullToRefreshStyle.qml 2015-04-17 15:45:47 +0000
3308@@ -24,7 +24,7 @@
3309
3310 The component defines the style API for the PullToRefresh component.
3311 */
3312-
3313+//![0]
3314 Item {
3315 /*!
3316 The property holds the style provided default content component. The value
3317@@ -46,3 +46,4 @@
3318 */
3319 property bool releaseToRefresh: false
3320 }
3321+//![0]
3322
3323=== modified file 'modules/Ubuntu/Components/Switch.qml'
3324--- modules/Ubuntu/Components/Switch.qml 2015-03-05 09:35:06 +0000
3325+++ modules/Ubuntu/Components/Switch.qml 2015-04-17 15:45:47 +0000
3326@@ -1,5 +1,5 @@
3327 /*
3328- * Copyright 2012 Canonical Ltd.
3329+ * Copyright 2015 Canonical Ltd.
3330 *
3331 * This program is free software; you can redistribute it and/or modify
3332 * it under the terms of the GNU Lesser General Public License as published by
3333@@ -40,5 +40,5 @@
3334 */
3335 CheckBox {
3336 id: switchItem
3337- style: Theme.createStyleComponent("SwitchStyle.qml", switchItem)
3338+ style: theme.createStyleComponent("SwitchStyle.qml", switchItem)
3339 }
3340
3341=== modified file 'modules/Ubuntu/Components/Tab.qml'
3342--- modules/Ubuntu/Components/Tab.qml 2015-03-03 13:47:48 +0000
3343+++ modules/Ubuntu/Components/Tab.qml 2015-04-17 15:45:47 +0000
3344@@ -1,5 +1,5 @@
3345 /*
3346- * Copyright 2012 Canonical Ltd.
3347+ * Copyright 2015 Canonical Ltd.
3348 *
3349 * This program is free software; you can redistribute it and/or modify
3350 * it under the terms of the GNU Lesser General Public License as published by
3351@@ -15,6 +15,7 @@
3352 */
3353
3354 import QtQuick 2.4
3355+import Ubuntu.Components 1.3 as Toolkit
3356
3357 /*!
3358 \qmltype Tab
3359@@ -137,7 +138,7 @@
3360 \internal
3361 */
3362 property alias __protected: internal
3363- QtObject {
3364+ Object {
3365 id: internal
3366 /*
3367 Specifies the index of the Tab in Tabs.
3368@@ -164,5 +165,22 @@
3369 component stack (children) change.
3370 */
3371 property bool removedFromTabs: false
3372+
3373+ /*!
3374+ Triggering this action will select the tab. Used by the tabs OverflowPanel.
3375+ */
3376+ property alias action: selectTabAction
3377+ Toolkit.Action {
3378+ id: selectTabAction
3379+ text: tab.title
3380+ objectName: "select_tab_"+index
3381+ iconSource: tab.iconSource
3382+ onTriggered: {
3383+ if (internal.index < 0) return;
3384+ if (tab.parentNode && tab.parentNode.hasOwnProperty("selectedTabIndex")) {
3385+ tab.parentNode.selectedTabIndex = internal.index;
3386+ }
3387+ }
3388+ }
3389 }
3390 }
3391
3392=== modified file 'modules/Ubuntu/Components/TabBar.qml'
3393--- modules/Ubuntu/Components/TabBar.qml 2015-03-03 13:47:48 +0000
3394+++ modules/Ubuntu/Components/TabBar.qml 2015-04-17 15:45:47 +0000
3395@@ -1,5 +1,5 @@
3396 /*
3397- * Copyright 2013 Canonical Ltd.
3398+ * Copyright 2015 Canonical Ltd.
3399 *
3400 * This program is free software; you can redistribute it and/or modify
3401 * it under the terms of the GNU Lesser General Public License as published by
3402@@ -15,6 +15,7 @@
3403 */
3404
3405 import QtQuick 2.4
3406+import Ubuntu.Components 1.3 as Toolkit
3407
3408 /*!
3409 \qmltype TabBar
3410@@ -24,7 +25,7 @@
3411 This component does not need to be instantiated by the developer, it is
3412 automatically created by the \l Tabs.
3413 */
3414-StyledItem {
3415+Toolkit.StyledItem {
3416 id: tabBar
3417
3418 /*!
3419@@ -97,7 +98,7 @@
3420 implicitHeight: units.gu(7.5)
3421 activeFocusOnPress: true
3422
3423- style: Theme.createStyleComponent("TabBarStyle.qml", tabBar)
3424+ style: theme.createStyleComponent("TabBarStyle.qml", tabBar)
3425
3426 QtObject {
3427 id: internal
3428
3429=== modified file 'modules/Ubuntu/Components/Tabs.qml'
3430--- modules/Ubuntu/Components/Tabs.qml 2015-03-05 09:35:06 +0000
3431+++ modules/Ubuntu/Components/Tabs.qml 2015-04-17 15:45:47 +0000
3432@@ -310,7 +310,10 @@
3433 if (tabBar && tabBar.__styleInstance && tabBar.__styleInstance.hasOwnProperty("sync")) {
3434 tabBar.__styleInstance.sync();
3435 }
3436- if (tabs.active && internal.header) {
3437+ if ((tabs.active && internal.header) &&
3438+ !(internal.header.config &&
3439+ internal.header.config.hasOwnProperty("locked") &&
3440+ internal.header.config.locked)) {
3441 internal.header.show();
3442 }
3443 // deprecated, however use it till we remove it completely
3444
3445=== modified file 'modules/Ubuntu/Components/TextArea.qml'
3446--- modules/Ubuntu/Components/TextArea.qml 2015-03-10 11:49:27 +0000
3447+++ modules/Ubuntu/Components/TextArea.qml 2015-04-17 15:45:47 +0000
3448@@ -1,5 +1,5 @@
3449 /*
3450- * Copyright 2012 Canonical Ltd.
3451+ * Copyright 2015 Canonical Ltd.
3452 *
3453 * This program is free software; you can redistribute it and/or modify
3454 * it under the terms of the GNU Lesser General Public License as published by
3455@@ -15,7 +15,7 @@
3456 */
3457
3458 import QtQuick 2.4
3459-import Ubuntu.Components 1.2 as Ubuntu
3460+import Ubuntu.Components 1.3 as Ubuntu
3461 import Ubuntu.Components.Popups 1.0
3462 import "mathUtils.js" as MathUtils
3463
3464@@ -92,7 +92,7 @@
3465 \note During text selection all interactive parent Flickables are turned off.
3466 */
3467
3468-StyledItem {
3469+Ubuntu.StyledItem {
3470 id: control
3471 implicitWidth: units.gu(30)
3472 implicitHeight: (autoSize) ? internal.minimumSize : internal.linesHeight(4)
3473@@ -104,7 +104,7 @@
3474 text input. This property allows to control the highlight separately from
3475 the focused behavior.
3476 */
3477- property bool highlighted: focus
3478+ property bool highlighted: activeFocus
3479 /*!
3480 Text that appears when there is no focus and no content in the component
3481 (hint text).
3482@@ -803,7 +803,7 @@
3483 }
3484 // hint is shown till user types something in the field
3485 visible: (editor.text == "") && !editor.inputMethodComposing
3486- color: Theme.palette.normal.backgroundText
3487+ color: theme.palette.normal.backgroundText
3488 font: editor.font
3489 elide: Text.ElideRight
3490 wrapMode: Text.WordWrap
3491@@ -873,5 +873,5 @@
3492 }
3493 }
3494
3495- style: Theme.createStyleComponent("TextAreaStyle.qml", control)
3496+ style: theme.createStyleComponent("TextAreaStyle.qml", control)
3497 }
3498
3499=== modified file 'modules/Ubuntu/Components/TextCursor.qml'
3500--- modules/Ubuntu/Components/TextCursor.qml 2015-03-18 15:51:07 +0000
3501+++ modules/Ubuntu/Components/TextCursor.qml 2015-04-17 15:45:47 +0000
3502@@ -1,5 +1,5 @@
3503 /*
3504- * Copyright 2012 Canonical Ltd.
3505+ * Copyright 2015 Canonical Ltd.
3506 *
3507 * This program is free software; you can redistribute it and/or modify
3508 * it under the terms of the GNU Lesser General Public License as published by
3509@@ -15,7 +15,7 @@
3510 */
3511
3512 import QtQuick 2.4
3513-import Ubuntu.Components 1.2 as Ubuntu
3514+import Ubuntu.Components 1.3 as Ubuntu
3515 import Ubuntu.Components.Popups 1.0
3516
3517 Ubuntu.StyledItem {
3518@@ -41,7 +41,7 @@
3519 handler.main.cursorDelegate :
3520 __styleInstance.cursorDelegate
3521
3522- style: Theme.createStyleComponent("TextCursorStyle.qml", cursorItem);
3523+ style: theme.createStyleComponent("TextCursorStyle.qml", cursorItem);
3524
3525 objectName: "textCursor"
3526 //Caret instance from the style.
3527
3528=== modified file 'modules/Ubuntu/Components/TextField.qml'
3529--- modules/Ubuntu/Components/TextField.qml 2015-03-10 11:49:27 +0000
3530+++ modules/Ubuntu/Components/TextField.qml 2015-04-17 15:45:47 +0000
3531@@ -1,5 +1,5 @@
3532 /*
3533- * Copyright 2012 Canonical Ltd.
3534+ * Copyright 2015 Canonical Ltd.
3535 *
3536 * This program is free software; you can redistribute it and/or modify
3537 * it under the terms of the GNU Lesser General Public License as published by
3538@@ -15,7 +15,7 @@
3539 */
3540
3541 import QtQuick 2.4
3542-import Ubuntu.Components 1.2 as Ubuntu
3543+import Ubuntu.Components 1.3 as Ubuntu
3544 import Ubuntu.Components.Popups 1.0
3545
3546 /*!
3547@@ -110,7 +110,7 @@
3548 text input. This property allows to control the highlight separately from
3549 the focused behavior.
3550 */
3551- property bool highlighted: focus
3552+ property bool highlighted: activeFocus
3553
3554 /*!
3555 Text that appears when there is no content in the component.
3556@@ -949,7 +949,7 @@
3557 }
3558 // hint is shown till user types something in the field
3559 visible: (editor.text == "") && !editor.inputMethodComposing
3560- color: Theme.palette.normal.backgroundText
3561+ color: theme.palette.normal.backgroundText
3562 font: editor.font
3563 elide: Text.ElideRight
3564 }
3565@@ -1019,5 +1019,5 @@
3566 cursorPosition = 0;
3567 }
3568
3569- style: Theme.createStyleComponent("TextFieldStyle.qml", control)
3570+ style: theme.createStyleComponent("TextFieldStyle.qml", control)
3571 }
3572
3573=== modified file 'modules/Ubuntu/Components/TextInputPopover.qml'
3574--- modules/Ubuntu/Components/TextInputPopover.qml 2015-03-10 11:49:27 +0000
3575+++ modules/Ubuntu/Components/TextInputPopover.qml 2015-04-17 15:45:47 +0000
3576@@ -1,5 +1,5 @@
3577 /*
3578- * Copyright 2012 Canonical Ltd.
3579+ * Copyright 2015 Canonical Ltd.
3580 *
3581 * This program is free software; you can redistribute it and/or modify
3582 * it under the terms of the GNU Lesser General Public License as published by
3583@@ -15,7 +15,7 @@
3584 */
3585
3586 import QtQuick 2.4
3587-import Ubuntu.Components 1.2
3588+import Ubuntu.Components 1.3
3589 import Ubuntu.Components.Popups 1.0
3590
3591 Popover {
3592@@ -96,7 +96,7 @@
3593 width: Math.max(units.gu(5), implicitWidth) + units.gu(2)
3594 height: units.gu(6)
3595 action: actions[modelData]
3596- style: Theme.createStyleComponent("ToolbarButtonStyle.qml", button)
3597+ style: theme.createStyleComponent("ToolbarButtonStyle.qml", button)
3598 }
3599 }
3600 }
3601
3602=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/BubbleShape.qml'
3603--- modules/Ubuntu/Components/Themes/Ambiance/BubbleShape.qml 2015-03-03 13:47:48 +0000
3604+++ modules/Ubuntu/Components/Themes/Ambiance/BubbleShape.qml 2015-04-17 15:45:47 +0000
3605@@ -1,5 +1,5 @@
3606 /*
3607- * Copyright 2013-2014 Canonical Ltd.
3608+ * Copyright 2015 Canonical Ltd.
3609 *
3610 * This program is free software; you can redistribute it and/or modify
3611 * it under the terms of the GNU Lesser General Public License as published by
3612@@ -15,7 +15,7 @@
3613 */
3614
3615 import QtQuick 2.4
3616-import Ubuntu.Components 1.2
3617+import Ubuntu.Components 1.3
3618
3619 Item {
3620 id: bubbleShape
3621@@ -28,7 +28,7 @@
3622 /*!
3623 The background color of the bubble.
3624 */
3625- property color color: square ? Theme.palette.normal.background : Theme.palette.normal.overlay
3626+ property color color: square ? theme.palette.normal.background : theme.palette.normal.overlay
3627
3628 property point target
3629 property string direction: "down"
3630@@ -111,7 +111,7 @@
3631 UbuntuShape {
3632 anchors.fill: parent
3633 borderSource: "none"
3634- color: Theme.palette.normal.overlay
3635+ color: theme.palette.normal.overlay
3636 image: bubbleShape.clipContent ? shapeSource : null
3637 visible: !square
3638 }
3639
3640=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/ButtonStyle.qml'
3641--- modules/Ubuntu/Components/Themes/Ambiance/ButtonStyle.qml 2015-03-03 13:47:48 +0000
3642+++ modules/Ubuntu/Components/Themes/Ambiance/ButtonStyle.qml 2015-04-17 15:45:47 +0000
3643@@ -103,7 +103,7 @@
3644 visible: stroke && strokeBorder.status == Image.Ready
3645
3646 property Item source: visible ? strokeBorder : null
3647- property color keyColorOut: stroke ? strokeColor : Qt.rgba(0.0, 0.0, 0.0, 0.0)
3648+ property color keyColorOut: stroke ? button.strokeColor : Qt.rgba(0.0, 0.0, 0.0, 0.0)
3649 property color keyColorIn: Qt.rgba(1.0, 1.0, 1.0, 1.0)
3650 property real threshold: 1.0
3651
3652@@ -135,8 +135,8 @@
3653 UbuntuShape {
3654 id: backgroundPressed
3655 anchors.fill: parent
3656- color: stroke ? strokeColor : background.color
3657- gradientColor: stroke ? strokeColor : background.gradientColor
3658+ color: stroke ? button.strokeColor : background.color
3659+ gradientColor: stroke ? button.strokeColor : background.gradientColor
3660 borderSource: "radius_pressed.sci"
3661 opacity: button.pressed ? 1.0 : 0.0
3662 Behavior on opacity {
3663@@ -159,7 +159,7 @@
3664 /* Pick either a clear or dark text color depending on the luminance of the
3665 background color to maintain good contrast (works in most cases)
3666 */
3667- textColor: ColorUtils.luminance(button.color) <= 0.85 && !(stroke && !pressed) ? "#FFFFFF" : "#888888"
3668+ textColor: ColorUtils.luminance(button.color) <= 0.85 && !(stroke && !button.pressed) ? "#FFFFFF" : "#888888"
3669 iconSource: button.iconSource
3670 iconPosition: button.iconPosition
3671 iconSize: units.gu(3)
3672
3673=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/CheckBoxStyle.qml'
3674--- modules/Ubuntu/Components/Themes/Ambiance/CheckBoxStyle.qml 2015-03-05 19:34:59 +0000
3675+++ modules/Ubuntu/Components/Themes/Ambiance/CheckBoxStyle.qml 2015-04-17 15:45:47 +0000
3676@@ -1,5 +1,5 @@
3677 /*
3678- * Copyright 2013 Canonical Ltd.
3679+ * Copyright 2015 Canonical Ltd.
3680 *
3681 * This program is free software; you can redistribute it and/or modify
3682 * it under the terms of the GNU Lesser General Public License as published by
3683@@ -15,7 +15,7 @@
3684 */
3685
3686 import QtQuick 2.4
3687-import Ubuntu.Components 1.2
3688+import Ubuntu.Components 1.3
3689
3690 Item {
3691 id: checkBoxStyle
3692@@ -28,9 +28,9 @@
3693 /*!
3694 The background color when the checkbox is not checked.
3695 */
3696- property color uncheckedBackgroundColor: Qt.rgba(Theme.palette.normal.foreground.r,
3697- Theme.palette.normal.foreground.g,
3698- Theme.palette.normal.foreground.b, 0.2)
3699+ property color uncheckedBackgroundColor: Qt.rgba(theme.palette.normal.foreground.r,
3700+ theme.palette.normal.foreground.g,
3701+ theme.palette.normal.foreground.b, 0.2)
3702
3703 /*!
3704 The background color when the checkbox is checked.
3705@@ -45,7 +45,7 @@
3706 /*!
3707 The color of the icon.
3708 */
3709- property color iconColor: Theme.palette.normal.foregroundText
3710+ property color iconColor: theme.palette.normal.foregroundText
3711
3712 /*!
3713 The padding between the icon and the border of the thumb.
3714
3715=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/DialerHandStyle.qml'
3716--- modules/Ubuntu/Components/Themes/Ambiance/DialerHandStyle.qml 2015-03-03 13:47:48 +0000
3717+++ modules/Ubuntu/Components/Themes/Ambiance/DialerHandStyle.qml 2015-04-17 15:45:47 +0000
3718@@ -1,5 +1,5 @@
3719 /*
3720- * Copyright 2013 Canonical Ltd.
3721+ * Copyright 2015 Canonical Ltd.
3722 *
3723 * This program is free software; you can redistribute it and/or modify
3724 * it under the terms of the GNU Lesser General Public License as published by
3725@@ -15,7 +15,7 @@
3726 */
3727
3728 import QtQuick 2.4
3729-import Ubuntu.Components 1.2
3730+import Ubuntu.Components 1.3
3731
3732 Item {
3733 // style API
3734@@ -52,7 +52,7 @@
3735 width: styledItem.hand.width
3736 height: styledItem.hand.height
3737 radius: units.gu(1)
3738- color: styledItem.hand.visible ? Theme.palette.normal.baseText : "#00000000"
3739+ color: styledItem.hand.visible ? theme.palette.normal.baseText : "#00000000"
3740 antialiasing: true
3741 }
3742
3743
3744=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/HeadDividerStyle.qml'
3745--- modules/Ubuntu/Components/Themes/Ambiance/HeadDividerStyle.qml 2015-03-03 12:53:42 +0000
3746+++ modules/Ubuntu/Components/Themes/Ambiance/HeadDividerStyle.qml 2015-04-17 15:45:47 +0000
3747@@ -15,6 +15,9 @@
3748 */
3749 import QtQuick 2.4
3750
3751+/*!
3752+ This component is DEPRECATED and no longer used. The divider is now a simple line.
3753+ */
3754 Item {
3755 id: dividerStyle
3756
3757
3758=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/HeaderStyle.qml'
3759--- modules/Ubuntu/Components/Themes/Ambiance/HeaderStyle.qml 2015-03-03 13:47:48 +0000
3760+++ modules/Ubuntu/Components/Themes/Ambiance/HeaderStyle.qml 2015-04-17 15:45:47 +0000
3761@@ -1,5 +1,5 @@
3762 /*
3763- * Copyright 2012 Canonical Ltd.
3764+ * Copyright 2015 Canonical Ltd.
3765 *
3766 * This program is free software; you can redistribute it and/or modify
3767 * it under the terms of the GNU Lesser General Public License as published by
3768@@ -14,7 +14,7 @@
3769 * along with this program. If not, see <http://www.gnu.org/licenses/>.
3770 */
3771 import QtQuick 2.4
3772-import Ubuntu.Components 1.2
3773+import Ubuntu.Components 1.3
3774
3775 Item {
3776 id: headerStyle
3777@@ -38,7 +38,7 @@
3778
3779 property int fontWeight: Font.Light
3780 property string fontSize: "x-large"
3781- property color textColor: Theme.palette.selected.backgroundText
3782+ property color textColor: theme.palette.selected.backgroundText
3783 property real textLeftMargin: units.gu(2)
3784
3785 implicitHeight: headerStyle.contentHeight + separator.height + separatorBottom.height
3786
3787=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/ListItemStyle.qml'
3788--- modules/Ubuntu/Components/Themes/Ambiance/ListItemStyle.qml 2015-03-03 12:53:42 +0000
3789+++ modules/Ubuntu/Components/Themes/Ambiance/ListItemStyle.qml 2015-04-17 15:45:47 +0000
3790@@ -1,5 +1,5 @@
3791 /*
3792- * Copyright 2014-2015 Canonical Ltd.
3793+ * Copyright 2015 Canonical Ltd.
3794 *
3795 * This program is free software; you can redistribute it and/or modify
3796 * it under the terms of the GNU Lesser General Public License as published by
3797@@ -15,20 +15,17 @@
3798 */
3799
3800 import QtQuick 2.4
3801-import Ubuntu.Components.Styles 1.2 as Styles
3802-import Ubuntu.Components 1.2
3803+import Ubuntu.Components.Styles 1.3 as Styles
3804+import Ubuntu.Components 1.3
3805
3806 Styles.ListItemStyle {
3807
3808 id: listItemStyle
3809- /*
3810- * Take over the ListItem's index context property as repeater used in panel
3811- * overrides the property.
3812- */
3813- readonly property int listItemIndex: index
3814
3815 // anchoring
3816 anchors {
3817+ // do not anchor fill
3818+ fill: undefined
3819 top: parent ? parent.top : undefined
3820 bottom: parent ? parent.bottom : undefined
3821 bottomMargin: styledItem.divider.visible ? styledItem.divider.height : 0
3822@@ -85,7 +82,7 @@
3823
3824 Rectangle {
3825 anchors.fill: parent
3826- color: Theme.palette.selected.background
3827+ color: theme.palette.selected.background
3828 visible: pressed
3829 }
3830
3831@@ -94,7 +91,7 @@
3832 height: parent.height
3833 sourceComponent: itemActions.delegate ? itemActions.delegate : defaultDelegate
3834 property Action action: modelData
3835- property int index: index
3836+ property int index: listItemIndex
3837 property bool pressed: actionButton.pressed
3838 onItemChanged: {
3839 // use action's objectName to identify the visualized action
3840@@ -168,7 +165,7 @@
3841 id: dragDelegate
3842 Item {
3843 id: dragPanel
3844- objectName: "drag_panel" + index
3845+ objectName: "drag_panel" + listItemIndex
3846 anchors.fill: parent ? parent : undefined
3847 Icon {
3848 objectName: "icon"
3849
3850=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/OverflowPanel.qml'
3851--- modules/Ubuntu/Components/Themes/Ambiance/OverflowPanel.qml 2015-03-03 13:47:48 +0000
3852+++ modules/Ubuntu/Components/Themes/Ambiance/OverflowPanel.qml 2015-04-17 15:45:47 +0000
3853@@ -1,5 +1,5 @@
3854 /*
3855- * Copyright 2014 Canonical Ltd.
3856+ * Copyright 2015 Canonical Ltd.
3857 *
3858 * This program is free software; you can redistribute it and/or modify
3859 * it under the terms of the GNU Lesser General Public License as published by
3860@@ -16,7 +16,125 @@
3861
3862 import QtQuick 2.4
3863 import Ubuntu.Components.Popups 1.0
3864+import Ubuntu.Components 1.3
3865+import Ubuntu.Components.ListItems 1.0 as ListItem
3866
3867+/*!
3868+ \internal
3869+ */
3870 Popover {
3871+ id: overflow
3872+
3873+ /*!
3874+ The background color of the tabs panel and the actions overflow panel.
3875+ */
3876+ property color backgroundColor: styledItem.panelColor
3877+
3878+ /*!
3879+ The background color of the tapped item in the panel.
3880+ */
3881+ property color highlightColor: theme.palette.selected.background
3882+
3883+ /*!
3884+ The foreground color (icon and text) of actions in the panel.
3885+ */
3886+ property color foregroundColor: theme.palette.selected.backgroundText
3887+
3888 property bool square: true
3889+ callerMargin: -units.gu(1) + units.dp(4)
3890+ contentWidth: units.gu(20)
3891+
3892+ /*!
3893+ False implies the model is a list of Actions.
3894+ True implies the model is a ListModel with a 'tab' role,
3895+ and false implies that the model is a list of actions.
3896+ */
3897+ property bool tabsOverflow: false
3898+ // FIXME: In the input, generate a list of actions from the Tabs
3899+ // so that we no longer need to make a distinction between the tabs ListModel
3900+ // and a list of Actions.
3901+ property var model: null
3902+
3903+ Binding {
3904+ target: overflow.__foreground.__styleInstance
3905+ property: "color"
3906+ value: overflow.backgroundColor
3907+ when: overflow.__foreground &&
3908+ overflow.__foreground.__styleInstance
3909+ }
3910+
3911+ Column {
3912+ anchors {
3913+ left: parent.left
3914+ top: parent.top
3915+ right: parent.right
3916+ }
3917+ Repeater {
3918+ id: overflowRepeater
3919+ model: overflow.model
3920+ AbstractButton {
3921+ action: overflow.tabsOverflow ? tab.__protected.action
3922+ : modelData
3923+
3924+ // These objectNames are used in the CPOs for header and tabs.
3925+ objectName: overflow.tabsOverflow ?
3926+ "tabButton" + index :
3927+ action.objectName + "_header_overflow_button"
3928+
3929+ // close after triggering the action.
3930+ onClicked: overflow.hide()
3931+
3932+ implicitHeight: units.gu(6) + bottomDividerLine.height
3933+ width: parent ? parent.width : units.gu(31)
3934+
3935+ Rectangle {
3936+ visible: parent.pressed
3937+ anchors {
3938+ left: parent.left
3939+ right: parent.right
3940+ top: parent.top
3941+ }
3942+ height: parent.height - bottomDividerLine.height
3943+ color: overflow.highlightColor
3944+ }
3945+
3946+ Icon {
3947+ id: actionIcon
3948+ visible: !overflow.tabsOverflow
3949+ source: action.iconSource
3950+ color: overflow.foregroundColor
3951+ anchors {
3952+ verticalCenter: parent.verticalCenter
3953+ verticalCenterOffset: units.dp(-1)
3954+ left: parent.left
3955+ leftMargin: units.gu(2)
3956+ }
3957+ width: units.gu(2)
3958+ height: units.gu(2)
3959+ opacity: action.enabled ? 1.0 : 0.5
3960+ }
3961+
3962+ Label {
3963+ anchors {
3964+ verticalCenter: parent.verticalCenter
3965+ verticalCenterOffset: units.dp(-1)
3966+ left: actionIcon.visible ? actionIcon.right : parent.left
3967+ leftMargin: units.gu(2)
3968+ right: parent.right
3969+ }
3970+ fontSize: overflow.tabsOverflow ? "medium" : "small"
3971+ elide: Text.ElideRight
3972+ text: action.text
3973+ color: overflow.foregroundColor
3974+ opacity: action.enabled ? 1.0 : 0.5
3975+ }
3976+
3977+ ListItem.ThinDivider {
3978+ id: bottomDividerLine
3979+ anchors.bottom: parent.bottom
3980+ visible: index !== overflowRepeater.count - 1
3981+ }
3982+ }
3983+ }
3984+ }
3985 }
3986
3987=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/PageHeadButton.qml'
3988--- modules/Ubuntu/Components/Themes/Ambiance/PageHeadButton.qml 2015-03-03 13:47:48 +0000
3989+++ modules/Ubuntu/Components/Themes/Ambiance/PageHeadButton.qml 2015-04-17 15:45:47 +0000
3990@@ -1,5 +1,5 @@
3991 /*
3992- * Copyright 2014 Canonical Ltd.
3993+ * Copyright 2015 Canonical Ltd.
3994 *
3995 * This program is free software; you can redistribute it and/or modify
3996 * it under the terms of the GNU Lesser General Public License as published by
3997@@ -15,12 +15,12 @@
3998 */
3999
4000 import QtQuick 2.4
4001-import Ubuntu.Components 1.2
4002+import Ubuntu.Components 1.3
4003
4004 AbstractButton {
4005 id: button
4006
4007- property real iconWidth: units.gu(2.5)
4008+ property real iconWidth: units.gu(2)
4009 property real iconHeight: iconWidth
4010
4011 width: visible ? units.gu(5) : 0
4012@@ -31,7 +31,7 @@
4013 Rectangle {
4014 visible: button.pressed
4015 anchors.fill: parent
4016- color: Theme.palette.selected.background
4017+ color: theme.palette.selected.background
4018 }
4019
4020 Icon {
4021
4022=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/PageHeadStyle.qml'
4023--- modules/Ubuntu/Components/Themes/Ambiance/PageHeadStyle.qml 2015-03-04 09:09:39 +0000
4024+++ modules/Ubuntu/Components/Themes/Ambiance/PageHeadStyle.qml 2015-04-17 15:45:47 +0000
4025@@ -1,5 +1,5 @@
4026 /*
4027- * Copyright 2014 Canonical Ltd.
4028+ * Copyright 2015 Canonical Ltd.
4029 *
4030 * This program is free software; you can redistribute it and/or modify
4031 * it under the terms of the GNU Lesser General Public License as published by
4032@@ -14,7 +14,7 @@
4033 * along with this program. If not, see <http://www.gnu.org/licenses/>.
4034 */
4035 import QtQuick 2.4
4036-import Ubuntu.Components 1.2
4037+import Ubuntu.Components 1.3
4038 import Ubuntu.Components.Popups 1.0
4039 import Ubuntu.Components.ListItems 1.0 as ListItem
4040 import Ubuntu.Components.Styles 1.2 as Style
4041@@ -22,9 +22,9 @@
4042 Style.PageHeadStyle {
4043 id: headerStyle
4044 objectName: "PageHeadStyle" // used in unit tests
4045- contentHeight: units.gu(7)
4046+ contentHeight: units.gu(6)
4047 fontWeight: Font.Light
4048- fontSize: "x-large"
4049+ fontSize: "large"
4050 textLeftMargin: units.gu(2)
4051 maximumNumberOfActions: 3
4052
4053@@ -38,25 +38,31 @@
4054 */
4055 property color titleColor: styledItem.config.foregroundColor
4056
4057+ // FIXME: When the three panel color properties below are removed,
4058+ // update unity8/Dash/PageHeader to use the new theming (currently
4059+ // in progress) to set these colors.
4060 /*!
4061+ \deprecated
4062 The background color of the tabs panel and the actions overflow panel.
4063 */
4064 property color panelBackgroundColor: styledItem.panelColor
4065
4066 /*!
4067- The background color of the tapped item in the panel.
4068- */
4069- property color panelHighlightColor: Theme.palette.selected.background
4070+ \deprecated
4071+ The background color of the tapped item in the panel.
4072+ */
4073+ property color panelHighlightColor: theme.palette.selected.background
4074
4075 /*!
4076- The foreground color (icon and text) of actions in the panel.
4077- */
4078- property color panelForegroundColor: Theme.palette.selected.backgroundText
4079+ \deprecated
4080+ The foreground color (icon and text) of actions in the panel.
4081+ */
4082+ property color panelForegroundColor: theme.palette.selected.backgroundText
4083
4084 /*!
4085 The text color of unselected sections and the section divider.
4086 */
4087- property color sectionColor: Theme.palette.selected.backgroundText
4088+ property color sectionColor: theme.palette.selected.backgroundText
4089
4090 /*!
4091 The text color of the selected section.
4092@@ -66,9 +72,14 @@
4093 /*!
4094 The background color of the pressed section.
4095 */
4096- property color sectionHighlightColor: Theme.palette.selected.background
4097-
4098- implicitHeight: headerStyle.contentHeight + divider.height
4099+ property color sectionHighlightColor: theme.palette.selected.background
4100+
4101+ implicitHeight: headerStyle.contentHeight + divider.height + sectionsItem.height
4102+
4103+ /*!
4104+ The height of the row displaying the sections, if sections are specified.
4105+ */
4106+ property real sectionsHeight: units.gu(4)
4107
4108 // FIXME: Workaround to get sectionsRepeater.count in autopilot tests,
4109 // see also FIXME in AppHeader where this property is used.
4110@@ -83,50 +94,57 @@
4111 // have a separator.
4112 property alias __separator_visible: divider.visible
4113
4114- StyledItem {
4115+ Rectangle {
4116 id: divider
4117 anchors {
4118+ left: parent.left
4119+ right: parent.right
4120 bottom: parent.bottom
4121+ }
4122+ height: units.dp(1)
4123+ color: styledItem.dividerColor
4124+ }
4125+
4126+ Item {
4127+ id: sectionsItem
4128+ anchors {
4129+ bottom: divider.top
4130 left: parent.left
4131 right: parent.right
4132 }
4133
4134- height: sectionsRow.visible ? units.gu(3) : units.gu(2)
4135-
4136- // separatorSource and separatorBottomSource are needed for the deprecated
4137- // HeadSeparatorImageStyle.
4138- property url separatorSource: headerStyle.separatorSource
4139- property url separatorBottomSource: headerStyle.separatorBottomSource
4140-
4141- // backgroundColor is used in the new HeadDividerStyle
4142- property color backgroundColor: styledItem.dividerColor
4143-
4144- style: Theme.createStyleComponent("HeadDividerStyle.qml", divider)
4145+ visible: sectionsItem.sections.model !== undefined
4146+ height: visible ? headerStyle.sectionsHeight : 0
4147
4148 property PageHeadSections sections: styledItem.config.sections
4149
4150 Row {
4151 id: sectionsRow
4152- anchors.centerIn: parent
4153+ anchors {
4154+ top: parent.top
4155+ bottom: parent.bottom
4156+ horizontalCenter: parent.horizontalCenter
4157+ }
4158 width: childrenRect.width
4159- height: parent.height
4160- enabled: divider.sections.enabled
4161- visible: divider.sections.model !== undefined
4162+ enabled: sectionsItem.sections.enabled
4163+ visible: sectionsItem.sections.model !== undefined
4164 opacity: enabled ? 1.0 : 0.5
4165
4166 Repeater {
4167 id: sectionsRepeater
4168- model: divider.sections.model
4169+ model: sectionsItem.sections.model
4170 objectName: "page_head_sections_repeater"
4171 AbstractButton {
4172 id: sectionButton
4173- anchors.verticalCenter: parent ? parent.verticalCenter : undefined
4174+ anchors {
4175+ top: parent.top
4176+ bottom: parent.bottom
4177+ }
4178 objectName: "section_button_" + index
4179 enabled: sectionsRow.enabled
4180- width: label.width + units.gu(4)
4181- height: sectionsRow.height + units.gu(2)
4182- property bool selected: index === divider.sections.selectedIndex
4183- onClicked: divider.sections.selectedIndex = index;
4184+ width: label.width + units.gu(4) // FIXME: expose spacing as style property
4185+ property bool selected: index === sectionsItem.sections.selectedIndex
4186+ onClicked: sectionsItem.sections.selectedIndex = index;
4187
4188 Rectangle {
4189 visible: parent.pressed
4190@@ -134,7 +152,6 @@
4191 verticalCenter: parent.verticalCenter
4192 left: parent.left
4193 right: parent.right
4194- rightMargin: verticalDividerLine.width
4195 }
4196 height: sectionsRow.height
4197 color: headerStyle.sectionHighlightColor
4198@@ -144,25 +161,24 @@
4199 id: label
4200 text: modelData
4201 fontSize: "small"
4202- anchors.centerIn: sectionButton
4203+ anchors.centerIn: parent
4204 horizontalAlignment: Text.AlignHCenter
4205 color: sectionButton.selected ?
4206 headerStyle.selectedSectionColor :
4207 headerStyle.sectionColor
4208 }
4209
4210- // vertical divider line
4211 Rectangle {
4212- id: verticalDividerLine
4213+ id: sectionLine
4214 anchors {
4215- verticalCenter: parent.verticalCenter
4216+ bottom: parent.bottom
4217+ left: parent.left
4218 right: parent.right
4219 }
4220- height: units.dp(10)
4221- width: units.dp(1)
4222- visible: index < sectionsRepeater.model.length - 1
4223- color: headerStyle.sectionColor
4224- opacity: 0.2
4225+ height: units.dp(2) // FIXME: Expose as style property
4226+ color: sectionButton.selected ?
4227+ headerStyle.selectedSectionColor :
4228+ styledItem.dividerColor
4229 }
4230 }
4231 }
4232@@ -341,67 +357,11 @@
4233 OverflowPanel {
4234 id: tabsPopover
4235 objectName: "tabsPopover"
4236- callerMargin: -units.gu(1) + units.dp(4)
4237- contentWidth: units.gu(20)
4238-
4239- Binding {
4240- target: tabsPopover.__foreground.__styleInstance
4241- property: "color"
4242- value: headerStyle.panelBackgroundColor
4243- when: tabsPopover.__foreground &&
4244- tabsPopover.__foreground.__styleInstance
4245- }
4246-
4247- Column {
4248- anchors {
4249- left: parent.left
4250- top: parent.top
4251- right: parent.right
4252- }
4253- Repeater {
4254- model: styledItem.tabsModel
4255- AbstractButton {
4256- objectName: "tabButton" + index
4257- onClicked: {
4258- styledItem.tabsModel.selectedIndex = index;
4259- tabsPopover.hide();
4260- }
4261- implicitHeight: units.gu(6) + bottomDividerLine.height
4262- width: parent ? parent.width : units.gu(31)
4263-
4264- Rectangle {
4265- visible: parent.pressed
4266- anchors {
4267- left: parent.left
4268- right: parent.right
4269- top: parent.top
4270- }
4271- height: parent.height - bottomDividerLine.height
4272- color: headerStyle.panelHighlightColor
4273- }
4274-
4275- Label {
4276- anchors {
4277- verticalCenter: parent.verticalCenter
4278- verticalCenterOffset: units.dp(-1)
4279- left: parent.left
4280- leftMargin: units.gu(2)
4281- right: parent.right
4282- }
4283- fontSize: "medium"
4284- elide: Text.ElideRight
4285- text: tab.title // FIXME: only "title" doesn't work with i18n.tr(). Why not?
4286- color: headerStyle.panelForegroundColor
4287- }
4288-
4289- ListItem.ThinDivider {
4290- id: bottomDividerLine
4291- anchors.bottom: parent.bottom
4292- visible: index < styledItem.tabsModel.count - 1
4293- }
4294- }
4295- }
4296- }
4297+ tabsOverflow: true
4298+ model: styledItem.tabsModel
4299+ backgroundColor: headerStyle.panelBackgroundColor
4300+ foregroundColor: headerStyle.panelForegroundColor
4301+ highlightColor: headerStyle.panelHighlightColor
4302 }
4303 }
4304 }
4305@@ -527,16 +487,10 @@
4306 OverflowPanel {
4307 id: actionsOverflowPopover
4308 objectName: "actions_overflow_popover"
4309- callerMargin: -units.gu(1) + units.dp(4)
4310- contentWidth: units.gu(20)
4311
4312- Binding {
4313- target: actionsOverflowPopover.__foreground.__styleInstance
4314- property: "color"
4315- value: headerStyle.panelBackgroundColor
4316- when: actionsOverflowPopover.__foreground &&
4317- actionsOverflowPopover.__foreground.__styleInstance
4318- }
4319+ backgroundColor: headerStyle.panelBackgroundColor
4320+ foregroundColor: headerStyle.panelForegroundColor
4321+ highlightColor: headerStyle.panelHighlightColor
4322
4323 // Ensure the popover closes when actions change and
4324 // the list item below may be destroyed before its
4325@@ -555,71 +509,9 @@
4326 }
4327 }
4328
4329- Column {
4330- anchors {
4331- left: parent.left
4332- top: parent.top
4333- right: parent.right
4334- }
4335- Repeater {
4336- id: overflowRepeater
4337- model: numberOfSlots.requested - numberOfSlots.used
4338- AbstractButton {
4339- action: actionsContainer.visibleActions[numberOfSlots.used + index]
4340- objectName: action.objectName + "_header_overflow_button"
4341- onClicked: actionsOverflowPopover.hide()
4342- implicitHeight: units.gu(6) + bottomDividerLine.height
4343- width: parent ? parent.width : units.gu(31)
4344-
4345- Rectangle {
4346- visible: parent.pressed
4347- anchors {
4348- left: parent.left
4349- right: parent.right
4350- top: parent.top
4351- }
4352- height: parent.height - bottomDividerLine.height
4353- color: headerStyle.panelHighlightColor
4354- }
4355-
4356- Icon {
4357- id: actionIcon
4358- source: action.iconSource
4359- color: headerStyle.panelForegroundColor
4360- anchors {
4361- verticalCenter: parent.verticalCenter
4362- verticalCenterOffset: units.dp(-1)
4363- left: parent.left
4364- leftMargin: units.gu(2)
4365- }
4366- width: units.gu(2)
4367- height: units.gu(2)
4368- opacity: action.enabled ? 1.0 : 0.5
4369- }
4370-
4371- Label {
4372- anchors {
4373- verticalCenter: parent.verticalCenter
4374- verticalCenterOffset: units.dp(-1)
4375- left: actionIcon.right
4376- leftMargin: units.gu(2)
4377- right: parent.right
4378- }
4379- fontSize: "small"
4380- elide: Text.ElideRight
4381- text: action.text
4382- color: headerStyle.panelForegroundColor
4383- opacity: action.enabled ? 1.0 : 0.5
4384- }
4385-
4386- ListItem.ThinDivider {
4387- id: bottomDividerLine
4388- anchors.bottom: parent.bottom
4389- visible: index !== overflowRepeater.count - 1
4390- }
4391- }
4392- }
4393- }
4394+ tabsOverflow: false
4395+ model: actionsContainer.visibleActions.slice(numberOfSlots.used,
4396+ numberOfSlots.requested)
4397 }
4398 }
4399 }
4400
4401=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/Palette.qml'
4402--- modules/Ubuntu/Components/Themes/Ambiance/Palette.qml 2015-03-03 13:47:48 +0000
4403+++ modules/Ubuntu/Components/Themes/Ambiance/Palette.qml 2015-04-17 15:45:47 +0000
4404@@ -19,7 +19,7 @@
4405 import Ubuntu.Components.Themes 0.1
4406
4407 Palette {
4408- normal: PaletteValues {
4409+ normal {
4410 background: "#EDEDED"
4411 backgroundText: "#81888888"
4412 base: Qt.rgba(0, 0, 0, 0.1)
4413@@ -28,13 +28,13 @@
4414 foregroundText: "#FFFFFF"
4415 overlay: "#FDFDFD"
4416 overlayText: UbuntuColors.lightGrey
4417- field: "#FAFAFA"
4418+ field: "lightgray"
4419 fieldText: UbuntuColors.darkGrey
4420 }
4421- selected: PaletteValues {
4422+ selected {
4423 background: Qt.rgba(0, 0, 0, 0.05)
4424 backgroundText: UbuntuColors.darkGrey
4425- selection: foreground // unused
4426+ selection: selected.foreground // unused
4427 foreground: Qt.rgba(UbuntuColors.blue.r, UbuntuColors.blue.g, UbuntuColors.blue.b, 0.2)
4428 foregroundText: UbuntuColors.darkGrey
4429 field: "#FFFFFF"
4430
4431=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/PickerStyle.qml'
4432--- modules/Ubuntu/Components/Themes/Ambiance/PickerStyle.qml 2015-03-03 13:47:48 +0000
4433+++ modules/Ubuntu/Components/Themes/Ambiance/PickerStyle.qml 2015-04-17 15:45:47 +0000
4434@@ -1,5 +1,5 @@
4435 /*
4436- * Copyright 2012 Canonical Ltd.
4437+ * Copyright 2015 Canonical Ltd.
4438 *
4439 * This program is free software; you can redistribute it and/or modify
4440 * it under the terms of the GNU Lesser General Public License as published by
4441@@ -15,7 +15,7 @@
4442 */
4443
4444 import QtQuick 2.4
4445-import Ubuntu.Components 1.2
4446+import Ubuntu.Components 1.3
4447 import Ubuntu.Components.ListItems 1.0
4448
4449 Item {
4450@@ -59,7 +59,7 @@
4451 UbuntuShape {
4452 anchors.fill: parent
4453 radius: "medium"
4454- color: Theme.palette.normal.overlay
4455+ color: theme.palette.normal.overlay
4456 image: shapeSource
4457 }
4458
4459
4460=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/ProgressBarStyle.qml'
4461--- modules/Ubuntu/Components/Themes/Ambiance/ProgressBarStyle.qml 2015-03-10 12:16:04 +0000
4462+++ modules/Ubuntu/Components/Themes/Ambiance/ProgressBarStyle.qml 2015-04-17 15:45:47 +0000
4463@@ -1,5 +1,5 @@
4464 /*
4465- * Copyright 2013 Canonical Ltd.
4466+ * Copyright 2015 Canonical Ltd.
4467 *
4468 * This program is free software; you can redistribute it and/or modify
4469 * it under the terms of the GNU Lesser General Public License as published by
4470@@ -15,15 +15,15 @@
4471 */
4472
4473 import QtQuick 2.4
4474-import Ubuntu.Components 1.2
4475+import Ubuntu.Components 1.3
4476
4477 Item {
4478 id: progressBarStyle
4479
4480 property color foregroundColor: UbuntuColors.orange
4481 property color foregroundTextColor: '#FFFFFF'
4482- property color backgroundColor: Theme.palette.normal.base
4483- property color backgroundTextColor: Theme.palette.normal.baseText
4484+ property color backgroundColor: theme.palette.normal.base
4485+ property color backgroundTextColor: theme.palette.normal.baseText
4486
4487 property var progressBar: styledItem
4488
4489
4490=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/ScrollbarStyle.qml'
4491--- modules/Ubuntu/Components/Themes/Ambiance/ScrollbarStyle.qml 2015-03-03 13:47:48 +0000
4492+++ modules/Ubuntu/Components/Themes/Ambiance/ScrollbarStyle.qml 2015-04-17 15:45:47 +0000
4493@@ -1,5 +1,5 @@
4494 /*
4495- * Copyright 2012 Canonical Ltd.
4496+ * Copyright 2015 Canonical Ltd.
4497 *
4498 * This program is free software; you can redistribute it and/or modify
4499 * it under the terms of the GNU Lesser General Public License as published by
4500@@ -15,7 +15,7 @@
4501 */
4502
4503 import QtQuick 2.4
4504-import Ubuntu.Components 1.2
4505+import Ubuntu.Components 1.3
4506
4507 /*
4508 The visuals handle both active and passive modes. This behavior is driven yet by
4509@@ -70,7 +70,7 @@
4510 property PropertyAnimation thumbConnectorFading: UbuntuNumberAnimation { duration: UbuntuAnimation.SnapDuration }
4511 property PropertyAnimation thumbFading: UbuntuNumberAnimation { duration: UbuntuAnimation.SnapDuration }
4512
4513- property color sliderColor: Theme.palette.normal.base
4514+ property color sliderColor: theme.palette.normal.base
4515 property real sliderRadius: units.gu(0.5)
4516 property color thumbConnectorColor: "white"
4517 property url forwardThumbReleased: (styledItem.align === Qt.AlignLeading || styledItem.align === Qt.AlignTrailing) ? "artwork/ScrollbarBottomIdle.png" : "artwork/ScrollbarRightIdle.png"
4518
4519=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/SliderStyle.qml'
4520--- modules/Ubuntu/Components/Themes/Ambiance/SliderStyle.qml 2015-03-20 01:10:48 +0000
4521+++ modules/Ubuntu/Components/Themes/Ambiance/SliderStyle.qml 2015-04-17 15:45:47 +0000
4522@@ -1,5 +1,5 @@
4523 /*
4524- * Copyright 2013 Canonical Ltd.
4525+ * Copyright 2015 Canonical Ltd.
4526 *
4527 * This program is free software; you can redistribute it and/or modify
4528 * it under the terms of the GNU Lesser General Public License as published by
4529@@ -15,7 +15,7 @@
4530 */
4531
4532 import QtQuick 2.4
4533-import Ubuntu.Components 1.2
4534+import Ubuntu.Components 1.3
4535
4536 /*
4537 The default slider style consists of a bar and a thumb shape.
4538@@ -27,7 +27,7 @@
4539 id: sliderStyle
4540
4541 property color foregroundColor: UbuntuColors.orange
4542- property color backgroundColor: Theme.palette.normal.base
4543+ property color backgroundColor: theme.palette.normal.base
4544
4545 property real thumbSpacing: units.gu(0)
4546 property Item bar: background
4547@@ -81,7 +81,7 @@
4548 width: units.gu(2)
4549 height: units.gu(2)
4550 opacity: 0.97
4551- color: Theme.palette.normal.overlay
4552+ color: theme.palette.normal.overlay
4553 }
4554
4555 BubbleShape {
4556@@ -117,7 +117,7 @@
4557 anchors.centerIn: parent
4558 text: styledItem.formatValue(SliderUtils.liveValue(styledItem))
4559 fontSize: "large"
4560- color: Theme.palette.normal.overlayText
4561+ color: theme.palette.normal.overlayText
4562 }
4563 }
4564 }
4565
4566=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/SwitchStyle.qml'
4567--- modules/Ubuntu/Components/Themes/Ambiance/SwitchStyle.qml 2015-03-03 13:47:48 +0000
4568+++ modules/Ubuntu/Components/Themes/Ambiance/SwitchStyle.qml 2015-04-17 15:45:47 +0000
4569@@ -1,5 +1,5 @@
4570 /*
4571- * Copyright 2013 Canonical Ltd.
4572+ * Copyright 2015 Canonical Ltd.
4573 *
4574 * This program is free software; you can redistribute it and/or modify
4575 * it under the terms of the GNU Lesser General Public License as published by
4576@@ -15,7 +15,7 @@
4577 */
4578
4579 import QtQuick 2.4
4580-import Ubuntu.Components 1.2
4581+import Ubuntu.Components 1.3
4582
4583 Item {
4584 id: switchStyle
4585@@ -39,7 +39,7 @@
4586 /*!
4587 The background color of the switch.
4588 */
4589- property color backgroundColor: Theme.palette.normal.base
4590+ property color backgroundColor: theme.palette.normal.base
4591
4592 /*!
4593 The background color of the thumb when the switch is checked.
4594@@ -54,12 +54,12 @@
4595 /*!
4596 The foreground color of the icon that is currently selected.
4597 */
4598- property color selectedIconColor: Theme.palette.normal.foregroundText
4599+ property color selectedIconColor: theme.palette.normal.foregroundText
4600
4601 /*!
4602 The color of the icon that is not currently selected.
4603 */
4604- property color unselectedIconColor: Theme.palette.normal.backgroundText
4605+ property color unselectedIconColor: theme.palette.normal.backgroundText
4606
4607 /*!
4608 The source of the selected icon when the switch is checked.
4609
4610=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml'
4611--- modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml 2015-03-03 13:47:48 +0000
4612+++ modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml 2015-04-17 15:45:47 +0000
4613@@ -1,5 +1,5 @@
4614 /*
4615- * Copyright 2012 Canonical Ltd.
4616+ * Copyright 2015 Canonical Ltd.
4617 *
4618 * This program is free software; you can redistribute it and/or modify
4619 * it under the terms of the GNU Lesser General Public License as published by
4620@@ -15,7 +15,7 @@
4621 */
4622
4623 import QtQuick 2.4
4624-import Ubuntu.Components 1.2
4625+import Ubuntu.Components 1.3
4626
4627 Item {
4628 id: tabBarStyle
4629@@ -25,8 +25,8 @@
4630 readonly property bool pressed: mouseArea.interacting
4631
4632 // styling properties, public API
4633- property color headerTextColor: Theme.palette.normal.backgroundText
4634- property color headerTextSelectedColor: Theme.palette.selected.backgroundText
4635+ property color headerTextColor: theme.palette.normal.backgroundText
4636+ property color headerTextSelectedColor: theme.palette.selected.backgroundText
4637
4638 // Don't start transitions because of updates to selectionMode before styledItem is completed.
4639 // This fixes bug #1246792: "Disable tabs scrolling animations at startup"
4640@@ -42,7 +42,7 @@
4641
4642 property string headerFontSize: "x-large"
4643 property int headerTextStyle: Text.Normal
4644- property color headerTextStyleColor: Theme.palette.normal.backgroundText
4645+ property color headerTextStyleColor: theme.palette.normal.backgroundText
4646 property int headerFontWeight: Font.Light
4647 property real headerTextLeftMargin: units.gu(2)
4648 property real headerTextRightMargin: units.gu(2)
4649
4650=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/TextAreaStyle.qml'
4651--- modules/Ubuntu/Components/Themes/Ambiance/TextAreaStyle.qml 2015-03-10 11:49:27 +0000
4652+++ modules/Ubuntu/Components/Themes/Ambiance/TextAreaStyle.qml 2015-04-17 15:45:47 +0000
4653@@ -1,5 +1,5 @@
4654 /*
4655- * Copyright 2012 Canonical Ltd.
4656+ * Copyright 2015 Canonical Ltd.
4657 *
4658 * This program is free software; you can redistribute it and/or modify
4659 * it under the terms of the GNU Lesser General Public License as published by
4660@@ -15,7 +15,7 @@
4661 */
4662
4663 import QtQuick 2.4
4664-import Ubuntu.Components 1.2
4665+import Ubuntu.Components 1.3
4666
4667 // frame
4668 // FIXME: stabilize API
4669@@ -25,13 +25,13 @@
4670 // FIXME: needs type checking in themes to define the proper type to be used
4671 // if color type is used, alpha value gets lost
4672
4673- property color color: (styledItem.focus || styledItem.highlighted) ? Theme.palette.selected.fieldText : Theme.palette.normal.fieldText
4674- property color selectedTextColor: Theme.palette.selected.foregroundText
4675- property color selectionColor: Theme.palette.selected.foreground
4676+ property color color: (styledItem.activeFocus || styledItem.highlighted) ? theme.palette.selected.fieldText : theme.palette.normal.fieldText
4677+ property color selectedTextColor: theme.palette.selected.foregroundText
4678+ property color selectionColor: theme.palette.selected.foreground
4679 /*!
4680 Background fill color
4681 */
4682- property color backgroundColor: (styledItem.focus || styledItem.highlighted) ? Theme.palette.selected.field : Theme.palette.normal.field
4683+ property color backgroundColor: (styledItem.activeFocus || styledItem.highlighted) ? theme.palette.selected.field : theme.palette.normal.field
4684 property color errorColor: UbuntuColors.orange
4685
4686 /*!
4687
4688=== modified file 'modules/Ubuntu/Components/Themes/Ambiance/ToolbarStyle.qml'
4689--- modules/Ubuntu/Components/Themes/Ambiance/ToolbarStyle.qml 2015-03-03 13:47:48 +0000
4690+++ modules/Ubuntu/Components/Themes/Ambiance/ToolbarStyle.qml 2015-04-17 15:45:47 +0000
4691@@ -1,5 +1,5 @@
4692 /*
4693- * Copyright 2012 Canonical Ltd.
4694+ * Copyright 2015 Canonical Ltd.
4695 *
4696 * This program is free software; you can redistribute it and/or modify
4697 * it under the terms of the GNU Lesser General Public License as published by
4698@@ -14,12 +14,12 @@
4699 * along with this program. If not, see <http://www.gnu.org/licenses/>.
4700 */
4701 import QtQuick 2.4
4702-import Ubuntu.Components 1.2
4703+import Ubuntu.Components 1.3
4704
4705 Item {
4706 id: visuals
4707 // styling properties
4708- property color color: Theme.palette.normal.overlay
4709+ property color color: theme.palette.normal.overlay
4710
4711 anchors.fill: parent
4712
4713
4714=== modified file 'modules/Ubuntu/Components/Themes/Palette.qml'
4715--- modules/Ubuntu/Components/Themes/Palette.qml 2015-03-03 13:47:48 +0000
4716+++ modules/Ubuntu/Components/Themes/Palette.qml 2015-04-17 15:45:47 +0000
4717@@ -1,5 +1,5 @@
4718 /*
4719- * Copyright 2013 Canonical Ltd.
4720+ * Copyright 2015 Canonical Ltd.
4721 *
4722 * This program is free software; you can redistribute it and/or modify
4723 * it under the terms of the GNU Lesser General Public License as published by
4724@@ -18,9 +18,9 @@
4725
4726 /*!
4727 \qmltype Palette
4728- \inqmlmodule Ubuntu.Components.Themes 0.1
4729- \ingroup theming
4730- \brief Palette of colors from the theme that widgets use to draw themselves.
4731+ \inqmlmodule Ubuntu.Components.Themes 1.0
4732+ \ingroup theme-module
4733+ \brief Provides the palette of colors from the theme that widgets use to draw themselves.
4734
4735 Palette provides access to colors defined by the current theme. The actual
4736 color palette to use depends on the state of the widget being drawn.
4737@@ -37,11 +37,11 @@
4738 \qml
4739 Item {
4740 Rectangle {
4741- color: Theme.palette.normal.base
4742+ color: theme.palette.normal.base
4743 }
4744
4745 Text {
4746- color: Theme.palette.normal.baseText
4747+ color: theme.palette.normal.baseText
4748 }
4749 }
4750 \endqml
4751@@ -50,10 +50,10 @@
4752 /*!
4753 Color palette to use when the widget is not in any particular state.
4754 */
4755- property PaletteValues normal
4756+ property PaletteValues normal: PaletteValues{}
4757 /*!
4758 Color palette to use when the widget is selected, for example when
4759 a tab is the current one.
4760 */
4761- property PaletteValues selected
4762+ property PaletteValues selected: PaletteValues{}
4763 }
4764
4765=== modified file 'modules/Ubuntu/Components/Themes/PaletteValues.qml'
4766--- modules/Ubuntu/Components/Themes/PaletteValues.qml 2015-03-03 13:47:48 +0000
4767+++ modules/Ubuntu/Components/Themes/PaletteValues.qml 2015-04-17 15:45:47 +0000
4768@@ -18,8 +18,8 @@
4769
4770 /*!
4771 \qmltype PaletteValues
4772- \inqmlmodule Ubuntu.Components.Themes 0.1
4773- \ingroup theming
4774+ \inqmlmodule Ubuntu.Components.Themes 1.0
4775+ \ingroup theme-module
4776 \brief Color values used for a given widget state.
4777 */
4778 QtObject {
4779
4780=== modified file 'modules/Ubuntu/Components/Themes/SuruDark/MainViewStyle.qml'
4781--- modules/Ubuntu/Components/Themes/SuruDark/MainViewStyle.qml 2015-03-03 13:47:48 +0000
4782+++ modules/Ubuntu/Components/Themes/SuruDark/MainViewStyle.qml 2015-04-17 15:45:47 +0000
4783@@ -1,5 +1,5 @@
4784 /*
4785- * Copyright 2013 Canonical Ltd.
4786+ * Copyright 2015 Canonical Ltd.
4787 *
4788 * This program is free software; you can redistribute it and/or modify
4789 * it under the terms of the GNU Lesser General Public License as published by
4790@@ -13,10 +13,11 @@
4791 * You should have received a copy of the GNU Lesser General Public License
4792 * along with this program. If not, see <http://www.gnu.org/licenses/>.
4793 */
4794-
4795+//![0]
4796 import QtQuick 2.4
4797 import Ubuntu.Components.Themes.Ambiance 0.1
4798
4799 MainViewStyle {
4800 backgroundSource: ""
4801 }
4802+//![0]
4803
4804=== modified file 'modules/Ubuntu/Components/Themes/SuruDark/Palette.qml'
4805--- modules/Ubuntu/Components/Themes/SuruDark/Palette.qml 2015-03-03 13:47:48 +0000
4806+++ modules/Ubuntu/Components/Themes/SuruDark/Palette.qml 2015-04-17 15:45:47 +0000
4807@@ -1,5 +1,5 @@
4808 /*
4809- * Copyright 2013 Canonical Ltd.
4810+ * Copyright 2015 Canonical Ltd.
4811 *
4812 * This program is free software; you can redistribute it and/or modify
4813 * it under the terms of the GNU Lesser General Public License as published by
4814@@ -14,12 +14,13 @@
4815 * along with this program. If not, see <http://www.gnu.org/licenses/>.
4816 */
4817
4818+//![0]
4819 import QtQuick 2.4
4820-import Ubuntu.Components 1.2
4821-import Ubuntu.Components.Themes 0.1
4822+import Ubuntu.Components 1.3
4823+import Ubuntu.Components.Themes 1.0
4824
4825 Palette {
4826- normal: PaletteValues {
4827+ normal {
4828 background: "#221E1C"
4829 backgroundText: "#33F3F3E7"
4830 base: "#19000000"
4831@@ -31,8 +32,8 @@
4832 field: "#19000000"
4833 fieldText: "#7F7F7F7F"
4834 }
4835- selected: PaletteValues {
4836- background: "#88D6D6D6" // FIXME: not from design
4837+ selected {
4838+ background: "#88D6D6D6"
4839 backgroundText: "#FFFFFF"
4840 selection: Qt.rgba(UbuntuColors.blue.r, UbuntuColors.blue.g, UbuntuColors.blue.b, 0.2)
4841 foreground: UbuntuColors.orange
4842@@ -41,3 +42,4 @@
4843 fieldText: "#888888"
4844 }
4845 }
4846+//![0]
4847
4848=== modified file 'modules/Ubuntu/Components/Themes/qmldir'
4849--- modules/Ubuntu/Components/Themes/qmldir 2013-07-01 06:32:40 +0000
4850+++ modules/Ubuntu/Components/Themes/qmldir 2015-04-17 15:45:47 +0000
4851@@ -1,3 +1,7 @@
4852 module Ubuntu.Components.Themes
4853 Palette 0.1 Palette.qml
4854 PaletteValues 0.1 PaletteValues.qml
4855+
4856+#version 1.0
4857+Palette 1.0 Palette.qml
4858+PaletteValues 1.0 PaletteValues.qml
4859
4860=== modified file 'modules/Ubuntu/Components/Toolbar.qml'
4861--- modules/Ubuntu/Components/Toolbar.qml 2015-03-03 13:47:48 +0000
4862+++ modules/Ubuntu/Components/Toolbar.qml 2015-04-17 15:45:47 +0000
4863@@ -1,5 +1,5 @@
4864 /*
4865- * Copyright (C) 2013 Canonical Ltd.
4866+ * Copyright (C) 2015 Canonical Ltd.
4867 *
4868 * This program is free software; you can redistribute it and/or modify
4869 * it under the terms of the GNU Lesser General Public License as published by
4870@@ -15,6 +15,7 @@
4871 */
4872
4873 import QtQuick 2.4
4874+import Ubuntu.Components 1.3 as Toolkit
4875
4876 /*!
4877 \internal
4878@@ -117,7 +118,7 @@
4879 }
4880 }
4881
4882- StyledItem {
4883+ Toolkit.StyledItem {
4884 // FIXME:
4885 // All theming items go into the background because only the children
4886 // of the Panel are being shown/hidden while the toolbar
4887@@ -134,7 +135,7 @@
4888 property bool opened: toolbar.opened
4889 property bool animating: toolbar.animating
4890
4891- style: Theme.createStyleComponent("ToolbarStyle.qml", background)
4892+ style: theme.createStyleComponent("ToolbarStyle.qml", background)
4893 }
4894
4895 Item {
4896
4897=== modified file 'modules/Ubuntu/Components/ToolbarButton.qml'
4898--- modules/Ubuntu/Components/ToolbarButton.qml 2015-03-03 13:47:48 +0000
4899+++ modules/Ubuntu/Components/ToolbarButton.qml 2015-04-17 15:45:47 +0000
4900@@ -1,5 +1,5 @@
4901 /*
4902- * Copyright (C) 2013 Canonical Ltd.
4903+ * Copyright (C) 2015 Canonical Ltd.
4904 *
4905 * This program is free software; you can redistribute it and/or modify
4906 * it under the terms of the GNU Lesser General Public License as published by
4907@@ -83,5 +83,5 @@
4908 height: parent ? parent.height : undefined
4909 width: units.gu(5)
4910
4911- style: Theme.createStyleComponent("ToolbarButtonStyle.qml", toolbarButton)
4912+ style: theme.createStyleComponent("ToolbarButtonStyle.qml", toolbarButton)
4913 }
4914
4915=== added file 'modules/Ubuntu/Components/pageUtils.js'
4916--- modules/Ubuntu/Components/pageUtils.js 1970-01-01 00:00:00 +0000
4917+++ modules/Ubuntu/Components/pageUtils.js 2015-04-17 15:45:47 +0000
4918@@ -0,0 +1,47 @@
4919+/*
4920+ * Copyright 2015 Canonical Ltd.
4921+ *
4922+ * This program is free software; you can redistribute it and/or modify
4923+ * it under the terms of the GNU Lesser General Public License as published by
4924+ * the Free Software Foundation; version 3.
4925+ *
4926+ * This program is distributed in the hope that it will be useful,
4927+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
4928+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
4929+ * GNU Lesser General Public License for more details.
4930+ *
4931+ * You should have received a copy of the GNU Lesser General Public License
4932+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
4933+ */
4934+
4935+/*!
4936+ Return true if the object is a Flickable that can be flicked in vertical direction.
4937+ */
4938+function isVerticalFlickable(object) {
4939+ if (object && object.hasOwnProperty("flickableDirection") && object.hasOwnProperty("contentHeight")) {
4940+ var direction = object.flickableDirection;
4941+ if ( ((direction === Flickable.AutoFlickDirection) && (object.contentHeight !== object.height) )
4942+ || direction === Flickable.VerticalFlick
4943+ || direction === Flickable.HorizontalAndVerticalFlick) {
4944+ return true;
4945+ }
4946+ }
4947+ return false;
4948+}
4949+
4950+/*!
4951+ Return the first child of the item that is flickable in the vertical direction.
4952+ */
4953+function getFlickableChild(item) {
4954+ if (item && item.hasOwnProperty("children")) {
4955+ for (var i=0; i < item.children.length; i++) {
4956+ var child = item.children[i];
4957+ if (isVerticalFlickable(child)) {
4958+ if (child.anchors.top === page.top || child.anchors.fill === page) {
4959+ return item.children[i];
4960+ }
4961+ }
4962+ }
4963+ }
4964+ return null;
4965+}
4966
4967=== modified file 'modules/Ubuntu/Components/plugin/plugin.cpp'
4968--- modules/Ubuntu/Components/plugin/plugin.cpp 2015-03-04 19:07:58 +0000
4969+++ modules/Ubuntu/Components/plugin/plugin.cpp 2015-04-17 15:45:47 +0000
4970@@ -1,5 +1,5 @@
4971 /*
4972- * Copyright 2012-2014 Canonical Ltd.
4973+ * Copyright 2015 Canonical Ltd.
4974 *
4975 * This program is free software; you can redistribute it and/or modify
4976 * it under the terms of the GNU Lesser General Public License as published by
4977@@ -13,7 +13,6 @@
4978 * You should have received a copy of the GNU Lesser General Public License
4979 * along with this program. If not, see <http://www.gnu.org/licenses/>.
4980 *
4981- * Author: Juhapekka Piiroinen <juhapekka.piiroinen@canonical.com>
4982 */
4983
4984 #include <QtQuick/private/qquickimagebase_p.h>
4985@@ -23,6 +22,7 @@
4986
4987 #include "plugin.h"
4988 #include "uctheme.h"
4989+#include "ucdeprecatedtheme.h"
4990
4991 #include <QtQml/QQmlContext>
4992 #include "i18n.h"
4993@@ -135,7 +135,7 @@
4994 qmlRegisterType<UCAction>(uri, major, minor, "Action");
4995 qmlRegisterType<UCActionContext>(uri, major, minor, "ActionContext");
4996 qmlRegisterType<UCActionManager>(uri, major, minor, "ActionManager");
4997- qmlRegisterType<UCStyledItemBase>(uri, major, minor, "StyledItemBase");
4998+ qmlRegisterType<UCStyledItemBase>(uri, major, minor, "StyledItem");
4999 qmlRegisterUncreatableType<UbuntuI18n>(uri, major, minor, "i18n", "Singleton object");
5000 qmlRegisterExtendedType<QQuickImageBase, UCQQuickImageExtension>(uri, major, minor, "QQuickImageBase");
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches

to status/vote changes: