on xenial help sign in
Merge from trunk
2b5d9dfMichael Terry
Components/Carousel.qml+5−4
@@ -72,7 +72,7 @@ Item {
72 id: listView
72 id: listView
73
73
74 property real minimumTileWidth: 0
74 property real minimumTileWidth: 0
75− property real newContentX: -1
75+ property real newContentX: disabledNewContentX
76 property real pathItemCount: referenceWidth / referenceTileWidth
76 property real pathItemCount: referenceWidth / referenceTileWidth
77 property real tileAspectRatio: 1
77 property real tileAspectRatio: 1
78
78
@@ -100,6 +100,7 @@ Item {
100 readonly property real kMiddleIndex: (realWidth / 2) / tileWidth - 0.5
100 readonly property real kMiddleIndex: (realWidth / 2) / tileWidth - 0.5
101 readonly property real kXBeginningEnd: 1 / tileWidth + kMiddleIndex / gapToMiddlePhase
101 readonly property real kXBeginningEnd: 1 / tileWidth + kMiddleIndex / gapToMiddlePhase
102 readonly property real maximumItemTranslation: (listView.tileWidth * 3) / listView.scaleFactor
102 readonly property real maximumItemTranslation: (listView.tileWidth * 3) / listView.scaleFactor
103+ readonly property real disabledNewContentX: -carousel.drawBuffer - 1
103 readonly property real realContentWidth: contentWidth - 2 * carousel.drawBuffer
104 readonly property real realContentWidth: contentWidth - 2 * carousel.drawBuffer
104 readonly property real realContentX: contentX + carousel.drawBuffer
105 readonly property real realContentX: contentX + carousel.drawBuffer
105 readonly property real realPathItemCount: Math.min(realWidth / tileWidth, pathItemCount)
106 readonly property real realPathItemCount: Math.min(realWidth / tileWidth, pathItemCount)
@@ -192,7 +193,7 @@ Item {
192 onMovementStarted: {
193 onMovementStarted: {
193 stepAnimation.stop()
194 stepAnimation.stop()
194 newContentXAnimation.stop()
195 newContentXAnimation.stop()
195− newContentX = -1
196+ newContentX = disabledNewContentX
196 }
197 }
197 onMovementEnded: {
198 onMovementEnded: {
198 if (realContentX > 0 && realContentX < realContentWidth - realWidth)
199 if (realContentX > 0 && realContentX < realContentWidth - realWidth)
@@ -228,7 +229,7 @@ Item {
228 easing.type: Easing.InOutQuad
229 easing.type: Easing.InOutQuad
229 }
230 }
230 ScriptAction {
231 ScriptAction {
231− script: listView.newContentX = -1
232+ script: listView.newContentX = listView.disabledNewContentX
232 }
233 }
233 }
234 }
234
235
@@ -253,7 +254,7 @@ Item {
253 readonly property bool explicitScale: (!listView.moving ||
254 readonly property bool explicitScale: (!listView.moving ||
254 listView.realContentX <= 0 ||
255 listView.realContentX <= 0 ||
255 listView.realContentX >= listView.realContentWidth - listView.realWidth) &&
256 listView.realContentX >= listView.realContentWidth - listView.realWidth) &&
256− listView.newContentX < 0 &&
257+ listView.newContentX === listView.disabledNewContentX &&
257 index === listView.selectedIndex
258 index === listView.selectedIndex
258 readonly property real cachedTiles: listView.realPathItemCount + carousel.drawBuffer / listView.tileWidth
259 readonly property real cachedTiles: listView.realPathItemCount + carousel.drawBuffer / listView.tileWidth
259 readonly property real distance: listView.continuousIndex - index
260 readonly property real distance: listView.continuousIndex - index
Dash/Apps/FrequentlyUsedAppsModel.qml+16−16
@@ -18,54 +18,54 @@ import QtQuick 2.0
18
18
19ListModel {
19ListModel {
20 ListElement {
20 ListElement {
21− uri: "application:///usr/share/applications/dialer-app.desktop"
21+ uri: "application://dialer-app.desktop"
22 icon: "../../graphics/applicationIcons/phone-app.png"
22 icon: "../../graphics/applicationIcons/phone-app.png"
23 category: 0
23 category: 0
24 mimetype: "application/x-desktop"
24 mimetype: "application/x-desktop"
25 title: "Dialer"
25 title: "Dialer"
26 comment: ""
26 comment: ""
27 dndUri: "file:///usr/share/applications/dialer-app.desktop"
27 dndUri: "file:///usr/share/applications/dialer-app.desktop"
28− metadata: ""
28+ metadata: "subscope:applications.scope/applications-non-click.scope"
29 }
29 }
30 ListElement {
30 ListElement {
31− uri: "application:///usr/share/applications/messaging-app.desktop"
31+ uri: "application://messaging-app.desktop"
32 icon: "../../graphics/applicationIcons/messages-app.png"
32 icon: "../../graphics/applicationIcons/messages-app.png"
33 category: 0
33 category: 0
34 mimetype: "application/x-desktop"
34 mimetype: "application/x-desktop"
35 title: "Messaging"
35 title: "Messaging"
36 comment: ""
36 comment: ""
37 dndUri: "file:///usr/share/applications/messaging-app.desktop"
37 dndUri: "file:///usr/share/applications/messaging-app.desktop"
38− metadata: ""
38+ metadata: "subscope:applications.scope/applications-non-click.scope"
39 }
39 }
40 ListElement {
40 ListElement {
41− uri: "application:///usr/share/applications/address-book-app.desktop"
41+ uri: "application://address-book-app.desktop"
42 icon: "../../graphics/applicationIcons/contacts-app.png"
42 icon: "../../graphics/applicationIcons/contacts-app.png"
43 category: 0
43 category: 0
44 mimetype: "application/x-desktop"
44 mimetype: "application/x-desktop"
45 title: "Contacts"
45 title: "Contacts"
46 comment: ""
46 comment: ""
47 dndUri: "file:///usr/share/applications/address-book-app.desktop"
47 dndUri: "file:///usr/share/applications/address-book-app.desktop"
48− metadata: ""
48+ metadata: "subscope:applications.scope/applications-non-click.scope"
49 }
49 }
50 ListElement {
50 ListElement {
51− uri: "application:///usr/share/applications/camera-app.desktop"
51+ uri: "application://camera-app.desktop"
52 icon: "../../graphics/applicationIcons/camera.png"
52 icon: "../../graphics/applicationIcons/camera.png"
53 category: 0
53 category: 0
54 mimetype: "application/x-desktop"
54 mimetype: "application/x-desktop"
55 title: "Camera"
55 title: "Camera"
56 comment: ""
56 comment: ""
57 dndUri: "file:///usr/share/applications/camera-app.desktop"
57 dndUri: "file:///usr/share/applications/camera-app.desktop"
58− metadata: ""
58+ metadata: "subscope:applications.scope/applications-non-click.scope"
59 }
59 }
60 ListElement {
60 ListElement {
61− uri: "application:///usr/share/applications/gallery-app.desktop"
61+ uri: "application://gallery-app.desktop"
62 icon: "../../graphics/applicationIcons/gallery.png"
62 icon: "../../graphics/applicationIcons/gallery.png"
63 category: 0
63 category: 0
64 mimetype: "application/x-desktop"
64 mimetype: "application/x-desktop"
65 title: "Gallery"
65 title: "Gallery"
66 comment: ""
66 comment: ""
67 dndUri: "file:///usr/share/applications/gallery.desktop"
67 dndUri: "file:///usr/share/applications/gallery.desktop"
68− metadata: ""
68+ metadata: "subscope:applications.scope/applications-non-click.scope"
69 }
69 }
70 ListElement {
70 ListElement {
71 uri: "appid://com.ubuntu.developer.webapps.webapp-facebook/webapp-facebook/current-user-version"
71 uri: "appid://com.ubuntu.developer.webapps.webapp-facebook/webapp-facebook/current-user-version"
@@ -75,17 +75,17 @@ ListModel {
75 title: "Facebook"
75 title: "Facebook"
76 comment: ""
76 comment: ""
77 dndUri: "appid://com.ubuntu.developer.webapps.webapp-facebook/webapp-facebook/current-user-version"
77 dndUri: "appid://com.ubuntu.developer.webapps.webapp-facebook/webapp-facebook/current-user-version"
78− metadata: ""
78+ metadata: "subscope:applications.scope/applications-click.scope?app_id=com.ubuntu.developer.webapps.webapp-facebook"
79 }
79 }
80 ListElement {
80 ListElement {
81− uri: "application:///usr/share/applications/webbrowser-app.desktop"
81+ uri: "application://webbrowser-app.desktop"
82 icon: "../../graphics/applicationIcons/browser.png"
82 icon: "../../graphics/applicationIcons/browser.png"
83 category: 0
83 category: 0
84 mimetype: "application/x-desktop"
84 mimetype: "application/x-desktop"
85 title: "Browser"
85 title: "Browser"
86 comment: ""
86 comment: ""
87 dndUri: "file:///usr/share/applications/webbrowser-app.desktop"
87 dndUri: "file:///usr/share/applications/webbrowser-app.desktop"
88− metadata: ""
88+ metadata: "subscope:applications.scope/applications-non-click.scope"
89 }
89 }
90 ListElement {
90 ListElement {
91 uri: "appid://com.ubuntu.developer.webapps.webapp-gmail/webapp-gmail/current-user-version"
91 uri: "appid://com.ubuntu.developer.webapps.webapp-gmail/webapp-gmail/current-user-version"
@@ -95,16 +95,16 @@ ListModel {
95 title: "GMail"
95 title: "GMail"
96 comment: ""
96 comment: ""
97 dndUri: "appid://com.ubuntu.developer.webapps.webapp-gmail/webapp-gmail/current-user-version"
97 dndUri: "appid://com.ubuntu.developer.webapps.webapp-gmail/webapp-gmail/current-user-version"
98− metadata: ""
98+ metadata: "subscope:applications.scope/applications-click.scope?app_id=com.ubuntu.developer.webapps.webapp-gmail"
99 }
99 }
100 ListElement {
100 ListElement {
101− uri: "application:///usr/share/applications/ubuntu-system-settings.desktop"
101+ uri: "application://ubuntu-system-settings.desktop"
102 icon: "../../graphics/applicationIcons/system-settings.png"
102 icon: "../../graphics/applicationIcons/system-settings.png"
103 category: 0
103 category: 0
104 mimetype: "application/x-desktop"
104 mimetype: "application/x-desktop"
105 title: "System Settings"
105 title: "System Settings"
106 comment: ""
106 comment: ""
107 dndUri: "file:///usr/share/applications/ubuntu-system-settings.desktop"
107 dndUri: "file:///usr/share/applications/ubuntu-system-settings.desktop"
108− metadata: ""
108+ metadata: "subscope:applications.scope/applications-non-click.scope"
109 }
109 }
110}
110}
Dash/DashPreview.qml+8
@@ -22,6 +22,7 @@ Rectangle {
22
22
23 property int keyboardSize: Qt.inputMethod.visible ? Qt.inputMethod.keyboardRectangle.height : 0
23 property int keyboardSize: Qt.inputMethod.visible ? Qt.inputMethod.keyboardRectangle.height : 0
24 property var previewData
24 property var previewData
25+ property alias showProcessingAction: waitingForActionMouseArea.enabled
25
26
26 property real previewWidthRatio: 0.5
27 property real previewWidthRatio: 0.5
27
28
@@ -196,4 +197,11 @@ Rectangle {
196 }
197 }
197 sourceComponent: root.header
198 sourceComponent: root.header
198 }
199 }
200+
201+ MouseArea {
202+ id: waitingForActionMouseArea
203+ objectName: "waitingForActionMouseArea"
204+ anchors.fill: parent
205+ enabled: false
206+ }
199}
207}
Dash/Generic/GenericPreview.qml+4−1
@@ -71,7 +71,10 @@ DashPreview {
71 text: modelData.displayName
71 text: modelData.displayName
72 iconSource: modelData.iconHint
72 iconSource: modelData.iconHint
73 iconPosition: "right"
73 iconPosition: "right"
74+ onClicked: {
74− onClicked: previewData.execute(modelData.id, { })
75+ previewData.execute(modelData.id, { })
76+ genericPreview.showProcessingAction = true;
77+ }
75 }
78 }
76 }
79 }
77 }
80 }
Dash/GenericScopeView.qml+7
@@ -59,6 +59,7 @@ ScopeView {
59 target: scopeView.scope
59 target: scopeView.scope
60 onShowDash: previewLoader.open = false;
60 onShowDash: previewLoader.open = false;
61 onHideDash: previewLoader.open = false;
61 onHideDash: previewLoader.open = false;
62+ onActivated: previewLoader.closePreviewSpinner();
62 }
63 }
63
64
64 ScopeListView {
65 ScopeListView {
@@ -345,6 +346,12 @@ ScopeView {
345 onLoaded: {
346 onLoaded: {
346 item.previewData = Qt.binding(function() { return previewLoader.previewData })
347 item.previewData = Qt.binding(function() { return previewLoader.previewData })
347 }
348 }
349+
350+ function closePreviewSpinner() {
351+ if(item) {
352+ item.showProcessingAction = false;
353+ }
354+ }
348 }
355 }
349
356
350 // TODO: Move as InverseMouseArea to DashPreview
357 // TODO: Move as InverseMouseArea to DashPreview
Notifications/Notification.qml+2−1
@@ -34,12 +34,13 @@ UbuntuShape {
34 property var notification
34 property var notification
35
35
36 objectName: "background"
36 objectName: "background"
37− implicitHeight: contentColumn.height + contentColumn.spacing * 2
37+ implicitHeight: type != Notification.PlaceHolder ? contentColumn.height + contentColumn.spacing * 2 : 0
38 color: Qt.rgba(0.132, 0.117, 0.109, 0.97)
38 color: Qt.rgba(0.132, 0.117, 0.109, 0.97)
39 opacity: 0
39 opacity: 0
40 radius: "medium"
40 radius: "medium"
41
41
42 clip: true
42 clip: true
43+ visible: type != Notification.PlaceHolder
43
44
44 UnityMenuModelPaths {
45 UnityMenuModelPaths {
45 id: paths
46 id: paths
data/unity8-setcap.confdeleted−32
@@ -1,32 +0,0 @@
1−# unity8-setcap - ugly hacks to arrange for /usr/bin/unity8 to have CAP_SYS_RESOURCE
2−
3−# XXX replace me with some root-helper to gain CAP_SYS_RESOURCE XXX
4−
5−author "Loïc Minier <loic.minier@ubuntu.com>"
6−description "Ugly hacks to arrange for /usr/bin/unity8 to have CAP_SYS_RESOURCE"
7−
8−# start when first boot-hooks event is emitted and before lightdm (lightdm
9−# starts ubuntu-touch-session which starts unity8); note that /run is
10−# guaranteeds to be be there because lightdm starts on filesystem
11−start on boot-hooks and starting lightdm
12−
13−# NOT a task as otherwise this would block restarting lightdm
14−
15−env RUNDIR=/run/unity8-setcap
16−
17−# work needs to be done in pre-start as this really is a job with nothing to
18−# start
19−pre-start script
20− if [ ! -e "$RUNDIR" ]; then
21− mkdir "$RUNDIR"
22− # /run is noexec, hence mounting another tmpfs exec
23− # NB: unity8 is 35K; 512K should be enough for everyone
24− mount -o rw,nosuid,nodev,exec,relatime,mode=755,size=512k -t tmpfs tmpfs "$RUNDIR"
25− cp -a /usr/bin/unity8 "$RUNDIR"
26− setcap CAP_SYS_RESOURCE=+ep "$RUNDIR/unity8"
27− # bind-mount this back as unity8 checks dirname(argv[0]'s) == /usr to
28− # decide whether it's installed or not
29− mount --bind "$RUNDIR/unity8" /usr/bin/unity8
30− fi
31−end script
32−
debian/changelog+115−2
@@ -1,8 +1,121 @@
1−unity8 (7.83) UNRELEASED; urgency=low
1+unity8 (7.83+14.04.20131028.1-0ubuntu1) trusty; urgency=low
2
2
3+ * New rebuild forced
4+ * Automatic snapshot from revision 480
5+
6+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Mon, 28 Oct 2013 22:42:07 +0000
7+
8+unity8 (7.83+14.04.20131028-0ubuntu1) trusty; urgency=low
9+
10+ [ Andrea Cimitan ]
11+ * Fix 1195349 by counting drawbuffer on the newContentX logic of the
12+ carousel When we changed carousel from repeater to listview, we
13+ added drawbuffer. this breaks the logic of newContentX, which was
14+ considered disabled and set to -1. The correct disabled value now
15+ has to take into account the drawbuffer. (LP: #1195349)
16+
17+ [ Christopher Lee ]
18+ * Checks both then env and upstart env for the currently set
19+ XDG_DATA_DIRS so they can be set correctly for the test.
20+
21+ [ Ubuntu daily release ]
22+ * Automatic snapshot from revision 479
23+
24+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Mon, 28 Oct 2013 03:08:59 +0000
25+
26+unity8 (7.83+13.10.20131016.2-0ubuntu1) saucy; urgency=low
27+
28+ [ Loïc Minier ]
29+ * Merge ~lool/unity8/drop-setcap-conf. Drop unity8-setcap.conf as this
30+ breaks desktop installs (no boot-hook event is emitted, boot
31+ stalls); add maintscript snippet to rm_conffile on upgrades; this
32+ boot-hook is now shipped under a different name in lxc-android-
33+ config.
34+
35+ [ Michał Sawicz ]
36+ * Ship a camera-app.desktop file and use a custom XDG_DATA_DIRS for
37+ testing.
38+
39+ [ Ubuntu daily release ]
40+ * Automatic snapshot from revision 472
41+
42+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Wed, 16 Oct 2013 23:15:48 +0000
43+
44+unity8 (7.83+13.10.20131016.1-0ubuntu1) saucy; urgency=low
45+
46+ [ Diego Sarmentero ]
47+ * Disable Preview interaction until the scope responds.
48+
49+ [ Albert Astals ]
50+ * Hide placeholder notification.
51+
52+ [ Ubuntu daily release ]
53+ * Automatic snapshot from revision 469
54+
55+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Wed, 16 Oct 2013 17:29:36 +0000
56+
57+unity8 (7.83+13.10.20131016-0ubuntu1) saucy; urgency=low
58+
59+ [ Loïc Minier ]
60+ * Add upstart job to copy unity8 to a new tmpfs, setcap it, and bind-
61+ mount it back; this is an ugly hack to set CAP_SYS_RESOURCE until we
62+ have a root-helper for it.
63+
64+ [ Michal Hruby ]
65+ * Enable definition of scope back references in overridden results.
66+
67+ [ Ubuntu daily release ]
68+ * Automatic snapshot from revision 466
69+
70+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Wed, 16 Oct 2013 11:29:52 +0000
71+
72+unity8 (7.83+13.10.20131015.4-0ubuntu1) saucy; urgency=low
73+
74+ [ Michał Sawicz ]
3 * Replace ubuntu-touch-session's unity8.conf upstart job.
75 * Replace ubuntu-touch-session's unity8.conf upstart job.
76+ * Revert r440 that made the dash collapse animation worse, rather than
77+ better.
78+
79+ [ om26er@ubuntu.com ]
80+ * close the app only when the close button is tapped, not the entire
81+ thumbnail
82+
83+ [ Nick Dedekind ]
84+ * Added missing Unity.Indicator mock objects causing qmltests to fail.
85+ Approved by: Michał Sawicz.
86+
87+ [ Christopher Lee ]
88+ * Launch unity8 for autopilot with upstart, and bring unity8 session
89+ over from session-manager-touch.
90+
91+ [ Pawel Stolowski ]
92+ * Temporarily disable category_order changed signal handling.
93+
94+ [ Daniel d'Andrada ]
95+ * OSKController area shouldn't cover the indicators' bar Since ubuntu-
96+ keyboard surface area doesn't cover the indicators' bar,
97+ OSKController should follow suit. Otherwise the OSKContoller's
98+ internal InputFilterArea (and others) wouldn't perfectly overlap the
99+ graphical keyboard rendered by ubuntu-keyboard (i.e. the opaque part
100+ of ubuntu-keyboard's surface).
101+
102+ [ Michael Zanetti ]
103+ * Initialize initialHeight/Width to height/width depending on scaleTo
104+ add checks for initialWidth/Height in the tests change sizes in
105+ tests to something else than the default for initialWidth/Height in
106+ order to catch failures there more easily
107+
108+ [ Omer Akram ]
109+ * Only show search indicator while the Dash is focued.
110+ * Add 2dp left margin for music and video tiles' title.
111+
112+ [ Nicolas d'Offay ]
113+ * Changed Infographics to use Ubuntu font.
114+
115+ [ Ubuntu daily release ]
116+ * Automatic snapshot from revision 463
4
117
5− -- Michał Sawicz <michal.sawicz@canonical.com> Tue, 15 Oct 2013 01:12:45 +0200
118+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Tue, 15 Oct 2013 11:05:04 +0000
6
119
7unity8 (7.82+13.10.20131011.2-0ubuntu1) saucy; urgency=low
120unity8 (7.82+13.10.20131011.2-0ubuntu1) saucy; urgency=low
8
121
debian/unity8-fake-env.install+1
@@ -1 +1,2 @@
1usr/lib/*/unity8/qml/mocks
1usr/lib/*/unity8/qml/mocks
2+usr/share/unity8/mocks
debian/unity8.install−1
@@ -13,4 +13,3 @@ usr/share/unity8/Shell.qml
13usr/share/unity8/SideStage
13usr/share/unity8/SideStage
14usr/share/unity8/graphics
14usr/share/unity8/graphics
15data/unity8.conf usr/share/upstart/sessions/
15data/unity8.conf usr/share/upstart/sessions/
16−data/unity8-setcap.conf etc/init/boot-hooks/
debian/unity8.maintscriptnew file+1
@@ -0,0 +1 @@
1+rm_conffile /etc/init/boot-hooks/unity8-setcap.conf
plugins/Unity/scope.cpp+10−1
@@ -28,6 +28,7 @@
28
28
29// Qt
29// Qt
30#include <QUrl>
30#include <QUrl>
31+#include <QUrlQuery>
31#include <QDebug>
32#include <QDebug>
32#include <QtGui/QDesktopServices>
33#include <QtGui/QDesktopServices>
33#include <QQmlEngine>
34#include <QQmlEngine>
@@ -203,7 +204,13 @@ void Scope::preview(const QVariant &uri, const QVariant &icon_hint, const QVaria
203 const QVariant &result_type, const QVariant &mimetype, const QVariant &title,
204 const QVariant &result_type, const QVariant &mimetype, const QVariant &title,
204 const QVariant &comment, const QVariant &dnd_uri, const QVariant &metadata)
205 const QVariant &comment, const QVariant &dnd_uri, const QVariant &metadata)
205{
206{
207+ QVariant real_metadata(metadata);
208+ // handle overridden results, since QML doesn't support defining maps
209+ if (metadata.type() == QVariant::String) {
210+ real_metadata = QVariant::fromValue(subscopeUriToMetadataHash(metadata.toString()));
211+ }
212+
206− auto res = createLocalResult(uri, icon_hint, category, result_type, mimetype, title, comment, dnd_uri, metadata);
213+ auto res = createLocalResult(uri, icon_hint, category, result_type, mimetype, title, comment, dnd_uri, real_metadata);
207 m_previewCancellable.Renew();
214 m_previewCancellable.Renew();
208
215
209 // canned queries don't have previews, must be activated
216 // canned queries don't have previews, must be activated
@@ -221,6 +228,7 @@ void Scope::cancelActivation()
221
228
222void Scope::onActivated(unity::dash::LocalResult const& result, unity::dash::ScopeHandledType type, unity::glib::HintsMap const& hints)
229void Scope::onActivated(unity::dash::LocalResult const& result, unity::dash::ScopeHandledType type, unity::glib::HintsMap const& hints)
223{
230{
231+ Q_EMIT activated();
224 // note: we will not get called on SHOW_PREVIEW, instead UnityCore will signal preview_ready.
232 // note: we will not get called on SHOW_PREVIEW, instead UnityCore will signal preview_ready.
225 switch (type)
233 switch (type)
226 {
234 {
@@ -254,6 +262,7 @@ void Scope::onActivated(unity::dash::LocalResult const& result, unity::dash::Sco
254
262
255void Scope::onPreviewReady(unity::dash::LocalResult const& /* result */, unity::dash::Preview::Ptr const& preview)
263void Scope::onPreviewReady(unity::dash::LocalResult const& /* result */, unity::dash::Preview::Ptr const& preview)
256{
264{
265+ Q_EMIT activated();
257 auto prv = Preview::newFromUnityPreview(preview);
266 auto prv = Preview::newFromUnityPreview(preview);
258 // is this the best solution? QML may need to keep more than one preview instance around, so we can't own it.
267 // is this the best solution? QML may need to keep more than one preview instance around, so we can't own it.
259 // passing it by value is not possible.
268 // passing it by value is not possible.
plugins/Unity/scope.h+1
@@ -117,6 +117,7 @@ Q_SIGNALS:
117 void showDash();
117 void showDash();
118 void hideDash();
118 void hideDash();
119 void gotoUri(const QString &uri);
119 void gotoUri(const QString &uri);
120+ void activated();
120
121
121 void activateApplication(const QString &desktop);
122 void activateApplication(const QString &desktop);
122
123
plugins/Unity/variantutils.cpp+31
@@ -17,6 +17,10 @@
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
18 */
19
19
20+#include <QUrl>
21+#include <QUrlQuery>
22+#include <QStringList>
23+
20#include <deelistmodel.h>
24#include <deelistmodel.h>
21#include "variantutils.h"
25#include "variantutils.h"
22
26
@@ -49,3 +53,30 @@ QVariantHash convertToQVariantHash(const unity::glib::HintsMap& var)
49 }
53 }
50 return hash;
54 return hash;
51}
55}
56+
57+/* This will translate uris in the form of:
58+ * "subscope:master.scope/sub.scope?foo=bar"
59+ * into a QVariantHash that can be passed as a metadata field to scope.
60+ */
61+QVariantHash subscopeUriToMetadataHash(const QString &metadata_string)
62+{
63+ QUrl metadata_url(metadata_string);
64+ if (metadata_url.scheme() == QLatin1String("subscope")) {
65+ QString subscope_uri(metadata_url.toString(QUrl::RemoveScheme | QUrl::RemoveQuery));
66+ QVariantHash new_metadata;
67+ QUrlQuery query(metadata_url.query());
68+ QList<QPair<QString,QString>> queryItems(query.queryItems());
69+ for (auto it = queryItems.begin(); it != queryItems.end(); ++it) {
70+ new_metadata[it->first] = QVariant::fromValue(it->second);
71+ }
72+ QStringList parts(subscope_uri.split(QChar('/')));
73+ for (int i = parts.size() - 1; i >= 0; i--) {
74+ QVariantHash inner;
75+ inner["scope-id"] = QVariant::fromValue(parts[i]);
76+ inner["content"] = QVariant::fromValue(new_metadata);
77+ new_metadata = inner;
78+ }
79+ return new_metadata;
80+ }
81+ return QVariantHash();
82+}
plugins/Unity/variantutils.h+3−1
@@ -28,6 +28,8 @@
28
28
29unity::glib::HintsMap convertToHintsMap(const QHash<QString, QVariant> &val);
29unity::glib::HintsMap convertToHintsMap(const QHash<QString, QVariant> &val);
30unity::glib::HintsMap convertToHintsMap(const QVariant &var);
30unity::glib::HintsMap convertToHintsMap(const QVariant &var);
31−QVariantHash convertToQVariantHash(const unity::glib::HintsMap& var);
31+QVariantHash convertToQVariantHash(const unity::glib::HintsMap &var);
32+/* used in tests, so we have to export it */
33+Q_DECL_EXPORT QVariantHash subscopeUriToMetadataHash(const QString &metadata_string);
32
34
33#endif
35#endif
po/ar.po+33−44
@@ -8,7 +8,7 @@ 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-10-11 12:12+0200\n"
10"POT-Creation-Date: 2013-10-11 12:12+0200\n"
11−"PO-Revision-Date: 2013-06-26 23:26+0000\n"
11+"PO-Revision-Date: 2013-10-20 19:41+0000\n"
12"Last-Translator: Ibrahim Saed <ibraheem5000@gmail.com>\n"
12"Last-Translator: Ibrahim Saed <ibraheem5000@gmail.com>\n"
13"Language-Team: Arabic <ar@li.org>\n"
13"Language-Team: Arabic <ar@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
@@ -16,8 +16,8 @@ msgstr ""
16"Content-Transfer-Encoding: 8bit\n"
16"Content-Transfer-Encoding: 8bit\n"
17"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n % 100 >= "
17"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n % 100 >= "
18"3 && n % 100 <= 10 ? 3 : n % 100 >= 11 && n % 100 <= 99 ? 4 : 5;\n"
18"3 && n % 100 <= 10 ? 3 : n % 100 >= 11 && n % 100 <= 99 ? 4 : 5;\n"
19−"X-Launchpad-Export-Date: 2013-10-13 05:43+0000\n"
19+"X-Launchpad-Export-Date: 2013-10-21 05:04+0000\n"
20−"X-Generator: Launchpad (build 16799)\n"
20+"X-Generator: Launchpad (build 16807)\n"
21
21
22#: Applications/applications.js:23
22#: Applications/applications.js:23
23msgid "Phone"
23msgid "Phone"
@@ -65,7 +65,7 @@ msgstr "مشغّل الوسائط"
65
65
66#: Applications/applications.js:86
66#: Applications/applications.js:86
67msgid "Evernote"
67msgid "Evernote"
68−msgstr ""
68+msgstr "Evernote"
69
69
70#: Applications/applications.js:91
70#: Applications/applications.js:91
71msgid "Map"
71msgid "Map"
@@ -73,11 +73,11 @@ msgstr "الخريطة"
73
73
74#: Applications/applications.js:96
74#: Applications/applications.js:96
75msgid "Pinterest"
75msgid "Pinterest"
76−msgstr ""
76+msgstr "Pinterest"
77
77
78#: Applications/applications.js:101
78#: Applications/applications.js:101
79msgid "SoundCloud"
79msgid "SoundCloud"
80−msgstr ""
80+msgstr "SoundCloud"
81
81
82#: Applications/applications.js:106
82#: Applications/applications.js:106
83msgid "Wikipedia"
83msgid "Wikipedia"
@@ -89,49 +89,52 @@ msgstr "يوتيوب"
89
89
90#: Components/EdgeDemoOverlay.qml:149
90#: Components/EdgeDemoOverlay.qml:149
91msgid "Skip intro"
91msgid "Skip intro"
92−msgstr ""
92+msgstr "تخطي المقدمة"
93
93
94#: Components/EdgeDemo.qml:112
94#: Components/EdgeDemo.qml:112
95msgid "Right edge"
95msgid "Right edge"
96−msgstr ""
96+msgstr "الحافة اليمنى"
97
97
98#: Components/EdgeDemo.qml:113
98#: Components/EdgeDemo.qml:113
99msgid "Try swiping from the right edge to unlock the phone"
99msgid "Try swiping from the right edge to unlock the phone"
100−msgstr ""
100+msgstr "اسحب اصبعك من الحافة اليمنى لفتح قفل الهاتف"
101
101
102#: Components/EdgeDemo.qml:144
102#: Components/EdgeDemo.qml:144
103msgid "Top edge"
103msgid "Top edge"
104−msgstr ""
104+msgstr "الحافة العلوية"
105
105
106#: Components/EdgeDemo.qml:145
106#: Components/EdgeDemo.qml:145
107msgid "Try swiping from the top edge to access the indicators"
107msgid "Try swiping from the top edge to access the indicators"
108−msgstr ""
108+msgstr "اسحب اصبعك من الحافة العلوية للوصول إلى المؤشرات"
109
109
110#: Components/EdgeDemo.qml:170
110#: Components/EdgeDemo.qml:170
111msgid "Close"
111msgid "Close"
112−msgstr ""
112+msgstr "أغلق"
113
113
114#: Components/EdgeDemo.qml:171
114#: Components/EdgeDemo.qml:171
115msgid "Swipe up again to close the settings screen"
115msgid "Swipe up again to close the settings screen"
116−msgstr ""
116+msgstr "اسحب اصعبك لأعلى مرة أخرى لغلق شاشة الإعدادات"
117
117
118#: Components/EdgeDemo.qml:198
118#: Components/EdgeDemo.qml:198
119msgid "Left edge"
119msgid "Left edge"
120−msgstr ""
120+msgstr "الحافة اليسرى"
121
121
122#: Components/EdgeDemo.qml:199
122#: Components/EdgeDemo.qml:199
123msgid "Swipe from the left to reveal the launcher for quick access to apps"
123msgid "Swipe from the left to reveal the launcher for quick access to apps"
124msgstr ""
124msgstr ""
125+"اسحب أصبعك من الحافة اليسرى لإظهار شريط يونتي للوصول السريع للتطبيقات"
125
126
126#: Components/EdgeDemo.qml:226
127#: Components/EdgeDemo.qml:226
127msgid "Well done"
128msgid "Well done"
128−msgstr ""
129+msgstr "أحسنت!"
129
130
130#: Components/EdgeDemo.qml:227
131#: Components/EdgeDemo.qml:227
131msgid ""
132msgid ""
132"You have now mastered the edge gestures and can start using the "
133"You have now mastered the edge gestures and can start using the "
133"phone<br><br>Tap anywhere to start"
134"phone<br><br>Tap anywhere to start"
134msgstr ""
135msgstr ""
136+"لقد أتقنت الآن إيماءات الحواف ويمكنك البدء باستخدام الهاتف<br><br>انقر في أي "
137+"مكان للبدء"
135
138
136#: Components/PageHeader.qml:341
139#: Components/PageHeader.qml:341
137msgid "Recent searches"
140msgid "Recent searches"
@@ -142,7 +145,7 @@ msgstr "عمليات البحث الأخيرة"
142#: Dash/Apps/AppInfo.qml:73 Dash/Previews/Header.qml:93
145#: Dash/Apps/AppInfo.qml:73 Dash/Previews/Header.qml:93
143#, qt-format
146#, qt-format
144msgid "(%1)"
147msgid "(%1)"
145−msgstr ""
148+msgstr "(%1)"
146
149
147#. TRANSLATORS: Number of persons who wrote reviews for this app
150#. TRANSLATORS: Number of persons who wrote reviews for this app
148#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
151#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
@@ -150,32 +153,36 @@ msgstr ""
150#, qt-format
153#, qt-format
151msgid "%1 review"
154msgid "%1 review"
152msgid_plural "%1 reviews"
155msgid_plural "%1 reviews"
153−msgstr[0] ""
156+msgstr[0] "لا تعليقات (%1)"
157+msgstr[1] "تعليق واحد (%1)"
158+msgstr[2] "تعليقان (%1)"
154−msgstr[1] ""
159+msgstr[3] "%1 تعليقات"
160+msgstr[4] "%1 تعليقا"
161+msgstr[5] "%1 تعليق"
155
162
156#: Dash/Apps/AppPreview.qml:126
163#: Dash/Apps/AppPreview.qml:126
157msgid "Rate this"
164msgid "Rate this"
158−msgstr ""
165+msgstr "قيّم ذلك"
159
166
160#: Dash/Previews/Reviews.qml:74
167#: Dash/Previews/Reviews.qml:74
161msgid "Add a review"
168msgid "Add a review"
162−msgstr ""
169+msgstr "أضف تعليق"
163
170
164#: Dash/Previews/Reviews.qml:86
171#: Dash/Previews/Reviews.qml:86
165msgid "Review"
172msgid "Review"
166−msgstr ""
173+msgstr "التعليق"
167
174
168#: Dash/Previews/Reviews.qml:121
175#: Dash/Previews/Reviews.qml:121
169msgid "Send"
176msgid "Send"
170−msgstr ""
177+msgstr "أرسل"
171
178
172#: Dash/Previews/Reviews.qml:139
179#: Dash/Previews/Reviews.qml:139
173msgid "Comments:"
180msgid "Comments:"
174−msgstr ""
181+msgstr "التعليقات:"
175
182
176#: Greeter/Lockscreen.qml:142
183#: Greeter/Lockscreen.qml:142
177msgid "Emergency Call"
184msgid "Emergency Call"
178−msgstr ""
185+msgstr "مكالمة طوارئ"
179
186
180#: Greeter/PassphraseLockscreen.qml:59
187#: Greeter/PassphraseLockscreen.qml:59
181#, qt-format
188#, qt-format
@@ -216,27 +223,9 @@ msgstr "عذراً، لا يوجد ما يطابق بحثك."
216
223
217#: plugins/Unity/showallfilteroption.cpp:41
224#: plugins/Unity/showallfilteroption.cpp:41
218msgid "All"
225msgid "All"
219−msgstr ""
226+msgstr "الكل"
220
227
221#: Shell.qml:438
228#: Shell.qml:438
222#, qt-format
229#, qt-format
223msgid "Please enter %1"
230msgid "Please enter %1"
224−msgstr ""
231+msgstr "من فضلك أدخِل %1"
225−
226−#~ msgid "Featured"
227−#~ msgstr "المميز"
228−
229−#~ msgid "Recent"
230−#~ msgstr "الحديث"
231−
232−#~ msgid "New Releases"
233−#~ msgstr "الإصدارات الجديدة"
234−
235−#~ msgid "Music"
236−#~ msgstr "موسيقى"
237−
238−#~ msgid "Popular Online"
239−#~ msgstr "الشائع على الإنترنت"
240−
241−#~ msgid "Videos"
242−#~ msgstr "فيديوهات"
po/de.po+11−28
@@ -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-10-11 12:12+0200\n"
10"POT-Creation-Date: 2013-10-11 12:12+0200\n"
11−"PO-Revision-Date: 2013-10-06 10:57+0000\n"
11+"PO-Revision-Date: 2013-10-18 12:26+0000\n"
12−"Last-Translator: SaGrLand <sg@samuel-greef.de>\n"
12+"Last-Translator: Phillip Sz <Unknown>\n"
13"Language-Team: German <de@li.org>\n"
13"Language-Team: German <de@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-10-13 05:43+0000\n"
18+"X-Launchpad-Export-Date: 2013-10-19 05:30+0000\n"
19−"X-Generator: Launchpad (build 16799)\n"
19+"X-Generator: Launchpad (build 16807)\n"
20
20
21#: Applications/applications.js:23
21#: Applications/applications.js:23
22msgid "Phone"
22msgid "Phone"
@@ -96,7 +96,7 @@ msgstr "Rechter Rand"
96
96
97#: Components/EdgeDemo.qml:113
97#: Components/EdgeDemo.qml:113
98msgid "Try swiping from the right edge to unlock the phone"
98msgid "Try swiping from the right edge to unlock the phone"
99−msgstr ""
99+msgstr "Vom rechten Rand her wischen, um das Gerät zu entsperren"
100
100
101#: Components/EdgeDemo.qml:144
101#: Components/EdgeDemo.qml:144
102msgid "Top edge"
102msgid "Top edge"
@@ -104,7 +104,7 @@ msgstr "Oberer Rand"
104
104
105#: Components/EdgeDemo.qml:145
105#: Components/EdgeDemo.qml:145
106msgid "Try swiping from the top edge to access the indicators"
106msgid "Try swiping from the top edge to access the indicators"
107−msgstr ""
107+msgstr "Vom oberen Rand her wischen, um die Statusmeldungen anzuzeigen"
108
108
109#: Components/EdgeDemo.qml:170
109#: Components/EdgeDemo.qml:170
110msgid "Close"
110msgid "Close"
@@ -112,7 +112,7 @@ msgstr "Schließen"
112
112
113#: Components/EdgeDemo.qml:171
113#: Components/EdgeDemo.qml:171
114msgid "Swipe up again to close the settings screen"
114msgid "Swipe up again to close the settings screen"
115−msgstr ""
115+msgstr "Nochmals nach oben wischen, um das Einstellungsmenü zu schließen"
116
116
117#: Components/EdgeDemo.qml:198
117#: Components/EdgeDemo.qml:198
118msgid "Left edge"
118msgid "Left edge"
@@ -121,6 +121,8 @@ msgstr "Linker Rand"
121#: Components/EdgeDemo.qml:199
121#: Components/EdgeDemo.qml:199
122msgid "Swipe from the left to reveal the launcher for quick access to apps"
122msgid "Swipe from the left to reveal the launcher for quick access to apps"
123msgstr ""
123msgstr ""
124+"Von links wischen, um die Seitenleiste für den Anwendungs-Schnellzugriff "
125+"aufzurufen"
124
126
125#: Components/EdgeDemo.qml:226
127#: Components/EdgeDemo.qml:226
126msgid "Well done"
128msgid "Well done"
@@ -131,6 +133,8 @@ msgid ""
131"You have now mastered the edge gestures and can start using the "
133"You have now mastered the edge gestures and can start using the "
132"phone<br><br>Tap anywhere to start"
134"phone<br><br>Tap anywhere to start"
133msgstr ""
135msgstr ""
136+"Sie haben nun die Einführung abgeschlossen und können Ihr Gerät nun "
137+"verwenden<br><br>Antippen um zu starten"
134
138
135#: Components/PageHeader.qml:341
139#: Components/PageHeader.qml:341
136msgid "Recent searches"
140msgid "Recent searches"
@@ -221,24 +225,3 @@ msgstr "Alle"
221#, qt-format
225#, qt-format
222msgid "Please enter %1"
226msgid "Please enter %1"
223msgstr "Bitte geben Sie %1 ein"
227msgstr "Bitte geben Sie %1 ein"
224−
225−#~ msgid "Featured"
226−#~ msgstr "Empfehlungen"
227−
228−#~ msgid "Recent"
229−#~ msgstr "Zuletzt verwendet"
230−
231−#~ msgid "New Releases"
232−#~ msgstr "Neue Veröffentlichungen"
233−
234−#~ msgid "Top Charting"
235−#~ msgstr "Top Tabellenplatz"
236−
237−#~ msgid "Music"
238−#~ msgstr "Musik"
239−
240−#~ msgid "Popular Online"
241−#~ msgstr "Online Beliebt"
242−
243−#~ msgid "Videos"
244−#~ msgstr "Videos"
po/ta.ponew file+229
@@ -0,0 +1,229 @@
1+# Tamil translation for unity8
2+# Copyright (c) 2013 Rosetta Contributors and Canonical Ltd 2013
3+# This file is distributed under the same license as the unity8 package.
4+# FIRST AUTHOR <EMAIL@ADDRESS>, 2013.
5+# துளசி <Thangamani Arun<thangam.arunx@gmail.com>>, 2013.
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-10-11 12:12+0200\n"
11+"PO-Revision-Date: 2013-10-24 11:36+0000\n"
12+"Last-Translator: Thangamani Arun - தங்கமணி அருண் <thangam.arunx@gmail.com>\n"
13+"Language-Team: Ubuntu Tamil Team/Free Tamil Computing/Thamizha\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=2; plural=n != 1;\n"
18+"X-Launchpad-Export-Date: 2013-10-25 06:05+0000\n"
19+"X-Generator: Launchpad (build 16810)\n"
20+"Language: ta\n"
21+
22+#: Applications/applications.js:23
23+msgid "Phone"
24+msgstr "தொலைபேசி"
25+
26+#: Applications/applications.js:29
27+msgid "Camera"
28+msgstr "புகைப்பட கருவி"
29+
30+#: Applications/applications.js:35
31+msgid "Gallery"
32+msgstr "படத்தொகுப்பு"
33+
34+#: Applications/applications.js:40
35+msgid "Facebook"
36+msgstr "முகநுல்"
37+
38+#: Applications/applications.js:46
39+msgid "Browser"
40+msgstr "உலாவி"
41+
42+#: Applications/applications.js:51
43+msgid "Twitter"
44+msgstr "ட்விட்டர்"
45+
46+#: Applications/applications.js:57
47+msgid "GMail"
48+msgstr "ஜிமெயில்"
49+
50+#: Applications/applications.js:62
51+msgid "Weather"
52+msgstr "வானிலை"
53+
54+#: Applications/applications.js:68
55+msgid "Notepad"
56+msgstr "குறிப்புபலகை"
57+
58+#: Applications/applications.js:74
59+msgid "Calendar"
60+msgstr "நாள்காட்டி"
61+
62+#: Applications/applications.js:80
63+msgid "Media Player"
64+msgstr "ஊடக இயக்கி"
65+
66+#: Applications/applications.js:86
67+msgid "Evernote"
68+msgstr "எப்போதும்குறிப்பெடு"
69+
70+#: Applications/applications.js:91
71+msgid "Map"
72+msgstr "வரைபடம்"
73+
74+#: Applications/applications.js:96
75+msgid "Pinterest"
76+msgstr "விசைத்தட்டு"
77+
78+#: Applications/applications.js:101
79+msgid "SoundCloud"
80+msgstr "ஒலி கிளவுட்"
81+
82+#: Applications/applications.js:106
83+msgid "Wikipedia"
84+msgstr "விக்கிப்பீடியா"
85+
86+#: Applications/applications.js:111
87+msgid "YouTube"
88+msgstr "யூட்யுப்"
89+
90+#: Components/EdgeDemoOverlay.qml:149
91+msgid "Skip intro"
92+msgstr "அறிமுகத்தை தவிர்"
93+
94+#: Components/EdgeDemo.qml:112
95+msgid "Right edge"
96+msgstr "வலது விளிம்பு"
97+
98+#: Components/EdgeDemo.qml:113
99+msgid "Try swiping from the right edge to unlock the phone"
100+msgstr "தொலைபேசியை திறக்க வலது முனையிலிருந்து தேய்த்து முயற்சி செய்"
101+
102+#: Components/EdgeDemo.qml:144
103+msgid "Top edge"
104+msgstr "மேல் விளிம்பு"
105+
106+#: Components/EdgeDemo.qml:145
107+msgid "Try swiping from the top edge to access the indicators"
108+msgstr "காட்டிகளை அனுக மேல் விளிம்பிலிருந்து தேய்த்து முயற்சி செய்"
109+
110+#: Components/EdgeDemo.qml:170
111+msgid "Close"
112+msgstr "மூடு"
113+
114+#: Components/EdgeDemo.qml:171
115+msgid "Swipe up again to close the settings screen"
116+msgstr "அமைவுகளின் திரையை மூட மறுபடியும் மேலே தேய்க்கவும்"
117+
118+#: Components/EdgeDemo.qml:198
119+msgid "Left edge"
120+msgstr "இடது விளிம்பு"
121+
122+#: Components/EdgeDemo.qml:199
123+msgid "Swipe from the left to reveal the launcher for quick access to apps"
124+msgstr ""
125+"பயன்பாடுகளின் விரைவான அணுகலை பெறத்தேவையான தொடக்கியை இடமிருந்து தேய்த்தால் "
126+"வெளிப்படும்"
127+
128+#: Components/EdgeDemo.qml:226
129+msgid "Well done"
130+msgstr "நன்றாக செய்தீர்கள்"
131+
132+#: Components/EdgeDemo.qml:227
133+msgid ""
134+"You have now mastered the edge gestures and can start using the "
135+"phone<br><br>Tap anywhere to start"
136+msgstr ""
137+"நீங்கள் இப்போது விளிம்பு சைகைகளில் கைதேர்ந்தவர் மற்றும் தொலைபேசி "
138+"பயன்படுத்த தொடங்கவும் <br> <br>தட்டுவதன் மூலம் எங்க வேண்டுமானாலும் "
139+"தொடங்கலாம்."
140+
141+#: Components/PageHeader.qml:341
142+msgid "Recent searches"
143+msgstr "கடையாக தேடப்பட்டவைகள்"
144+
145+#. TRANSLATORS: Number of persons who rated this app
146+#. TRANSLATORS: Number of persons who rated this app/video/whatever
147+#: Dash/Apps/AppInfo.qml:73 Dash/Previews/Header.qml:93
148+#, qt-format
149+msgid "(%1)"
150+msgstr "(%1)"
151+
152+#. TRANSLATORS: Number of persons who wrote reviews for this app
153+#. TRANSLATORS: Number of persons who wrote reviews for this app/video/whatever
154+#: Dash/Apps/AppInfo.qml:85 Dash/Previews/Header.qml:105
155+#, qt-format
156+msgid "%1 review"
157+msgid_plural "%1 reviews"
158+msgstr[0] "%1 பரிசீலனை"
159+msgstr[1] "%1 பரிசீலனைகள்"
160+
161+#: Dash/Apps/AppPreview.qml:126
162+msgid "Rate this"
163+msgstr "இதை மதிப்பிடு"
164+
165+#: Dash/Previews/Reviews.qml:74
166+msgid "Add a review"
167+msgstr "ஒரு பரிசீலனையை சேர்"
168+
169+#: Dash/Previews/Reviews.qml:86
170+msgid "Review"
171+msgstr "மறுஆய்வு"
172+
173+#: Dash/Previews/Reviews.qml:121
174+msgid "Send"
175+msgstr "அனுப்பு"
176+
177+#: Dash/Previews/Reviews.qml:139
178+msgid "Comments:"
179+msgstr "கருத்துகள்:"
180+
181+#: Greeter/Lockscreen.qml:142
182+msgid "Emergency Call"
183+msgstr "அவசர அழைப்பு"
184+
185+#: Greeter/PassphraseLockscreen.qml:59
186+#, qt-format
187+msgid "Hello %1"
188+msgstr "வணக்கம் %1"
189+
190+#: Greeter/PassphraseLockscreen.qml:59
191+msgid "Hello"
192+msgstr "வணக்கம்"
193+
194+#: Hud/HudParametrizedActionsPage.qml:132
195+msgid "Confirm"
196+msgstr "உறுதிப்படுத்து"
197+
198+#: Hud/Hud.qml:61 Hud/Hud.qml:99 Hud/Hud.qml:372
199+msgid "Type or say a command"
200+msgstr "ஒரு கட்டளையை உச்சரி அல்லது தட்டச்சுசெய்"
201+
202+#: Hud/Hud.qml:84
203+msgid "Loading. Please Wait..."
204+msgstr "ஏற்றுகிறது. தயைசெய்து காத்திருக்கவும்..."
205+
206+#: Hud/Hud.qml:89
207+msgid "Speak Now..."
208+msgstr "இப்பொது பேசு..."
209+
210+#: Hud/Hud.qml:94
211+msgid "Speaking..."
212+msgstr "பேசுகிறது..."
213+
214+#: Panel/SearchIndicator.qml:27
215+msgid "Search"
216+msgstr "தெடு"
217+
218+#: plugins/Unity/scope.cpp:398
219+msgid "Sorry, there is nothing that matches your search."
220+msgstr "மன்னிக்கவும், உங்களுடைய தேடலுக்கு தகுந்த பொருத்தம் கிடைக்கவில்லை."
221+
222+#: plugins/Unity/showallfilteroption.cpp:41
223+msgid "All"
224+msgstr "அனைத்தும்"
225+
226+#: Shell.qml:438
227+#, qt-format
228+msgid "Please enter %1"
229+msgstr "தயவுச்செய்து %1 உள்ளிடு"
po/uk.po+6−25
@@ -8,7 +8,7 @@ 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-10-11 12:12+0200\n"
10"POT-Creation-Date: 2013-10-11 12:12+0200\n"
11−"PO-Revision-Date: 2013-09-28 07:54+0000\n"
11+"PO-Revision-Date: 2013-10-19 16:44+0000\n"
12"Last-Translator: Yuri Chornoivan <yurchor@gmail.com>\n"
12"Last-Translator: Yuri Chornoivan <yurchor@gmail.com>\n"
13"Language-Team: Ukrainian <uk@li.org>\n"
13"Language-Team: Ukrainian <uk@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
@@ -16,8 +16,8 @@ msgstr ""
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: 2013-10-13 05:43+0000\n"
19+"X-Launchpad-Export-Date: 2013-10-20 05:20+0000\n"
20−"X-Generator: Launchpad (build 16799)\n"
20+"X-Generator: Launchpad (build 16807)\n"
21
21
22#: Applications/applications.js:23
22#: Applications/applications.js:23
23msgid "Phone"
23msgid "Phone"
@@ -135,6 +135,8 @@ msgid ""
135"You have now mastered the edge gestures and can start using the "
135"You have now mastered the edge gestures and can start using the "
136"phone<br><br>Tap anywhere to start"
136"phone<br><br>Tap anywhere to start"
137msgstr ""
137msgstr ""
138+"Тепер жести налаштовано, ви можете почати користуватися "
139+"телефоном.<br><br>Натисніть у довільному місці екрана."
138
140
139#: Components/PageHeader.qml:341
141#: Components/PageHeader.qml:341
140msgid "Recent searches"
142msgid "Recent searches"
@@ -220,30 +222,9 @@ msgstr "Вибачте, для вказаних вами ключових слі
220
222
221#: plugins/Unity/showallfilteroption.cpp:41
223#: plugins/Unity/showallfilteroption.cpp:41
222msgid "All"
224msgid "All"
223−msgstr ""
225+msgstr "Усе"
224
226
225#: Shell.qml:438
227#: Shell.qml:438
226#, qt-format
228#, qt-format
227msgid "Please enter %1"
229msgid "Please enter %1"
228msgstr "Будь ласка, введіть %1"
230msgstr "Будь ласка, введіть %1"
229−
230−#~ msgid "Featured"
231−#~ msgstr "Рекомендовані"
232−
233−#~ msgid "Recent"
234−#~ msgstr "Нещодавні"
235−
236−#~ msgid "New Releases"
237−#~ msgstr "Нові випуски"
238−
239−#~ msgid "Top Charting"
240−#~ msgstr "З високими оцінками"
241−
242−#~ msgid "Music"
243−#~ msgstr "Музика"
244−
245−#~ msgid "Popular Online"
246−#~ msgstr "Популярне у мережі"
247−
248−#~ msgid "Videos"
249−#~ msgstr "Відео"
tests/autopilot/unity8/__init__.py+46−1
@@ -52,7 +52,11 @@ def get_mocks_library_path():
52 if running_installed_tests():
52 if running_installed_tests():
53 mock_path = "qml/mocks/"
53 mock_path = "qml/mocks/"
54 else:
54 else:
55+ mock_path = os.path.join(
56+ "../lib/",
57+ sysconfig.get_config_var('MULTIARCH'),
55− mock_path = "../lib/x86_64-linux-gnu/unity8/qml/mocks/"
58+ "unity8/qml/mocks/"
59+ )
56 lib_path = get_lib_path()
60 lib_path = get_lib_path()
57 ld_library_path = os.path.abspath(
61 ld_library_path = os.path.abspath(
58 os.path.join(
62 os.path.join(
@@ -84,6 +88,47 @@ def get_binary_path(binary="unity8"):
84 return binary_path
88 return binary_path
85
89
86
90
91+def get_data_dirs():
92+ """Prepend a mock data path to XDG_DATA_DIRS."""
93+ if running_installed_tests():
94+ data_path = "/usr/share/unity8/mocks/data"
95+ else:
96+ data_path = "../../mocks/data"
97+ full_data_path = os.path.abspath(
98+ os.path.join(
99+ os.path.dirname(__file__),
100+ data_path
101+ )
102+ )
103+
104+ if os.path.exists(full_data_path):
105+ xdg_path = _get_xdg_env_path()
106+ if xdg_path is not None:
107+ return "{0}:{1}".format(full_data_path, xdg_path)
108+ else:
109+ return full_data_path
110+ else:
111+ return None
112+
113+
114+def _get_xdg_env_path():
115+ path = os.getenv("XDG_DATA_DIRS")
116+ if path is None:
117+ path = _get_xdg_upstart_env()
118+ return path
119+
120+
121+def _get_xdg_upstart_env():
122+ try:
123+ return subprocess.check_output([
124+ "/sbin/initctl",
125+ "get-env",
126+ "--global",
127+ "XDG_DATA_DIRS"
128+ ]).rstrip()
129+ except subprocess.CalledProcessError:
130+ return None
131+
87def get_grid_size():
132def get_grid_size():
88 grid_size = os.getenv('GRID_UNIT_PX')
133 grid_size = os.getenv('GRID_UNIT_PX')
89 if grid_size is None:
134 if grid_size is None:
tests/autopilot/unity8/shell/tests/__init__.py+8
@@ -41,6 +41,7 @@ from unity8 import (
41 get_binary_path,
41 get_binary_path,
42 get_mocks_library_path,
42 get_mocks_library_path,
43 get_default_extra_mock_libraries,
43 get_default_extra_mock_libraries,
44+ get_data_dirs
44)
45)
45from unity8.shell.emulators import UnityEmulatorBase
46from unity8.shell.emulators import UnityEmulatorBase
46from unity8.shell.emulators.dash import Dash
47from unity8.shell.emulators.dash import Dash
@@ -123,6 +124,8 @@ class UnityTestCase(AutopilotTestCase):
123 self._qml_mock_enabled = True
124 self._qml_mock_enabled = True
124 self._environment = {}
125 self._environment = {}
125
126
127+ self._patch_data_dirs()
128+
126 #### FIXME: This is a work around re: lp:1238417 ####
129 #### FIXME: This is a work around re: lp:1238417 ####
127 if model() != "Desktop":
130 if model() != "Desktop":
128 from autopilot.input import _uinput
131 from autopilot.input import _uinput
@@ -306,6 +309,11 @@ class UnityTestCase(AutopilotTestCase):
306 except subprocess.CalledProcessError:
309 except subprocess.CalledProcessError:
307 logger.warning("Appears unity was already stopped!")
310 logger.warning("Appears unity was already stopped!")
308
311
312+ def _patch_data_dirs(self):
313+ data_dirs = get_data_dirs()
314+ if data_dirs is not None:
315+ self._environment['XDG_DATA_DIRS'] = data_dirs
316+
309 def patch_lightdm_mock(self, mock_type='single'):
317 def patch_lightdm_mock(self, mock_type='single'):
310 self._lightdm_mock_type = mock_type
318 self._lightdm_mock_type = mock_type
311 logger.info("Setting up LightDM mock type '%s'", mock_type)
319 logger.info("Setting up LightDM mock type '%s'", mock_type)
tests/autopilot/unity8/shell/tests/test_notifications.py+10−9
@@ -143,7 +143,7 @@ class InteractiveNotificationBase(NotificationsBase):
143 hints,
143 hints,
144 )
144 )
145
145
146− get_notification = lambda: notify_list.select_single('Notification')
146+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
147 self.assertThat(get_notification, Eventually(NotEquals(None)))
147 self.assertThat(get_notification, Eventually(NotEquals(None)))
148 notification = get_notification()
148 notification = get_notification()
149
149
@@ -187,7 +187,7 @@ class InteractiveNotificationBase(NotificationsBase):
187 hints
187 hints
188 )
188 )
189
189
190− get_notification = lambda: notify_list.select_single('Notification')
190+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
191 self.assertThat(get_notification, Eventually(NotEquals(None)))
191 self.assertThat(get_notification, Eventually(NotEquals(None)))
192 notification = get_notification()
192 notification = get_notification()
193 self._assert_notification(notification, None, None, True, True, 1.0)
193 self._assert_notification(notification, None, None, True, True, 1.0)
@@ -354,7 +354,7 @@ class EphemeralNotificationsTests(NotificationsBase):
354
354
355 notification.show()
355 notification.show()
356
356
357− get_notification = lambda: notify_list.select_single('Notification')
357+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
358 self.assertThat(get_notification, Eventually(NotEquals(None)))
358 self.assertThat(get_notification, Eventually(NotEquals(None)))
359 notification = get_notification()
359 notification = get_notification()
360 self._assert_notification(notification, summary, body, True, True, 1.0)
360 self._assert_notification(notification, summary, body, True, True, 1.0)
@@ -383,7 +383,7 @@ class EphemeralNotificationsTests(NotificationsBase):
383
383
384 notification.show()
384 notification.show()
385
385
386− get_notification = lambda: notify_list.select_single('Notification')
386+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
387 self.assertThat(get_notification, Eventually(NotEquals(None)))
387 self.assertThat(get_notification, Eventually(NotEquals(None)))
388 notification = get_notification()
388 notification = get_notification()
389 self._assert_notification(
389 self._assert_notification(
@@ -496,7 +496,7 @@ class EphemeralNotificationsTests(NotificationsBase):
496 notification = self._create_ephemeral_notification(summary, body)
496 notification = self._create_ephemeral_notification(summary, body)
497 notification.show()
497 notification.show()
498
498
499− get_notification = lambda: notify_list.select_single('Notification')
499+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
500 self.assertThat(get_notification, Eventually(NotEquals(None)))
500 self.assertThat(get_notification, Eventually(NotEquals(None)))
501 notification = get_notification()
501 notification = get_notification()
502 self._assert_notification(
502 self._assert_notification(
@@ -519,7 +519,7 @@ class EphemeralNotificationsTests(NotificationsBase):
519 notification = self._create_ephemeral_notification(summary)
519 notification = self._create_ephemeral_notification(summary)
520 notification.show()
520 notification.show()
521
521
522− get_notification = lambda: notify_list.select_single('Notification')
522+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
523 self.assertThat(get_notification, Eventually(NotEquals(None)))
523 self.assertThat(get_notification, Eventually(NotEquals(None)))
524 notification = get_notification()
524 notification = get_notification()
525
525
@@ -585,7 +585,7 @@ class EphemeralNotificationsTests(NotificationsBase):
585 )
585 )
586 notification.show()
586 notification.show()
587
587
588− get_notification = lambda: notify_list.select_single('Notification')
588+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
589 self.assertThat(get_notification, Eventually(NotEquals(None)))
589 self.assertThat(get_notification, Eventually(NotEquals(None)))
590 self._assert_notification(
590 self._assert_notification(
591 get_notification(),
591 get_notification(),
@@ -625,7 +625,7 @@ class EphemeralNotificationsTests(NotificationsBase):
625
625
626 notification.show()
626 notification.show()
627
627
628− get_notification = lambda: notify_list.select_single('Notification')
628+ get_notification = lambda: notify_list.select_single('Notification', objectName='notification1')
629 self.assertThat(get_notification, Eventually(NotEquals(None)))
629 self.assertThat(get_notification, Eventually(NotEquals(None)))
630 notification = get_notification()
630 notification = get_notification()
631 self._assert_notification(
631 self._assert_notification(
@@ -658,7 +658,8 @@ class EphemeralNotificationsTests(NotificationsBase):
658 )
658 )
659 notification.show()
659 notification.show()
660 get_notification = lambda: notify_list.select_single(
660 get_notification = lambda: notify_list.select_single(
661− 'Notification'
661+ 'Notification',
662+ objectName='notification1'
662 )
663 )
663 self.assertThat(get_notification, Eventually(NotEquals(None)))
664 self.assertThat(get_notification, Eventually(NotEquals(None)))
664 notification = get_notification()
665 notification = get_notification()
tests/mocks/CMakeLists.txt+5
@@ -8,3 +8,8 @@ add_subdirectory(QMenuModel)
8add_subdirectory(SessionManager)
8add_subdirectory(SessionManager)
9add_subdirectory(Ubuntu)
9add_subdirectory(Ubuntu)
10add_subdirectory(Unity)
10add_subdirectory(Unity)
11+
12+install(
13+ DIRECTORY data
14+ DESTINATION ${SHELL_APP_DIR}/mocks
15+)
tests/mocks/data/applications/camera-app.desktopnew file

No changes to the content.

tests/plugins/Unity/resultstest.cpp+52
@@ -23,6 +23,7 @@
23
23
24#include "resultstest.h"
24#include "resultstest.h"
25#include "categoryresults.h"
25#include "categoryresults.h"
26+#include "variantutils.h"
26
27
27static DeeModel* createBackendModel()
28static DeeModel* createBackendModel()
28{
29{
@@ -193,4 +194,55 @@ void ResultsTest::testSpecialIcons()
193 QCOMPARE(transformedIcon, result);
194 QCOMPARE(transformedIcon, result);
194}
195}
195
196
197+void ResultsTest::testMetadataOverride_data()
198+{
199+ QTest::addColumn<QString>("uri");
200+ QTest::addColumn<QVariantHash>("result");
201+
202+ QVariantHash expected_result;
203+ QVariantHash inner_hash;
204+
205+ expected_result = QVariantHash();
206+ expected_result["scope-id"] = QVariant::fromValue(QString("applications.scope"));
207+ expected_result["content"] = QVariant::fromValue(QVariantHash());
208+
209+ QTest::newRow("single scope") << "subscope:applications.scope" << expected_result;
210+
211+ expected_result = QVariantHash();
212+ expected_result["scope-id"] = QVariant::fromValue(QString("applications.scope"));
213+ inner_hash = QVariantHash();
214+ inner_hash["foo"] = QVariant::fromValue(QString("bar"));
215+ inner_hash["qoo"] = QVariant::fromValue(QString("baz"));
216+ expected_result["content"] = QVariant::fromValue(inner_hash);
217+
218+ QTest::newRow("single scope with data") << "subscope:applications.scope?foo=bar&qoo=baz" << expected_result;
219+
220+ expected_result = QVariantHash();
221+ inner_hash = QVariantHash();
222+ inner_hash["scope-id"] = QVariant::fromValue(QString("applications-local.scope"));
223+ inner_hash["content"] = QVariant::fromValue(QVariantHash());
224+ expected_result["scope-id"] = QVariant::fromValue(QString("applications.scope"));
225+ expected_result["content"] = QVariant::fromValue(inner_hash);
226+ QTest::newRow("master scope") << "subscope:applications.scope/applications-local.scope" << expected_result;
227+
228+ expected_result = QVariantHash();
229+ expected_result["foo"] = QVariant::fromValue(QString("baz"));
230+ expected_result["qoo"] = QVariant::fromValue(QString("baz"));
231+ inner_hash = QVariantHash();
232+ inner_hash["scope-id"] = QVariant::fromValue(QString("applications-local.scope"));
233+ inner_hash["content"] = QVariant::fromValue(expected_result);
234+ expected_result = QVariantHash();
235+ expected_result["scope-id"] = QVariant::fromValue(QString("applications.scope"));
236+ expected_result["content"] = QVariant::fromValue(inner_hash);
237+ QTest::newRow("nested with data") << "subscope:applications.scope/applications-local.scope?foo=baz&qoo=baz" << expected_result;
238+}
239+
240+void ResultsTest::testMetadataOverride()
241+{
242+ QFETCH(QString, uri);
243+ QFETCH(QVariantHash, result);
244+
245+ QCOMPARE(subscopeUriToMetadataHash(uri), result);
246+}
247+
196QTEST_MAIN(ResultsTest)
248QTEST_MAIN(ResultsTest)
tests/plugins/Unity/resultstest.h+2
@@ -32,6 +32,8 @@ class ResultsTest : public QObject
32 void testIconColumn();
32 void testIconColumn();
33 void testSpecialIcons_data();
33 void testSpecialIcons_data();
34 void testSpecialIcons();
34 void testSpecialIcons();
35+ void testMetadataOverride_data();
36+ void testMetadataOverride();
35};
37};
36
38
37#endif
39#endif
tests/qmltests/Dash/Apps/tst_AppPreview.qml+3−2
@@ -137,11 +137,12 @@ Item {
137 for(var i = 0; i < buttons.count; i++) {
137 for(var i = 0; i < buttons.count; i++) {
138 var button = findChild(appPreview, "button" + i);
138 var button = findChild(appPreview, "button" + i);
139 mouseClick(button, 1, 1);
139 mouseClick(button, 1, 1);
140+ appPreview.showProcessingAction = false;
140 }
141 }
141
142
142 var actions = data.actions;
143 var actions = data.actions;
143− for(var i = 0; i < actions.length; i++) {
144+ for(var j = 0; j < actions.length; j++) {
144− compare(root.calls[i][0], actions[i].id, "Id of action not found.");
145+ compare(root.calls[j][0], actions[j].id, "Id of action not found.");
145 }
146 }
146 }
147 }
147
148
tests/qmltests/Dash/Movie/tst_MoviePreview.qml+1
@@ -74,6 +74,7 @@ Item {
74 for(var i = 0; i < buttons.count; i++) {
74 for(var i = 0; i < buttons.count; i++) {
75 var button = findChild(moviePreview, "button" + i);
75 var button = findChild(moviePreview, "button" + i);
76 mouseClick(button, 1, 1);
76 mouseClick(button, 1, 1);
77+ moviePreview.showProcessingAction = false;
77 }
78 }
78
79
79 var actions = get_actions_data();
80 var actions = get_actions_data();
tests/qmltests/Dash/tst_GenericPreview.qml+1
@@ -76,6 +76,7 @@ Item {
76 for(var i = 0; i < buttons.count; i++) {
76 for(var i = 0; i < buttons.count; i++) {
77 var button = findChild(genericPreview, "button" + i);
77 var button = findChild(genericPreview, "button" + i);
78 mouseClick(button, 1, 1);
78 mouseClick(button, 1, 1);
79+ genericPreview.showProcessingAction = false;
79 }
80 }
80
81
81 var actions = get_actions_data();
82 var actions = get_actions_data();
tests/qmltests/Dash/tst_GenericScopeView.qml+11
@@ -66,6 +66,17 @@ Item {
66 scopes.get(0).hideDash();
66 scopes.get(0).hideDash();
67 tryCompare(genericScopeView, "previewShown", false);
67 tryCompare(genericScopeView, "previewShown", false);
68 }
68 }
69+
70+ function test_show_spinner() {
71+ var previewLoader = findChild(genericScopeView, "previewLoader");
72+ previewLoader.open = true;
73+ previewLoader.source = "../../../Dash/Generic/GenericPreview.qml";
74+ previewLoader.item.showProcessingAction = true;
75+ var waitingForAction = findChild(genericScopeView, "waitingForActionMouseArea");
76+ tryCompare(waitingForAction, "enabled", true);
77+ previewLoader.closePreviewSpinner();
78+ tryCompare(waitingForAction, "enabled", false);
79+ }
69 }
80 }
70 }
81 }
71}
82}