Merge lp:~ajalkane/ubuntu-filemanager-app/content-hub-open-fix into lp:ubuntu-filemanager-app

Proposed by Arto Jalkanen
Status: Merged
Approved by: Arto Jalkanen
Approved revision: 309
Merged at revision: 309
Proposed branch: lp:~ajalkane/ubuntu-filemanager-app/content-hub-open-fix
Merge into: lp:ubuntu-filemanager-app
Diff against target: 48 lines (+11/-5)
2 files modified
src/app/qml/content-hub/FileOpener.qml (+10/-4)
src/app/qml/ui/FolderListPage.qml (+1/-1)
To merge this branch: bzr merge lp:~ajalkane/ubuntu-filemanager-app/content-hub-open-fix
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Ubuntu File Manager Developers Pending
Review via email: mp+239550@code.launchpad.net

Commit message

Fixing opening with content hub. Full path was not passed.

Description of the change

Fixing opening with content hub. Full path was not passed.

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

Self-approving since this is clear as a cake.

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

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/app/qml/content-hub/FileOpener.qml'
2--- src/app/qml/content-hub/FileOpener.qml 2014-10-22 21:55:37 +0000
3+++ src/app/qml/content-hub/FileOpener.qml 2014-10-24 12:29:45 +0000
4@@ -41,7 +41,7 @@
5 ContentItem {}
6 }
7
8- function __exportItems(url) {
9+ function __exportItemsWhenPossible(url) {
10 if (root.activeTransfer.state === ContentTransfer.InProgress)
11 {
12 root.activeTransfer.items = [ resultComponent.createObject(root, {"url": url}) ];
13@@ -59,13 +59,19 @@
14 onPeerSelected: {
15 root.activeTransfer = peer.request();
16 pageStack.pop();
17- if (root.activeTransfer.state === ContentTransfer.InProgress) {
18- root.__exportItems(root.fileUrl);
19- }
20+ __exportItemsWhenPossible(root.fileUrl)
21 }
22
23 onCancelPressed: {
24 pageStack.pop();
25 }
26 }
27+
28+ Connections {
29+ target: root.activeTransfer
30+ onStateChanged: {
31+ console.log("curTransfer StateChanged: " + root.activeTransfer.state);
32+ __exportItemsWhenPossible(root.fileUrl)
33+ }
34+ }
35 }
36
37=== modified file 'src/app/qml/ui/FolderListPage.qml'
38--- src/app/qml/ui/FolderListPage.qml 2014-10-23 23:02:55 +0000
39+++ src/app/qml/ui/FolderListPage.qml 2014-10-24 12:29:45 +0000
40@@ -752,7 +752,7 @@
41 false,
42 true);
43 } else {
44- openFile(model.fileName)
45+ openFile(model.filePath)
46 }
47 // PopupUtils.open(Qt.resolvedUrl("FileActionDialog.qml"), root,
48 // {

Subscribers

People subscribed via source and target branches