Merge pull request #1175 from ONLYOFFICE/fix/bugfix

Fix/bugfix
This commit is contained in:
Julia Radzhabova 2021-09-14 23:28:23 +03:00 committed by GitHub
commit c9db264d51
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 18 additions and 10 deletions

View file

@ -939,8 +939,11 @@ define([
var x0 = p[0][0] + sdkPanelLeftWidth, y0 = p[0][1],
x1 = p[isCursor ? 2 : 1][0] + sdkPanelLeftWidth, y1 = p[isCursor ? 2 : 1][1];
var leftPos = parseInt(this.$window.css('left')) - this.arrow.width,
windowWidth = this.$window.outerWidth() + this.arrow.width;
if (x0>leftPos && x0<leftPos+windowWidth || x1>leftPos && x1<leftPos+windowWidth) {
windowWidth = this.$window.outerWidth() + this.arrow.width,
topPos = parseInt(this.$window.css('top')),
windowHeight = this.$window.outerHeight();
if (x0>leftPos && x0<leftPos+windowWidth && y0>topPos && y0<topPos+windowHeight ||
x1>leftPos && x1<leftPos+windowWidth && y1>topPos && y1<topPos+windowHeight) {
var newDown = (y0>y1) ? [x0, y0] : [x1, y1],// try move down
newUp = (y0<y1) ? [x0, y0] : [x1, y1]; // try move up
return [newUp, newDown];

View file

@ -103,6 +103,11 @@
border-radius: 2px;
}
}
&.border-top {
border-top: @scaled-one-px-value-ie solid @border-divider-ie;
border-top: @scaled-one-px-value solid @border-divider;
}
}
> .disabled {

View file

@ -1855,7 +1855,7 @@ define([
Common.NotificationCenter.trigger('goback', true);
}
}
if (id == Asc.c_oAscError.ID.DataEncrypted) {
if (id == Asc.c_oAscError.ID.DataEncrypted || id == Asc.c_oAscError.ID.ConvertationOpenLimitError) {
this.api.asc_coAuthoringDisconnect();
Common.NotificationCenter.trigger('api:disconnect');
}

View file

@ -448,7 +448,7 @@ define([
var itemsTemplate =
_.template([
'<% _.each(items, function(item) { %>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> style="border-top: 1px solid #e5e5e5;margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> class="border-top" style="margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<% }); %>'
].join(''));
this.cmbFontRender = new Common.UI.ComboBox({

View file

@ -1508,7 +1508,7 @@ define([
}
}
}
if (id == Asc.c_oAscError.ID.DataEncrypted) {
if (id == Asc.c_oAscError.ID.DataEncrypted || id == Asc.c_oAscError.ID.ConvertationOpenLimitError) {
this.api.asc_coAuthoringDisconnect();
Common.NotificationCenter.trigger('api:disconnect');
}

View file

@ -377,7 +377,7 @@ define([
var itemsTemplate =
_.template([
'<% _.each(items, function(item) { %>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> style="border-top: 1px solid #e5e5e5;margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> class="border-top" style="margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<% }); %>'
].join(''));
this.cmbFontRender = new Common.UI.ComboBox({

View file

@ -1885,7 +1885,7 @@ define([
}
}
}
if (id == Asc.c_oAscError.ID.DataEncrypted) {
if (id == Asc.c_oAscError.ID.DataEncrypted || id == Asc.c_oAscError.ID.ConvertationOpenLimitError) {
this.api.asc_coAuthoringDisconnect();
Common.NotificationCenter.trigger('api:disconnect');
}

View file

@ -446,7 +446,7 @@ define([
var itemsTemplate =
_.template([
'<% _.each(items, function(item) { %>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "customoptions") { %> style="border-top: 1px solid #e5e5e5;margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem">',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "customoptions") { %> class="border-top" style="margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem">',
'<%= scope.getDisplayValue(item) %>',
'</a></li>',
'<% }); %>'
@ -897,7 +897,7 @@ define([
var itemsTemplate =
_.template([
'<% _.each(items, function(item) { %>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> style="border-top: 1px solid #e5e5e5;margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "custom") { %> class="border-top" style="margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem" <% if (typeof(item.checked) !== "undefined" && item.checked) { %> class="checked" <% } %> ><%= scope.getDisplayValue(item) %></a></li>',
'<% }); %>'
].join(''));
this.cmbFontRender = new Common.UI.ComboBox({

View file

@ -212,7 +212,7 @@ define([ 'text!spreadsheeteditor/main/app/template/PrintSettings.template',
var itemsTemplate =
_.template([
'<% _.each(items, function(item) { %>',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "customoptions") { %> style="border-top: 1px solid #e5e5e5;margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem">',
'<li id="<%= item.id %>" data-value="<%= item.value %>" <% if (item.value === "customoptions") { %> class="border-top" style="margin-top: 5px;" <% } %> ><a tabindex="-1" type="menuitem">',
'<%= scope.getDisplayValue(item) %>',
'</a></li>',
'<% }); %>'