mirror of
https://github.com/tcsenpai/Zundler.git
synced 2025-06-06 11:35:40 +00:00
Fix doc title and loading indicator
This commit is contained in:
parent
8aa570030b
commit
b496b1cad7
@ -76,6 +76,8 @@ var prepare = function(html) {
|
|||||||
fixLinks(doc);
|
fixLinks(doc);
|
||||||
fixForms(doc);
|
fixForms(doc);
|
||||||
|
|
||||||
|
window.document.title = doc.title;
|
||||||
|
|
||||||
return doc.documentElement.outerHTML;
|
return doc.documentElement.outerHTML;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -177,11 +179,7 @@ window.onload = function() {
|
|||||||
var iframe = document.getElementById(iFrameId);
|
var iframe = document.getElementById(iFrameId);
|
||||||
|
|
||||||
if (evnt.data.action == 'ready') {
|
if (evnt.data.action == 'ready') {
|
||||||
// iframe is ready to receive the globalContext
|
hideLoadingIndicator();
|
||||||
iframe.contentWindow.postMessage({
|
|
||||||
action: "set_data",
|
|
||||||
argument: window.globalContext,
|
|
||||||
}, "*");
|
|
||||||
|
|
||||||
} else if (evnt.data.action == 'set_title') {
|
} else if (evnt.data.action == 'set_title') {
|
||||||
// iframe has finished loading and sent us its title
|
// iframe has finished loading and sent us its title
|
||||||
|
Loading…
x
Reference in New Issue
Block a user