on xenial help sign in
Merged with trunk.
e74d03aLeo Arias
data/unity8.conf+1
@@ -24,6 +24,7 @@ pre-start script
24 # Point all future jobs in this session to our Mir socket instead of
24 # Point all future jobs in this session to our Mir socket instead of
25 # unity-system-compositor's socket.
25 # unity-system-compositor's socket.
26 initctl set-env --global MIR_SOCKET=$MIR_SERVER_FILE
26 initctl set-env --global MIR_SOCKET=$MIR_SERVER_FILE
27+ gdbus call --session --dest org.freedesktop.DBus --object-path /org/freedesktop/DBus --method org.freedesktop.DBus.UpdateActivationEnvironment "@a{ss} {'MIR_SOCKET': '$MIR_SERVER_FILE'}"
27 fi
28 fi
28end script
29end script
29
30
debian/control+1
@@ -72,6 +72,7 @@ Package: unity8
72Architecture: any
72Architecture: any
73Provides: indicator-renderer,
73Provides: indicator-renderer,
74Depends: gsettings-desktop-schemas,
74Depends: gsettings-desktop-schemas,
75+ libglib2.0-bin,
75 qmenumodel-qml (>= 0.2.7),
76 qmenumodel-qml (>= 0.2.7),
76 qtdeclarative5-dee-plugin,
77 qtdeclarative5-dee-plugin,
77 qtdeclarative5-gsettings1.0,
78 qtdeclarative5-gsettings1.0,
po/fr.po+29−29
@@ -8,23 +8,23 @@ msgstr ""
8"Project-Id-Version: unity\n"
8"Project-Id-Version: unity\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
11−"PO-Revision-Date: 2013-06-27 03:21+0000\n"
11+"PO-Revision-Date: 2014-01-28 00:34+0000\n"
12−"Last-Translator: Michał Sawicz <michal.sawicz@canonical.com>\n"
12+"Last-Translator: Pierre <Unknown>\n"
13"Language-Team: French <fr@li.org>\n"
13"Language-Team: French <fr@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
15"Content-Type: text/plain; charset=UTF-8\n"
15"Content-Type: text/plain; charset=UTF-8\n"
16"Content-Transfer-Encoding: 8bit\n"
16"Content-Transfer-Encoding: 8bit\n"
17"Plural-Forms: nplurals=2; plural=n > 1;\n"
17"Plural-Forms: nplurals=2; plural=n > 1;\n"
18−"X-Launchpad-Export-Date: 2013-12-29 06:04+0000\n"
18+"X-Launchpad-Export-Date: 2014-01-28 07:06+0000\n"
19−"X-Generator: Launchpad (build 16877)\n"
19+"X-Generator: Launchpad (build 16914)\n"
20
20
21#: Components/EdgeDemoOverlay.qml:151
21#: Components/EdgeDemoOverlay.qml:151
22msgid "Skip intro"
22msgid "Skip intro"
23−msgstr ""
23+msgstr "Passer l'intro"
24
24
25#: Components/EdgeDemo.qml:112
25#: Components/EdgeDemo.qml:112
26msgid "Right edge"
26msgid "Right edge"
27−msgstr ""
27+msgstr "Bord droit"
28
28
29#: Components/EdgeDemo.qml:113
29#: Components/EdgeDemo.qml:113
30msgid "Try swiping from the right edge to unlock the phone"
30msgid "Try swiping from the right edge to unlock the phone"
@@ -32,7 +32,7 @@ msgstr ""
32
32
33#: Components/EdgeDemo.qml:144
33#: Components/EdgeDemo.qml:144
34msgid "Top edge"
34msgid "Top edge"
35−msgstr ""
35+msgstr "Bord supérieur"
36
36
37#: Components/EdgeDemo.qml:145
37#: Components/EdgeDemo.qml:145
38msgid "Try swiping from the top edge to access the indicators"
38msgid "Try swiping from the top edge to access the indicators"
@@ -40,7 +40,7 @@ msgstr ""
40
40
41#: Components/EdgeDemo.qml:170
41#: Components/EdgeDemo.qml:170
42msgid "Close"
42msgid "Close"
43−msgstr ""
43+msgstr "Fermer"
44
44
45#: Components/EdgeDemo.qml:171
45#: Components/EdgeDemo.qml:171
46msgid "Swipe up again to close the settings screen"
46msgid "Swipe up again to close the settings screen"
@@ -48,7 +48,7 @@ msgstr ""
48
48
49#: Components/EdgeDemo.qml:198
49#: Components/EdgeDemo.qml:198
50msgid "Left edge"
50msgid "Left edge"
51−msgstr ""
51+msgstr "Bord gauche"
52
52
53#: Components/EdgeDemo.qml:199
53#: Components/EdgeDemo.qml:199
54msgid "Swipe from the left to reveal the launcher for quick access to apps"
54msgid "Swipe from the left to reveal the launcher for quick access to apps"
@@ -66,70 +66,70 @@ msgstr ""
66
66
67#: Components/PageHeader.qml:364
67#: Components/PageHeader.qml:364
68msgid "Recent searches"
68msgid "Recent searches"
69−msgstr ""
69+msgstr "Recherches récentes"
70
70
71#: Dash/Apps/AppPreview.qml:135
71#: Dash/Apps/AppPreview.qml:135
72msgid "Rate this"
72msgid "Rate this"
73−msgstr ""
73+msgstr "Evaluez ceci"
74
74
75#. TRANSLATORS: Number of persons who rated this app/video/whatever
75#. TRANSLATORS: Number of persons who rated this app/video/whatever
76#: Dash/Previews/Header.qml:93
76#: Dash/Previews/Header.qml:93
77#, qt-format
77#, qt-format
78msgid "(%1)"
78msgid "(%1)"
79−msgstr ""
79+msgstr "(%1)"
80
80
81#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
81#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
82#: Dash/Previews/Header.qml:105
82#: Dash/Previews/Header.qml:105
83#, qt-format
83#, qt-format
84msgid "%1 review"
84msgid "%1 review"
85msgid_plural "%1 reviews"
85msgid_plural "%1 reviews"
86−msgstr[0] ""
86+msgstr[0] "%1 avis"
87−msgstr[1] ""
87+msgstr[1] "%1 avis"
88
88
89#: Dash/Previews/Reviews.qml:74
89#: Dash/Previews/Reviews.qml:74
90msgid "Add a review"
90msgid "Add a review"
91−msgstr ""
91+msgstr "Ajouter un avis"
92
92
93#: Dash/Previews/Reviews.qml:86
93#: Dash/Previews/Reviews.qml:86
94msgid "Review"
94msgid "Review"
95−msgstr ""
95+msgstr "Avis"
96
96
97#: Dash/Previews/Reviews.qml:121
97#: Dash/Previews/Reviews.qml:121
98msgid "Send"
98msgid "Send"
99−msgstr ""
99+msgstr "Envoyer"
100
100
101#: Dash/Previews/Reviews.qml:139
101#: Dash/Previews/Reviews.qml:139
102msgid "Comments:"
102msgid "Comments:"
103−msgstr ""
103+msgstr "Commentaires :"
104
104
105#: Greeter/Lockscreen.qml:149
105#: Greeter/Lockscreen.qml:149
106msgid "Emergency Call"
106msgid "Emergency Call"
107−msgstr ""
107+msgstr "Appel d'urgence"
108
108
109#: Greeter/PassphraseLockscreen.qml:59
109#: Greeter/PassphraseLockscreen.qml:59
110#, qt-format
110#, qt-format
111msgid "Hello %1"
111msgid "Hello %1"
112−msgstr ""
112+msgstr "Bonjour %1"
113
113
114#: Greeter/PassphraseLockscreen.qml:59
114#: Greeter/PassphraseLockscreen.qml:59
115msgid "Hello"
115msgid "Hello"
116−msgstr ""
116+msgstr "Bonjour"
117
117
118#: Hud/HudParametrizedActionsPage.qml:132
118#: Hud/HudParametrizedActionsPage.qml:132
119msgid "Confirm"
119msgid "Confirm"
120−msgstr ""
120+msgstr "Confirmez"
121
121
122#: Hud/Hud.qml:61 Hud/Hud.qml:99 Hud/Hud.qml:372
122#: Hud/Hud.qml:61 Hud/Hud.qml:99 Hud/Hud.qml:372
123msgid "Type or say a command"
123msgid "Type or say a command"
124−msgstr ""
124+msgstr "Rédigez ou dictez une commande"
125
125
126#: Hud/Hud.qml:84
126#: Hud/Hud.qml:84
127msgid "Loading. Please Wait..."
127msgid "Loading. Please Wait..."
128−msgstr ""
128+msgstr "Chargement. Veuillez patienter…"
129
129
130#: Hud/Hud.qml:89
130#: Hud/Hud.qml:89
131msgid "Speak Now..."
131msgid "Speak Now..."
132−msgstr ""
132+msgstr "Parlez maintenant…"
133
133
134#: Hud/Hud.qml:94
134#: Hud/Hud.qml:94
135msgid "Speaking..."
135msgid "Speaking..."
@@ -137,16 +137,16 @@ msgstr ""
137
137
138#: Notifications/NotificationMenuItemFactory.qml:89
138#: Notifications/NotificationMenuItemFactory.qml:89
139msgid "Show password"
139msgid "Show password"
140−msgstr ""
140+msgstr "Afficher le mot de passe"
141
141
142#: Panel/SearchIndicator.qml:27
142#: Panel/SearchIndicator.qml:27
143msgid "Search"
143msgid "Search"
144−msgstr ""
144+msgstr "Rechercher"
145
145
146#: plugins/Unity/Launcher/launcheritem.cpp:43
146#: plugins/Unity/Launcher/launcheritem.cpp:43
147#: plugins/Unity/Launcher/launcheritem.cpp:73
147#: plugins/Unity/Launcher/launcheritem.cpp:73
148msgid "Lock to Launcher"
148msgid "Lock to Launcher"
149−msgstr ""
149+msgstr "Conserver dans le lanceur"
150
150
151#: plugins/Unity/Launcher/launcheritem.cpp:73
151#: plugins/Unity/Launcher/launcheritem.cpp:73
152msgid "Unlock from Launcher"
152msgid "Unlock from Launcher"
@@ -155,4 +155,4 @@ msgstr ""
155#: Shell.qml:439
155#: Shell.qml:439
156#, qt-format
156#, qt-format
157msgid "Please enter %1"
157msgid "Please enter %1"
158−msgstr ""
158+msgstr "Veuillez saisir %1"
po/it.po+7−7
@@ -8,15 +8,15 @@ msgstr ""
8"Project-Id-Version: unity\n"
8"Project-Id-Version: unity\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
11−"PO-Revision-Date: 2013-10-07 09:34+0000\n"
11+"PO-Revision-Date: 2014-01-22 09:15+0000\n"
12−"Last-Translator: Claudio Arseni <claudio.arseni@gmail.com>\n"
12+"Last-Translator: Domenico <domenico.verde125@live.it>\n"
13"Language-Team: Italian <it@li.org>\n"
13"Language-Team: Italian <it@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
15"Content-Type: text/plain; charset=UTF-8\n"
15"Content-Type: text/plain; charset=UTF-8\n"
16"Content-Transfer-Encoding: 8bit\n"
16"Content-Transfer-Encoding: 8bit\n"
17"Plural-Forms: nplurals=2; plural=n != 1;\n"
17"Plural-Forms: nplurals=2; plural=n != 1;\n"
18−"X-Launchpad-Export-Date: 2013-12-29 06:04+0000\n"
18+"X-Launchpad-Export-Date: 2014-01-23 06:00+0000\n"
19−"X-Generator: Launchpad (build 16877)\n"
19+"X-Generator: Launchpad (build 16901)\n"
20
20
21#: Components/EdgeDemoOverlay.qml:151
21#: Components/EdgeDemoOverlay.qml:151
22msgid "Skip intro"
22msgid "Skip intro"
@@ -144,7 +144,7 @@ msgstr "Sto parlando..."
144
144
145#: Notifications/NotificationMenuItemFactory.qml:89
145#: Notifications/NotificationMenuItemFactory.qml:89
146msgid "Show password"
146msgid "Show password"
147−msgstr ""
147+msgstr "Mostra password"
148
148
149#: Panel/SearchIndicator.qml:27
149#: Panel/SearchIndicator.qml:27
150msgid "Search"
150msgid "Search"
@@ -153,11 +153,11 @@ msgstr "Cerca"
153#: plugins/Unity/Launcher/launcheritem.cpp:43
153#: plugins/Unity/Launcher/launcheritem.cpp:43
154#: plugins/Unity/Launcher/launcheritem.cpp:73
154#: plugins/Unity/Launcher/launcheritem.cpp:73
155msgid "Lock to Launcher"
155msgid "Lock to Launcher"
156−msgstr ""
156+msgstr "Blocca nel Launcher"
157
157
158#: plugins/Unity/Launcher/launcheritem.cpp:73
158#: plugins/Unity/Launcher/launcheritem.cpp:73
159msgid "Unlock from Launcher"
159msgid "Unlock from Launcher"
160−msgstr ""
160+msgstr "Sblocca dal Launcher"
161
161
162#: Shell.qml:439
162#: Shell.qml:439
163#, qt-format
163#, qt-format
po/ru.po+7−6
@@ -8,16 +8,16 @@ msgstr ""
8"Project-Id-Version: unity\n"
8"Project-Id-Version: unity\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
10"POT-Creation-Date: 2013-11-29 09:21+0100\n"
11−"PO-Revision-Date: 2014-01-14 19:17+0000\n"
11+"PO-Revision-Date: 2014-01-26 15:56+0000\n"
12−"Last-Translator: alex <sos987@gmail.com>\n"
12+"Last-Translator: Zonov Roman <Unknown>\n"
13"Language-Team: Russian <ru@li.org>\n"
13"Language-Team: Russian <ru@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
15"Content-Type: text/plain; charset=UTF-8\n"
15"Content-Type: text/plain; charset=UTF-8\n"
16"Content-Transfer-Encoding: 8bit\n"
16"Content-Transfer-Encoding: 8bit\n"
17"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
17"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
18"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
18"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
19−"X-Launchpad-Export-Date: 2014-01-15 06:35+0000\n"
19+"X-Launchpad-Export-Date: 2014-01-27 05:48+0000\n"
20−"X-Generator: Launchpad (build 16890)\n"
20+"X-Generator: Launchpad (build 16914)\n"
21
21
22#: Components/EdgeDemoOverlay.qml:151
22#: Components/EdgeDemoOverlay.qml:151
23msgid "Skip intro"
23msgid "Skip intro"
@@ -91,8 +91,9 @@ msgstr "(%1)"
91#, qt-format
91#, qt-format
92msgid "%1 review"
92msgid "%1 review"
93msgid_plural "%1 reviews"
93msgid_plural "%1 reviews"
94+msgstr[0] "%1 отзыв"
94−msgstr[0] "%1 отзыва"
95+msgstr[1] "%1 отзыва"
95−msgstr[1] "%1 отзывов"
96+msgstr[2] "%1 отзывов"
96
97
97#: Dash/Previews/Reviews.qml:74
98#: Dash/Previews/Reviews.qml:74
98msgid "Add a review"
99msgid "Add a review"
po/zh_HK.ponew file+157
@@ -0,0 +1,157 @@
1+# Chinese (Hong Kong) translation for unity8
2+# Copyright (c) 2014 Rosetta Contributors and Canonical Ltd 2014
3+# This file is distributed under the same license as the unity8 package.
4+# FIRST AUTHOR <EMAIL@ADDRESS>, 2014.
5+#
6+msgid ""
7+msgstr ""
8+"Project-Id-Version: unity8\n"
9+"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
10+"POT-Creation-Date: 2013-11-29 09:21+0100\n"
11+"PO-Revision-Date: 2014-01-25 13:32+0000\n"
12+"Last-Translator: Daniel Cheung <daniel.2345@hotmail.com>\n"
13+"Language-Team: Chinese (Hong Kong) <zh_HK@li.org>\n"
14+"MIME-Version: 1.0\n"
15+"Content-Type: text/plain; charset=UTF-8\n"
16+"Content-Transfer-Encoding: 8bit\n"
17+"Plural-Forms: nplurals=1; plural=0;\n"
18+"X-Launchpad-Export-Date: 2014-01-26 05:18+0000\n"
19+"X-Generator: Launchpad (build 16914)\n"
20+
21+#: Components/EdgeDemoOverlay.qml:151
22+msgid "Skip intro"
23+msgstr "跳過介紹"
24+
25+#: Components/EdgeDemo.qml:112
26+msgid "Right edge"
27+msgstr "右邊緣"
28+
29+#: Components/EdgeDemo.qml:113
30+msgid "Try swiping from the right edge to unlock the phone"
31+msgstr "試從右邊緣輕掃解鎖手機"
32+
33+#: Components/EdgeDemo.qml:144
34+msgid "Top edge"
35+msgstr "頂部邊緣"
36+
37+#: Components/EdgeDemo.qml:145
38+msgid "Try swiping from the top edge to access the indicators"
39+msgstr "試從頂部邊緣輕掃存取指示器"
40+
41+#: Components/EdgeDemo.qml:170
42+msgid "Close"
43+msgstr "關閉"
44+
45+#: Components/EdgeDemo.qml:171
46+msgid "Swipe up again to close the settings screen"
47+msgstr "再向上掃一次以關閉設定畫面"
48+
49+#: Components/EdgeDemo.qml:198
50+msgid "Left edge"
51+msgstr "左邊緣"
52+
53+#: Components/EdgeDemo.qml:199
54+msgid "Swipe from the left to reveal the launcher for quick access to apps"
55+msgstr "從左邊緣輕掃以顯示啟動器快速訪問應用"
56+
57+#: Components/EdgeDemo.qml:226
58+msgid "Well done"
59+msgstr "做得好"
60+
61+#: Components/EdgeDemo.qml:227
62+msgid ""
63+"You have now mastered the edge gestures and can start using the "
64+"phone<br><br>Tap anywhere to start"
65+msgstr "現在你已經掌握了邊緣手勢,可以開始使用手機<br><br>點擊任意位置以開始"
66+
67+#: Components/PageHeader.qml:364
68+msgid "Recent searches"
69+msgstr "最近的搜尋"
70+
71+#: Dash/Apps/AppPreview.qml:135
72+msgid "Rate this"
73+msgstr "評價"
74+
75+#. TRANSLATORS: Number of persons who rated this app/video/whatever
76+#: Dash/Previews/Header.qml:93
77+#, qt-format
78+msgid "(%1)"
79+msgstr "(%1)"
80+
81+#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
82+#: Dash/Previews/Header.qml:105
83+#, qt-format
84+msgid "%1 review"
85+msgid_plural "%1 reviews"
86+msgstr[0] "%1 評論"
87+
88+#: Dash/Previews/Reviews.qml:74
89+msgid "Add a review"
90+msgstr "新增評論"
91+
92+#: Dash/Previews/Reviews.qml:86
93+msgid "Review"
94+msgstr "評論"
95+
96+#: Dash/Previews/Reviews.qml:121
97+msgid "Send"
98+msgstr "傳送"
99+
100+#: Dash/Previews/Reviews.qml:139
101+msgid "Comments:"
102+msgstr "評論:"
103+
104+#: Greeter/Lockscreen.qml:149
105+msgid "Emergency Call"
106+msgstr "緊急電話"
107+
108+#: Greeter/PassphraseLockscreen.qml:59
109+#, qt-format
110+msgid "Hello %1"
111+msgstr "您好 %1"
112+
113+#: Greeter/PassphraseLockscreen.qml:59
114+msgid "Hello"
115+msgstr "您好"
116+
117+#: Hud/HudParametrizedActionsPage.qml:132
118+msgid "Confirm"
119+msgstr "確認"
120+
121+#: Hud/Hud.qml:61 Hud/Hud.qml:99 Hud/Hud.qml:372
122+msgid "Type or say a command"
123+msgstr "輸入或說出指令"
124+
125+#: Hud/Hud.qml:84
126+msgid "Loading. Please Wait..."
127+msgstr "正載入。請稍候..."
128+
129+#: Hud/Hud.qml:89
130+msgid "Speak Now..."
131+msgstr "馬上講..."
132+
133+#: Hud/Hud.qml:94
134+msgid "Speaking..."
135+msgstr "正在講..."
136+
137+#: Notifications/NotificationMenuItemFactory.qml:89
138+msgid "Show password"
139+msgstr "顯示密碼"
140+
141+#: Panel/SearchIndicator.qml:27
142+msgid "Search"
143+msgstr "搜尋"
144+
145+#: plugins/Unity/Launcher/launcheritem.cpp:43
146+#: plugins/Unity/Launcher/launcheritem.cpp:73
147+msgid "Lock to Launcher"
148+msgstr "鎖定至啟動器"
149+
150+#: plugins/Unity/Launcher/launcheritem.cpp:73
151+msgid "Unlock from Launcher"
152+msgstr "從啟動器解除鎖定"
153+
154+#: Shell.qml:439
155+#, qt-format
156+msgid "Please enter %1"
157+msgstr "請輸入 %1"
qml/Components/ResponsiveGridView.qml+1−1
@@ -72,7 +72,7 @@ Item {
72
72
73 function columnsForSpacing(spacing) {
73 function columnsForSpacing(spacing) {
74 // minimum margin is half of the spacing
74 // minimum margin is half of the spacing
75− return Math.max(1, Math.floor((parent.width - spacing/2) / (delegateWidth + spacing)));
75+ return Math.max(1, Math.floor(parent.width / (delegateWidth + spacing)));
76 }
76 }
77
77
78 property real allocatableHorizontalSpace: parent.width - columns * delegateWidth
78 property real allocatableHorizontalSpace: parent.width - columns * delegateWidth
qml/Dash/Card.qml+1
@@ -79,5 +79,6 @@ Item {
79 maximumLineCount: 5
79 maximumLineCount: 5
80 elide: Text.ElideRight
80 elide: Text.ElideRight
81 text: cardData && cardData["summary"] || ""
81 text: cardData && cardData["summary"] || ""
82+ height: text ? implicitHeight : 0
82 }
83 }
83}
84}
qml/Dash/CardHeader.qml+5−1
@@ -56,9 +56,9 @@ Item {
56
56
57 Label {
57 Label {
58 id: titleLabel
58 id: titleLabel
59+ objectName: "titleLabel"
59 anchors { left: parent.left; right: parent.right }
60 anchors { left: parent.left; right: parent.right }
60 elide: Text.ElideRight
61 elide: Text.ElideRight
61− objectName: "titleLabel"
62 font.weight: Font.DemiBold
62 font.weight: Font.DemiBold
63 wrapMode: Text.Wrap
63 wrapMode: Text.Wrap
64 maximumLineCount: 2
64 maximumLineCount: 2
@@ -66,6 +66,7 @@ Item {
66
66
67 Label {
67 Label {
68 id: subtitleLabel
68 id: subtitleLabel
69+ objectName: "subtitleLabel"
69 anchors { left: parent.left; right: parent.right }
70 anchors { left: parent.left; right: parent.right }
70 elide: Text.ElideRight
71 elide: Text.ElideRight
71 visible: titleLabel.text && text
72 visible: titleLabel.text && text
@@ -90,6 +91,7 @@ Item {
90 elide: Text.ElideRight
91 elide: Text.ElideRight
91 font.weight: Font.DemiBold
92 font.weight: Font.DemiBold
92 color: Theme.palette.selected.foreground
93 color: Theme.palette.selected.foreground
94+ visible: text
93 }
95 }
94
96
95 Label {
97 Label {
@@ -98,6 +100,7 @@ Item {
98 width: parent.labelWidth
100 width: parent.labelWidth
99 elide: Text.ElideRight
101 elide: Text.ElideRight
100 horizontalAlignment: parent.labels === 3 ? Text.AlignHCenter : Text.AlignRight
102 horizontalAlignment: parent.labels === 3 ? Text.AlignHCenter : Text.AlignRight
103+ visible: text
101 }
104 }
102
105
103 Label {
106 Label {
@@ -105,6 +108,7 @@ Item {
105 width: parent.labelWidth
108 width: parent.labelWidth
106 elide: Text.ElideRight
109 elide: Text.ElideRight
107 horizontalAlignment: Text.AlignRight
110 horizontalAlignment: Text.AlignRight
111+ visible: text
108 }
112 }
109 }
113 }
110 }
114 }
tests/qmltests/Components/tst_ResponsiveGridView.qml+1−1
@@ -152,7 +152,7 @@ Item {
152 var data = new Array()
152 var data = new Array()
153
153
154 data.push({selectedIndex: 0, minHSpacing:0, columnCount: 13})
154 data.push({selectedIndex: 0, minHSpacing:0, columnCount: 13})
155− data.push({selectedIndex: 1, minHSpacing:units.gu(2), columnCount: 9})
155+ data.push({selectedIndex: 1, minHSpacing:units.gu(2), columnCount: 10})
156 data.push({selectedIndex: 2, minHSpacing:units.gu(8), columnCount: 5})
156 data.push({selectedIndex: 2, minHSpacing:units.gu(8), columnCount: 5})
157 data.push({selectedIndex: 3, minHSpacing:units.gu(25), columnCount: 2})
157 data.push({selectedIndex: 3, minHSpacing:units.gu(25), columnCount: 2})
158
158
tests/qmltests/Dash/tst_Card.qml+21−4
@@ -106,6 +106,10 @@ Rectangle {
106 "layout": { "template": { "card-layout": "horizontal" },
106 "layout": { "template": { "card-layout": "horizontal" },
107 "components": JSON.parse(fullMapping) }
107 "components": JSON.parse(fullMapping) }
108 },
108 },
109+ {
110+ "name": "Art, header - vertical",
111+ "layout": { "components": Helpers.update(JSON.parse(root.fullMapping), { "summary": undefined }) }
112+ },
109 ]
113 ]
110
114
111 Card {
115 Card {
@@ -189,7 +193,10 @@ Rectangle {
189 property Item summary: findChild(card, "summaryLabel")
193 property Item summary: findChild(card, "summaryLabel")
190
194
191 function initTestCase() {
195 function initTestCase() {
192− verify(testCase.header !== undefined, "Couldn't find header object.");
196+ verify(typeof testCase.header === "object", "Couldn't find header object.");
197+ verify(typeof testCase.art === "object", "Couldn't find art object.");
198+ verify(typeof testCase.artImage === "object", "Couldn't find artImage object.");
199+ verify(typeof testCase.summary === "object", "Couldn't find summary object.");
193 }
200 }
194
201
195 function cleanup() {
202 function cleanup() {
@@ -237,6 +244,9 @@ Rectangle {
237 { tag: "Large", width: units.gu(38), size: "large", index: 0 },
244 { tag: "Large", width: units.gu(38), size: "large", index: 0 },
238 { tag: "Wide", width: units.gu(18.5), aspect: 0.5, index: 0 },
245 { tag: "Wide", width: units.gu(18.5), aspect: 0.5, index: 0 },
239 { tag: "Horizontal", width: units.gu(38), index: 5 },
246 { tag: "Horizontal", width: units.gu(38), index: 5 },
247+ // Make sure card ends with header when there's no summary
248+ { tag: "NoSummary", height: function() { return header.y + header.height }, index: 6 },
249+ { tag: "HorizontalNoSummary", height: function() { return header.height }, card_layout: "horizontal", index: 6 },
240 ]
250 ]
241 }
251 }
242
252
@@ -248,6 +258,11 @@ Rectangle {
248 card.templateChanged();
258 card.templateChanged();
249 }
259 }
250
260
261+ if (data.hasOwnProperty("card_layout")) {
262+ card.template['card-layout'] = data.card_layout;
263+ card.templateChanged();
264+ }
265+
251 if (data.hasOwnProperty("aspect")) {
266 if (data.hasOwnProperty("aspect")) {
252 card.components['art']['aspect-ratio'] = data.aspect;
267 card.components['art']['aspect-ratio'] = data.aspect;
253 card.componentsChanged();
268 card.componentsChanged();
@@ -257,7 +272,9 @@ Rectangle {
257 tryCompare(card, "width", data.width);
272 tryCompare(card, "width", data.width);
258 }
273 }
259
274
275+ if (typeof data.height === "function") {
276+ tryCompareFunction(function() { return card.height === data.height() }, true);
260− if (data.hasOwnProperty("height")) {
277+ } else if (data.hasOwnProperty("height")) {
261 tryCompare(card, "height", data.height);
278 tryCompare(card, "height", data.height);
262 }
279 }
263 }
280 }
@@ -308,7 +325,7 @@ Rectangle {
308 function test_art_layout_data() {
325 function test_art_layout_data() {
309 return [
326 return [
310 { tag: "Vertical", left: function() { return 0 }, index: 0},
327 { tag: "Vertical", left: function() { return 0 }, index: 0},
311− { tag: "Horizontal", left: function() { return art.width }, index: 5 }
328+ { tag: "Horizontal", left: function() { return art.width }, index: 5 },
312 ];
329 ];
313 }
330 }
314
331
@@ -323,7 +340,7 @@ Rectangle {
323 { tag: "Vertical", top: function() { return art.y + art.height },
340 { tag: "Vertical", top: function() { return art.y + art.height },
324 left: function() { return art.x }, index: 0 },
341 left: function() { return art.x }, index: 0 },
325 { tag: "Horizontal", top: function() { return art.y },
342 { tag: "Horizontal", top: function() { return art.y },
326− left: function() { return art.x + art.width }, index: 5 }
343+ left: function() { return art.x + art.width }, index: 5 },
327 ]
344 ]
328 }
345 }
329
346
tests/qmltests/Dash/tst_CardHeader.qml+13−8
@@ -52,11 +52,11 @@ Rectangle {
52 property Item column: findChild(cardHeader, "column")
52 property Item column: findChild(cardHeader, "column")
53
53
54 function initTestCase() {
54 function initTestCase() {
55− verify(testCase.mascot !== undefined, "Couldn't find mascot object.");
55+ verify(typeof testCase.mascot === "object", "Couldn't find mascot object.");
56− verify(testCase.titleLabel !== undefined, "Couldn't find titleLabel object.");
56+ verify(typeof testCase.titleLabel === "object", "Couldn't find titleLabel object.");
57− verify(testCase.subtitleLabel !== undefined, "Couldn't find subtitleLabel object.");
57+ verify(typeof testCase.subtitleLabel === "object", "Couldn't find subtitleLabel object.");
58− verify(testCase.prices !== undefined, "Couldn't find prices object.");
58+ verify(typeof testCase.prices === "object", "Couldn't find prices object.");
59− verify(testCase.oldPriceLabel !== undefined, "Couldn't find oldPriceLabel object.");
59+ verify(typeof testCase.oldPriceLabel === "object", "Couldn't find oldPriceLabel object.");
60 }
60 }
61
61
62 function cleanup() {
62 function cleanup() {
@@ -86,7 +86,7 @@ Rectangle {
86 { tag: "Empty", visible: false },
86 { tag: "Empty", visible: false },
87 { tag: "Title only", title: "Foo", visible: true },
87 { tag: "Title only", title: "Foo", visible: true },
88 { tag: "Subtitle only", subtitle: "Bar", visible: false },
88 { tag: "Subtitle only", subtitle: "Bar", visible: false },
89− { tag: "Both", title: "Foo", subtitle: "Bar", visible: true }
89+ { tag: "Both", title: "Foo", subtitle: "Bar", visible: true },
90 ]
90 ]
91 }
91 }
92
92
@@ -104,7 +104,7 @@ Rectangle {
104 { tag: "Main and Alt", main: "$1.25", alt: "€1.00", visible: true },
104 { tag: "Main and Alt", main: "$1.25", alt: "€1.00", visible: true },
105 { tag: "Main and Old", main: "$1.25", old: "$2.00", visible: true, oldAlign: Text.AlignRight },
105 { tag: "Main and Old", main: "$1.25", old: "$2.00", visible: true, oldAlign: Text.AlignRight },
106 { tag: "Alt and Old", alt: "€1.00", old: "$2.00", visible: false },
106 { tag: "Alt and Old", alt: "€1.00", old: "$2.00", visible: false },
107− { tag: "All", main: "$1.25", alt: "€1.00", old: "$2.00", visible: true, oldAlign: Text.AlignHCenter }
107+ { tag: "All", main: "$1.25", alt: "€1.00", old: "$2.00", visible: true, oldAlign: Text.AlignHCenter },
108 ]
108 ]
109 }
109 }
110
110
@@ -121,7 +121,8 @@ Rectangle {
121 function test_dimensions_data() {
121 function test_dimensions_data() {
122 return [
122 return [
123 { tag: "Column width", object: column, width: cardHeader.width - testCase.outerRow.spacing * 2 },
123 { tag: "Column width", object: column, width: cardHeader.width - testCase.outerRow.spacing * 2 },
124− { tag: "Column width", object: column, width: cardHeader.width - mascot.width - testCase.outerRow.spacing * 3, mascot: "artwork/avatar.png" }
124+ { tag: "Column width", object: column, width: cardHeader.width - mascot.width - testCase.outerRow.spacing * 3, mascot: "artwork/avatar.png" },
125+ { tag: "Header height", object: cardHeader, height: function() { return subtitleLabel.y + subtitleLabel.height + outerRow.spacing * 2 } },
125 ]
126 ]
126 }
127 }
127
128
@@ -133,6 +134,10 @@ Rectangle {
133 if (data.hasOwnProperty("width")) {
134 if (data.hasOwnProperty("width")) {
134 tryCompare(data.object, "width", data.width);
135 tryCompare(data.object, "width", data.width);
135 }
136 }
137+
138+ if (data.hasOwnProperty("height")) {
139+ tryCompareFunction(function() { return data.object.height === data.height() }, true);
140+ }
136 }
141 }
137 }
142 }
138}
143}