Fix version history
This commit is contained in:
parent
8635e274e5
commit
5454b06329
|
@ -104,38 +104,37 @@ define([
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
show: function(){
|
internalShow: function() {
|
||||||
// if (maskeEl || loaderEl)
|
this.ownerEl.append(this.maskeEl);
|
||||||
// return;
|
this.ownerEl.append(this.loaderEl);
|
||||||
|
|
||||||
|
this.loaderEl.css('min-width', $('.asc-loadmask-title', this.loaderEl).width() + 105);
|
||||||
|
|
||||||
|
if (this.ownerEl && this.ownerEl.closest('.asc-window.modal').length==0)
|
||||||
|
Common.util.Shortcuts.suspendEvents();
|
||||||
|
},
|
||||||
|
|
||||||
|
show: function(immediately){
|
||||||
// The owner is already masked
|
// The owner is already masked
|
||||||
var ownerEl = this.ownerEl,
|
if (!!this.ownerEl.ismasked)
|
||||||
loaderEl = this.loaderEl,
|
|
||||||
maskeEl = this.maskeEl;
|
|
||||||
if (!!ownerEl.ismasked)
|
|
||||||
return this;
|
return this;
|
||||||
|
|
||||||
ownerEl.ismasked = true;
|
this.ownerEl.ismasked = true;
|
||||||
|
|
||||||
var me = this;
|
var me = this;
|
||||||
if (me.title != me.options.title) {
|
if (me.title != me.options.title) {
|
||||||
me.options.title = me.title;
|
me.options.title = me.title;
|
||||||
$('.asc-loadmask-title', loaderEl).html(me.title);
|
$('.asc-loadmask-title', this.loaderEl).html(me.title);
|
||||||
}
|
}
|
||||||
|
|
||||||
// show mask after 500 ms if it wont be hided
|
if (immediately) {
|
||||||
me.timerId = setTimeout(function () {
|
me.internalShow();
|
||||||
ownerEl.append(maskeEl);
|
} else if (!me.timerId) {
|
||||||
ownerEl.append(loaderEl);
|
// show mask after 500 ms if it wont be hided
|
||||||
|
me.timerId = setTimeout(function () {
|
||||||
// if (ownerEl.height()<1 || ownerEl.width()<1)
|
me.internalShow();
|
||||||
// loaderEl.css({visibility: 'hidden'});
|
},500);
|
||||||
|
}
|
||||||
loaderEl.css('min-width', $('.asc-loadmask-title', loaderEl).width() + 105);
|
|
||||||
|
|
||||||
if (ownerEl && ownerEl.closest('.asc-window.modal').length==0)
|
|
||||||
Common.util.Shortcuts.suspendEvents();
|
|
||||||
},500);
|
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
|
@ -177,6 +177,9 @@ define([
|
||||||
};
|
};
|
||||||
Common.UI.alert(config);
|
Common.UI.alert(config);
|
||||||
} else {
|
} else {
|
||||||
|
if (this.currentRev !== opts.data.version) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
var commentsController = this.getApplication().getController('Common.Controllers.Comments');
|
var commentsController = this.getApplication().getController('Common.Controllers.Comments');
|
||||||
if (commentsController) {
|
if (commentsController) {
|
||||||
commentsController.onApiHideComment();
|
commentsController.onApiHideComment();
|
||||||
|
|
|
@ -962,7 +962,7 @@ define([
|
||||||
this.loadMask.setTitle(title);
|
this.loadMask.setTitle(title);
|
||||||
|
|
||||||
if (!this.isShowOpenDialog)
|
if (!this.isShowOpenDialog)
|
||||||
this.loadMask.show();
|
this.loadMask.show(action.id===Asc.c_oAscAsyncAction['Open']);
|
||||||
} else {
|
} else {
|
||||||
this.getApplication().getController('Statusbar').setStatusCaption(text, force);
|
this.getApplication().getController('Statusbar').setStatusCaption(text, force);
|
||||||
}
|
}
|
||||||
|
|
|
@ -709,7 +709,7 @@ define([
|
||||||
this.loadMask.setTitle(title);
|
this.loadMask.setTitle(title);
|
||||||
|
|
||||||
if (!this.isShowOpenDialog)
|
if (!this.isShowOpenDialog)
|
||||||
this.loadMask.show();
|
this.loadMask.show(action.id===Asc.c_oAscAsyncAction['Open']);
|
||||||
} else {
|
} else {
|
||||||
this.getApplication().getController('Statusbar').setStatusCaption(text, force);
|
this.getApplication().getController('Statusbar').setStatusCaption(text, force);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue