diff --git a/apps/common/main/resources/less/toolbar.less b/apps/common/main/resources/less/toolbar.less index 23cf89c5b..f0a9cf0d9 100644 --- a/apps/common/main/resources/less/toolbar.less +++ b/apps/common/main/resources/less/toolbar.less @@ -214,7 +214,7 @@ padding: 12px 10px 7px 0; border-radius: 0; z-index:999; - overflow: hidden; + overflow: auto; .compactwidth { .btn-group, .btn-toolbar { &.x-huge { diff --git a/apps/documenteditor/main/app/view/Toolbar.js b/apps/documenteditor/main/app/view/Toolbar.js index 4fc5381db..a294b8338 100644 --- a/apps/documenteditor/main/app/view/Toolbar.js +++ b/apps/documenteditor/main/app/view/Toolbar.js @@ -1515,11 +1515,17 @@ define([ menu.menuAlignEl = cmp.cmpEl; menu.menuAlign = 'tl-tl'; - var offset = cmp.cmpEl.width() - cmp.openButton.$el.width() - columnCount * (itemMargin + _width) - 1; + var menuWidth = columnCount * (itemMargin + _width), + buttonOffsetLeft = cmp.openButton.$el.offset().left; + // if (menuWidth>buttonOffsetLeft) + // menuWidth = Math.max(Math.floor(buttonOffsetLeft/(itemMargin + _width)), 2) * (itemMargin + _width); + if (menuWidth>Common.Utils.innerWidth()) + menuWidth = Math.max(Math.floor(Common.Utils.innerWidth()/(itemMargin + _width)), 2) * (itemMargin + _width); + var offset = cmp.cmpEl.width() - cmp.openButton.$el.width() - Math.min(menuWidth, buttonOffsetLeft) - 1; menu.setOffset(Math.min(offset, 0)); menu.cmpEl.css({ - 'width': columnCount * (_width + itemMargin), + 'width': menuWidth, 'min-height': cmp.cmpEl.height() }); } diff --git a/apps/presentationeditor/main/app/view/Toolbar.js b/apps/presentationeditor/main/app/view/Toolbar.js index de669b96c..41ff4c21f 100644 --- a/apps/presentationeditor/main/app/view/Toolbar.js +++ b/apps/presentationeditor/main/app/view/Toolbar.js @@ -1088,11 +1088,17 @@ define([ menu.menuAlignEl = cmp.cmpEl; menu.menuAlign = 'tl-tl'; - var offset = cmp.cmpEl.width() - cmp.openButton.$el.width() - columnCount * (itemMargin + itemWidth) - 1; + var menuWidth = columnCount * (itemMargin + itemWidth), + buttonOffsetLeft = cmp.openButton.$el.offset().left; + // if (menuWidth>buttonOffsetLeft) + // menuWidth = Math.max(Math.floor(buttonOffsetLeft/(itemMargin + itemWidth)), 2) * (itemMargin + itemWidth); + if (menuWidth>Common.Utils.innerWidth()) + menuWidth = Math.max(Math.floor(Common.Utils.innerWidth()/(itemMargin + itemWidth)), 2) * (itemMargin + itemWidth); + var offset = cmp.cmpEl.width() - cmp.openButton.$el.width() - Math.min(menuWidth, buttonOffsetLeft) - 1; menu.setOffset(Math.min(offset, 0)); menu.cmpEl.css({ - 'width': columnCount * (itemWidth + itemMargin), + 'width': menuWidth, 'min-height': cmp.cmpEl.height() }); } diff --git a/apps/spreadsheeteditor/main/app/view/PivotTable.js b/apps/spreadsheeteditor/main/app/view/PivotTable.js index f5c4396be..94d66261a 100644 --- a/apps/spreadsheeteditor/main/app/view/PivotTable.js +++ b/apps/spreadsheeteditor/main/app/view/PivotTable.js @@ -79,7 +79,6 @@ define([ '' + '' + '' + - '
' + '