diff --git a/apps/common/main/lib/component/Mixtbar.js b/apps/common/main/lib/component/Mixtbar.js
index 9b452c354..c1e6c29f8 100644
--- a/apps/common/main/lib/component/Mixtbar.js
+++ b/apps/common/main/lib/component/Mixtbar.js
@@ -503,7 +503,8 @@ define([
setMoreButton: function(tab, panel) {
var me = this;
if (!btnsMore[tab]) {
- var box = $('
' +
+ var top = panel.position().top;
+ var box = $('
');
@@ -561,7 +562,7 @@ define([
var need_break = false;
for (var i=items.length-1; i>=0; i--) {
var item = $(items[i]);
- if (!item.is(':visible')) { // move invisible items as is and set special attr
+ if (!item.is(':visible') && !item.attr('hidden-on-resize')) { // move invisible items as is and set special attr
item.attr('data-hidden-tb-item', true);
this.$moreBar.prepend(item);
hideAllMenus = true;
@@ -585,6 +586,7 @@ define([
this.$moreBar.prepend(item);
if (last_separator) {
last_separator.css('display', '');
+ last_separator.removeAttr('hidden-on-resize');
}
hideAllMenus = true;
} else if ( offset.left+item_width > _maxright ) {
@@ -595,6 +597,7 @@ define([
this.$moreBar.prepend(item);
if (last_separator) {
last_separator.css('display', '');
+ last_separator.removeAttr('hidden-on-resize');
}
hideAllMenus = true;
break;
@@ -612,6 +615,7 @@ define([
this.$moreBar.prepend(last_group);
if (last_separator) {
last_separator.css('display', '');
+ last_separator.removeAttr('hidden-on-resize');
}
}
last_group.prepend(child);
@@ -638,6 +642,7 @@ define([
} else if (item.hasClass('separator')) {
this.$moreBar.prepend(item);
item.css('display', 'none');
+ item.attr('hidden-on-resize', true);
last_separator = item;
hideAllMenus = true;
}
@@ -683,6 +688,7 @@ define([
more_section.before(item);
if (last_separator) {
last_separator.css('display', '');
+ last_separator.removeAttr('hidden-on-resize');
}
if (this.$moreBar.children().filter('.group').length == 0) {
this.hideMoreBtns();
@@ -717,6 +723,7 @@ define([
more_section.before(last_group);
if (last_separator) {
last_separator.css('display', '');
+ last_separator.removeAttr('hidden-on-resize');
}
}
last_group.append(child);
@@ -747,6 +754,7 @@ define([
} else if (item.hasClass('separator')) {
more_section.before(item);
item.css('display', 'none');
+ item.attr('hidden-on-resize', true);
last_separator = item;
last_width = parseInt(last_separator.css('margin-left')) + parseInt(last_separator.css('margin-right')) + 1;
hideAllMenus = true;
@@ -779,7 +787,7 @@ define([
right = Common.Utils.innerWidth() - (showxy.left - parentxy.left + target.width()),
top = showxy.top - parentxy.top + target.height() + 10;
- moreContainer.css({right: right, left: 'auto', top : top});
+ moreContainer.css({right: right, left: 'auto', top : top, 'max-width': Common.Utils.innerWidth() + 'px'});
moreContainer.show();
},
diff --git a/apps/common/main/lib/controller/Plugins.js b/apps/common/main/lib/controller/Plugins.js
index 05775c87a..ba115f40d 100644
--- a/apps/common/main/lib/controller/Plugins.js
+++ b/apps/common/main/lib/controller/Plugins.js
@@ -242,6 +242,10 @@ define([
$('
').appendTo(me.$toolbarPanelPlugins);
_group = $('
');
rank_plugins = 0;
+ } else {
+ _group.appendTo(me.$toolbarPanelPlugins);
+ $('
').appendTo(me.$toolbarPanelPlugins);
+ _group = $('
');
}
var btn = me.panelPlugins.createPluginButton(model);
diff --git a/apps/common/main/lib/util/utils.js b/apps/common/main/lib/util/utils.js
index 52ca72d75..03aac86ae 100644
--- a/apps/common/main/lib/util/utils.js
+++ b/apps/common/main/lib/util/utils.js
@@ -193,13 +193,18 @@ var utils = new(function() {
me.innerHeight = window.innerHeight * me.zoom;
me.applicationPixelRatio = scale.applicationPixelRatio || scale.devicePixelRatio;
};
+ checkSizeIE = function() {
+ me.innerWidth = window.innerWidth;
+ me.innerHeight = window.innerHeight;
+ };
me.zoom = 1;
me.applicationPixelRatio = 1;
me.innerWidth = window.innerWidth;
me.innerHeight = window.innerHeight;
- if ( isIE )
+ if ( isIE ) {
$(document.body).addClass('ie');
- else {
+ $(window).on('resize', checkSizeIE);
+ } else {
checkSize();
$(window).on('resize', checkSize);
}
diff --git a/apps/common/main/resources/less/toolbar.less b/apps/common/main/resources/less/toolbar.less
index c78364c45..a3b26b0c1 100644
--- a/apps/common/main/resources/less/toolbar.less
+++ b/apps/common/main/resources/less/toolbar.less
@@ -214,6 +214,7 @@
padding: 12px 10px 7px 0;
border-radius: 0;
z-index:999;
+ overflow: auto;
.compactwidth {
.btn-group, .btn-toolbar {
&.x-huge {
@@ -231,8 +232,18 @@
}
}
}
+ .group {
+ height: 52px !important;
+ }
&[data-tab=pivot] {
padding: 5px 10px 0 0;
+ .group {
+ height: 60px !important;
+ }
+ .separator {
+ margin-top: 4px;
+ margin-bottom: 4px;
+ }
}
}
@@ -258,7 +269,7 @@
&.small {
padding-left: 10px;
- + .separator {
+ + .separator:not(.invisible) {
margin-left: 10px;
}
}
@@ -290,6 +301,11 @@
margin-left: 5px;
}
+ &.invisible {
+ margin-left: 0;
+ border: none;
+ }
+
&.long {
height: 52px;
}
diff --git a/apps/documenteditor/main/app/controller/Toolbar.js b/apps/documenteditor/main/app/controller/Toolbar.js
index 7ad5c52b2..aafe23e8e 100644
--- a/apps/documenteditor/main/app/controller/Toolbar.js
+++ b/apps/documenteditor/main/app/controller/Toolbar.js
@@ -3190,6 +3190,7 @@ define([
me.toolbar.btnPaste.$el.detach().appendTo($box);
me.toolbar.btnPaste.$el.find('button').attr('data-hint-direction', 'bottom');
me.toolbar.btnCopy.$el.removeClass('split');
+ me.toolbar.processPanelVisible(null, true, true);
}
if ( config.isDesktopApp ) {
diff --git a/apps/documenteditor/main/app/template/Toolbar.template b/apps/documenteditor/main/app/template/Toolbar.template
index 593bd1710..6271e1249 100644
--- a/apps/documenteditor/main/app/template/Toolbar.template
+++ b/apps/documenteditor/main/app/template/Toolbar.template
@@ -86,6 +86,7 @@
+