kopia lustrzana https://github.com/browsh-org/browsh
HTTP server: fixes that were causing page hangs
rodzic
d6b5951059
commit
95562aa129
|
@ -116,7 +116,13 @@ export default class extends utils.mixins(CommonMixin, TabCommandsMixin) {
|
||||||
sendGlobalConfig(config) {
|
sendGlobalConfig(config) {
|
||||||
config.http_server_mode_type = this._calculateMode();
|
config.http_server_mode_type = this._calculateMode();
|
||||||
config.start_time = this.start_time;
|
config.start_time = this.start_time;
|
||||||
this.channel.postMessage(`/config,${JSON.stringify(config)}`);
|
if (this.channel) {
|
||||||
|
this.channel.postMessage(`/config,${JSON.stringify(config)}`);
|
||||||
|
} else {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.sendGlobalConfig(config);
|
||||||
|
}, 1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_listenForMessages() {
|
_listenForMessages() {
|
||||||
|
|
|
@ -25,6 +25,7 @@ export default class extends utils.mixins(CommonMixin, CommandsMixin) {
|
||||||
}
|
}
|
||||||
|
|
||||||
_postSetupConstructor() {
|
_postSetupConstructor() {
|
||||||
|
this._injectCustomCSS();
|
||||||
this.dimensions.channel = this.channel;
|
this.dimensions.channel = this.channel;
|
||||||
this.graphics_builder = new GraphicsBuilder(
|
this.graphics_builder = new GraphicsBuilder(
|
||||||
this.channel,
|
this.channel,
|
||||||
|
@ -191,7 +192,6 @@ export default class extends utils.mixins(CommonMixin, CommandsMixin) {
|
||||||
this.is_dom_loaded = true;
|
this.is_dom_loaded = true;
|
||||||
this.log("DOM LOADED");
|
this.log("DOM LOADED");
|
||||||
this._fixStickyElements();
|
this._fixStickyElements();
|
||||||
this._injectCustomCSS();
|
|
||||||
this._willHideText();
|
this._willHideText();
|
||||||
});
|
});
|
||||||
window.addEventListener("load", () => {
|
window.addEventListener("load", () => {
|
||||||
|
|
Ładowanie…
Reference in New Issue