~ubuntu-docviewer-dev/ubuntu-docviewer-app/lo-viewer

« back to all changes in this revision

Viewing changes to src/app/qml/ubuntu-docviewer-app.qml

  • Committer: Stefano Verzegnassi
  • Date: 2014-11-04 18:54:38 UTC
  • mto: This revision was merged to the branch mainline in revision 39.
  • Revision ID: stefano92.100@gmail.com-20141104185438-3jx9hwc93oc89r02
Fixed issue with ContentPeerPicker (binding loop for visible property while importing a file from an external source)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
import QtQuick 2.3
2
2
import Ubuntu.Components 1.1
3
 
import Ubuntu.Content 1.1
4
3
import Ubuntu.Components.Popups 1.0
5
4
import com.ubuntu.fileqmlplugin 1.0
6
5
 
46
45
    }
47
46
 
48
47
    // Content Importer
49
 
    Connections {
50
 
        target: ContentHub
51
 
 
52
 
        onImportRequested: {
53
 
            // We have no signals to know if an import was requested before Component.completed signal
54
 
            //  is emitted. So clear the stack when this occurs.
55
 
            pageStack.clear()
56
 
 
57
 
            if (transfer.state === ContentTransfer.Charged) {
58
 
                console.log("[CONTENT-HUB] Incoming Import Request")
59
 
                file.path = transfer.items[0].url.toString().replace("file://", "");
 
48
    Loader {
 
49
        id: contentHubLoader
 
50
 
 
51
        asynchronous: true
 
52
        source: Qt.resolvedUrl("ContentHubProxy.qml")
 
53
        onStatusChanged: {
 
54
            if (status === Loader.Ready) {
 
55
                item.pageStack = pageStack
60
56
            }
61
57
        }
62
58
    }