back to master version

This commit is contained in:
howard-stearns 2016-08-30 14:06:20 -07:00
parent c5b998a2a8
commit 232ac74b26
2 changed files with 7 additions and 11 deletions

View file

@ -28,7 +28,7 @@ Rectangle {
color: hifi.colors.baseGrayShadow
property var currentUrl: "https://metaverse.highfidelity.com/marketplace"
Controls.WebView {
Controls.BaseWebView {
id: webview
url: currentUrl
anchors.top: switchMarketView.bottom
@ -48,12 +48,15 @@ Rectangle {
property var autoCancel: 'var element = $("a.btn.cancel");
element.click();'
newWindowHook: function (component, newWindow) {
onNewViewRequested: {
var component = Qt.createComponent("Browser.qml");
var newWindow = component.createObject(desktop);
request.openIn(newWindow.webView);
if (File.isZippedFbx(desktop.currentUrl)) {
runJavaScript(autoCancel);
zipTimer.handler = function() {
newWindow.destroy();
};
runJavaScript(autoCancel);
}
zipTimer.start();
}
}

View file

@ -61,13 +61,6 @@ WebEngineView {
}
}
property var newWindowHook: function (component, newWindow, request) { }; // override if you need to
onNewViewRequested:{
var component = Qt.createComponent("../Browser.qml");
var newWindow = component.createObject(desktop);
request.openIn(newWindow.webView)
newWindowHook(component, newWindow, request);
}
// This breaks the webchannel used for passing messages. Fixed in Qt 5.6
// See https://bugreports.qt.io/browse/QTBUG-49521