mirror of
https://github.com/overte-org/overte.git
synced 2025-04-14 14:47:19 +02:00
use new hook in marketplace code
This commit is contained in:
parent
a48aced7bd
commit
c5b998a2a8
1 changed files with 3 additions and 6 deletions
|
@ -48,15 +48,12 @@ Rectangle {
|
|||
property var autoCancel: 'var element = $("a.btn.cancel");
|
||||
element.click();'
|
||||
|
||||
onNewViewRequested: {
|
||||
var component = Qt.createComponent("Browser.qml");
|
||||
var newWindow = component.createObject(desktop);
|
||||
request.openIn(newWindow.webView);
|
||||
newWindowHook: function (component, newWindow) {
|
||||
if (File.isZippedFbx(desktop.currentUrl)) {
|
||||
runJavaScript(autoCancel);
|
||||
zipTimer.handler = function() {
|
||||
newWindow.destroy();
|
||||
runJavaScript(autoCancel);
|
||||
}
|
||||
};
|
||||
zipTimer.start();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue