Fix Bug 37192

This commit is contained in:
Julia Radzhabova 2018-03-15 14:38:53 +03:00
parent 280f57cd11
commit 5b3dab1239
3 changed files with 16 additions and 4 deletions

View file

@ -210,6 +210,8 @@ define([
me.dontCloseDummyComment = true;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = true;
else if (/form-control/.test(e.target.className))
me.inFormControl = true;
}
});
@ -226,6 +228,8 @@ define([
me.dontCloseDummyComment = false;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = false;
else if (/form-control/.test(e.target.className))
me.inFormControl = false;
}
}
}).on('dragover', function(e) {
@ -665,7 +669,7 @@ define([
if ( type == Asc.c_oAscAsyncActionType.BlockInteraction &&
(!this.getApplication().getController('LeftMenu').dlgSearch || !this.getApplication().getController('LeftMenu').dlgSearch.isVisible()) &&
!( id == Asc.c_oAscAsyncAction['ApplyChanges'] && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed )) ) {
!( id == Asc.c_oAscAsyncAction['ApplyChanges'] && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed || this.inFormControl)) ) {
// this.onEditComplete(this.loadMask); //если делать фокус, то при принятии чужих изменений, заканчивается свой композитный ввод
this.api.asc_enableKeyEvents(true);
}

View file

@ -191,6 +191,8 @@ define([
me.dontCloseDummyComment = true;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = true;
else if (/form-control/.test(e.target.className))
me.inFormControl = true;
}
});
@ -207,6 +209,8 @@ define([
me.dontCloseDummyComment = false;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = false;
else if (/form-control/.test(e.target.className))
me.inFormControl = false;
}
}
}).on('dragover', function(e) {
@ -456,7 +460,7 @@ define([
if ((id==Asc.c_oAscAsyncAction['Save'] || id==Asc.c_oAscAsyncAction['ForceSaveButton']) && (!this._state.fastCoauth || this._state.usersCount<2))
this.synchronizeChanges();
if (type == Asc.c_oAscAsyncActionType.BlockInteraction && !((id == Asc.c_oAscAsyncAction['LoadDocumentFonts'] || id == Asc.c_oAscAsyncAction['ApplyChanges']) && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed ))) {
if (type == Asc.c_oAscAsyncActionType.BlockInteraction && !((id == Asc.c_oAscAsyncAction['LoadDocumentFonts'] || id == Asc.c_oAscAsyncAction['ApplyChanges']) && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed || this.inFormControl))) {
this.onEditComplete(this.loadMask);
this.api.asc_enableKeyEvents(true);
}

View file

@ -197,6 +197,8 @@ define([
me.dontCloseDummyComment = true;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = true;
else if (/form-control/.test(e.target.className))
me.inFormControl = true;
}
});
@ -215,6 +217,8 @@ define([
me.dontCloseDummyComment = false;
else if (/chat-msg-text/.test(e.target.id))
me.dontCloseChat = false;
else if (/form-control/.test(e.target.className))
me.inFormControl = false;
}
}
}).on('dragover', function(e) {
@ -476,12 +480,12 @@ define([
this.setLongActionView(action);
} else {
if (this.loadMask) {
if (this.loadMask.isVisible() && !this.dontCloseDummyComment && !this.dontCloseChat && !this.isModalShowed )
if (this.loadMask.isVisible() && !this.dontCloseDummyComment && !this.dontCloseChat && !this.isModalShowed && !this.inFormControl)
this.api.asc_enableKeyEvents(true);
this.loadMask.hide();
}
if (type == Asc.c_oAscAsyncActionType.BlockInteraction && !( (id == Asc.c_oAscAsyncAction['LoadDocumentFonts'] || id == Asc.c_oAscAsyncAction['ApplyChanges']) && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed ) ))
if (type == Asc.c_oAscAsyncActionType.BlockInteraction && !( (id == Asc.c_oAscAsyncAction['LoadDocumentFonts'] || id == Asc.c_oAscAsyncAction['ApplyChanges']) && (this.dontCloseDummyComment || this.dontCloseChat || this.isModalShowed || this.inFormControl) ))
this.onEditComplete(this.loadMask, {restorefocus:true});
}
},