more detailed stats, memory optimalizations, connection pinging and timeout, request timeout, validate content after signing, only recompile changed coffeescripts, remove unnecessary js logs
This commit is contained in:
parent
bd7e76628b
commit
b35d21d643
13 changed files with 222 additions and 59 deletions
|
@ -4,12 +4,10 @@ class Loading
|
|||
|
||||
|
||||
setProgress: (percent) ->
|
||||
console.log "Progress:", percent
|
||||
$(".progressbar").css("width", percent*100+"%").css("opacity", "1").css("display", "block")
|
||||
|
||||
hideProgress: ->
|
||||
$(".progressbar").css("width", "100%").css("opacity", "0").cssLater("display", "none", 1000)
|
||||
console.log "Hideprogress"
|
||||
|
||||
|
||||
showScreen: ->
|
||||
|
|
|
@ -59,7 +59,6 @@ class Wrapper
|
|||
cmd = message.cmd
|
||||
if cmd == "innerReady"
|
||||
@inner_ready = true
|
||||
@log "innerReady", @ws.ws.readyState, @wrapperWsInited
|
||||
if @ws.ws.readyState == 1 and not @wrapperWsInited # If ws already opened
|
||||
@sendInner {"cmd": "wrapperOpenedWebsocket"}
|
||||
@wrapperWsInited = true
|
||||
|
@ -148,7 +147,6 @@ class Wrapper
|
|||
|
||||
onOpenWebsocket: (e) =>
|
||||
@ws.cmd "channelJoin", {"channel": "siteChanged"} # Get info on modifications
|
||||
@log "onOpenWebsocket", @inner_ready, @wrapperWsInited
|
||||
if not @wrapperWsInited and @inner_ready
|
||||
@sendInner {"cmd": "wrapperOpenedWebsocket"} # Send to inner frame
|
||||
@wrapperWsInited = true
|
||||
|
@ -178,7 +176,6 @@ class Wrapper
|
|||
|
||||
# Iframe loaded
|
||||
onLoad: (e) =>
|
||||
@log "onLoad"
|
||||
@inner_loaded = true
|
||||
if not @inner_ready then @sendInner {"cmd": "wrapperReady"} # Inner frame loaded before wrapper
|
||||
#if not @site_error then @loading.hideScreen() # Hide loading screen
|
||||
|
|
|
@ -472,13 +472,11 @@ jQuery.extend( jQuery.easing,
|
|||
}
|
||||
|
||||
Loading.prototype.setProgress = function(percent) {
|
||||
console.log("Progress:", percent);
|
||||
return $(".progressbar").css("width", percent * 100 + "%").css("opacity", "1").css("display", "block");
|
||||
};
|
||||
|
||||
Loading.prototype.hideProgress = function() {
|
||||
$(".progressbar").css("width", "100%").css("opacity", "0").cssLater("display", "none", 1000);
|
||||
return console.log("Hideprogress");
|
||||
return $(".progressbar").css("width", "100%").css("opacity", "0").cssLater("display", "none", 1000);
|
||||
};
|
||||
|
||||
Loading.prototype.showScreen = function() {
|
||||
|
@ -807,7 +805,6 @@ jQuery.extend( jQuery.easing,
|
|||
cmd = message.cmd;
|
||||
if (cmd === "innerReady") {
|
||||
this.inner_ready = true;
|
||||
this.log("innerReady", this.ws.ws.readyState, this.wrapperWsInited);
|
||||
if (this.ws.ws.readyState === 1 && !this.wrapperWsInited) {
|
||||
this.sendInner({
|
||||
"cmd": "wrapperOpenedWebsocket"
|
||||
|
@ -933,7 +930,6 @@ jQuery.extend( jQuery.easing,
|
|||
this.ws.cmd("channelJoin", {
|
||||
"channel": "siteChanged"
|
||||
});
|
||||
this.log("onOpenWebsocket", this.inner_ready, this.wrapperWsInited);
|
||||
if (!this.wrapperWsInited && this.inner_ready) {
|
||||
this.sendInner({
|
||||
"cmd": "wrapperOpenedWebsocket"
|
||||
|
@ -974,7 +970,6 @@ jQuery.extend( jQuery.easing,
|
|||
|
||||
Wrapper.prototype.onLoad = function(e) {
|
||||
var _ref;
|
||||
this.log("onLoad");
|
||||
this.inner_loaded = true;
|
||||
if (!this.inner_ready) {
|
||||
this.sendInner({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue