Implements QML Apps. Implements #47

You are welcome Stephan.
This commit is contained in:
Maran
2014-06-23 16:25:57 +02:00
parent 2408e38218
commit f6aabb7a90
5 changed files with 152 additions and 35 deletions

View File

@@ -372,7 +372,15 @@ ApplicationWindow {
onAccepted: {
//ui.open(openAppDialog.fileUrl.toString())
//ui.openHtml(Qt.resolvedUrl(ui.assetPath("test.html")))
ui.openHtml(openAppDialog.fileUrl.toString())
var path = openAppDialog.fileUrl.toString()
console.log(path)
var ext = path.split('.').pop()
console.log(ext)
if(ext == "html" || ext == "htm") {
ui.openHtml(path)
}else if(ext == "qml"){
ui.openQml(path)
}
}
}