Fix Bug 40747
This commit is contained in:
parent
37df45af5a
commit
20ccd6280d
|
@ -110,6 +110,22 @@ define([
|
||||||
this.content_panels = $window.find('.settings-panel');
|
this.content_panels = $window.find('.settings-panel');
|
||||||
if (this.btnsCategory.length>0)
|
if (this.btnsCategory.length>0)
|
||||||
this.btnsCategory[0].toggle(true, true);
|
this.btnsCategory[0].toggle(true, true);
|
||||||
|
|
||||||
|
me.menuAddAlign = function(menuRoot, left, top) {
|
||||||
|
var self = this;
|
||||||
|
if (!$window.hasClass('notransform')) {
|
||||||
|
$window.addClass('notransform');
|
||||||
|
menuRoot.addClass('hidden');
|
||||||
|
setTimeout(function() {
|
||||||
|
menuRoot.removeClass('hidden');
|
||||||
|
menuRoot.css({left: left, top: top});
|
||||||
|
self.options.additionalAlign = null;
|
||||||
|
}, 300);
|
||||||
|
} else {
|
||||||
|
menuRoot.css({left: left, top: top});
|
||||||
|
self.options.additionalAlign = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
setHeight: function(height) {
|
setHeight: function(height) {
|
||||||
|
|
|
@ -994,6 +994,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
||||||
});
|
});
|
||||||
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -1020,6 +1021,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
||||||
});
|
});
|
||||||
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -1052,6 +1054,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
||||||
});
|
});
|
||||||
this.btnEndStyleMenu = (new Common.UI.Menu({
|
this.btnEndStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -1078,6 +1081,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
||||||
});
|
});
|
||||||
this.btnEndSizeMenu = (new Common.UI.Menu({
|
this.btnEndSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
|
|
@ -337,6 +337,7 @@ define([ 'text!presentationeditor/main/app/template/ShapeSettingsAdvanced.tem
|
||||||
});
|
});
|
||||||
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -363,6 +364,7 @@ define([ 'text!presentationeditor/main/app/template/ShapeSettingsAdvanced.tem
|
||||||
});
|
});
|
||||||
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -395,6 +397,7 @@ define([ 'text!presentationeditor/main/app/template/ShapeSettingsAdvanced.tem
|
||||||
});
|
});
|
||||||
this.btnEndStyleMenu = (new Common.UI.Menu({
|
this.btnEndStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -421,6 +424,7 @@ define([ 'text!presentationeditor/main/app/template/ShapeSettingsAdvanced.tem
|
||||||
});
|
});
|
||||||
this.btnEndSizeMenu = (new Common.UI.Menu({
|
this.btnEndSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
|
|
@ -111,27 +111,12 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
||||||
|
|
||||||
// Layout
|
// Layout
|
||||||
|
|
||||||
var menuAddAlign = function(menuRoot, left, top) {
|
|
||||||
var self = this;
|
|
||||||
if (!$window.hasClass('notransform')) {
|
|
||||||
$window.addClass('notransform');
|
|
||||||
menuRoot.addClass('hidden');
|
|
||||||
setTimeout(function() {
|
|
||||||
menuRoot.removeClass('hidden');
|
|
||||||
menuRoot.css({left: left, top: top});
|
|
||||||
self.options.additionalAlign = null;
|
|
||||||
}, 500);
|
|
||||||
} else {
|
|
||||||
menuRoot.css({left: left, top: top});
|
|
||||||
self.options.additionalAlign = null;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
this.btnChartType = new Common.UI.Button({
|
this.btnChartType = new Common.UI.Button({
|
||||||
cls : 'btn-large-dataview',
|
cls : 'btn-large-dataview',
|
||||||
iconCls : 'item-chartlist bar-normal',
|
iconCls : 'item-chartlist bar-normal',
|
||||||
menu : new Common.UI.Menu({
|
menu : new Common.UI.Menu({
|
||||||
style: 'width: 435px; padding-top: 12px;',
|
style: 'width: 435px; padding-top: 12px;',
|
||||||
additionalAlign: menuAddAlign,
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="id-chart-dlg-menu-type" class="menu-insertchart" style="margin: 5px 5px 5px 10px;"></div>') }
|
{ template: _.template('<div id="id-chart-dlg-menu-type" class="menu-insertchart" style="margin: 5px 5px 5px 10px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -792,7 +777,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
||||||
iconCls : 'item-chartlist spark-column',
|
iconCls : 'item-chartlist spark-column',
|
||||||
menu : new Common.UI.Menu({
|
menu : new Common.UI.Menu({
|
||||||
style: 'width: 200px; padding-top: 12px;',
|
style: 'width: 200px; padding-top: 12px;',
|
||||||
additionalAlign: menuAddAlign,
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="id-spark-dlg-menu-type" class="menu-insertchart" style="margin: 5px 5px 0 10px;"></div>') }
|
{ template: _.template('<div id="id-spark-dlg-menu-type" class="menu-insertchart" style="margin: 5px 5px 0 10px;"></div>') }
|
||||||
]
|
]
|
||||||
|
|
|
@ -357,6 +357,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ShapeSettingsAdvanced.temp
|
||||||
});
|
});
|
||||||
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
this.btnBeginStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -383,6 +384,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ShapeSettingsAdvanced.temp
|
||||||
});
|
});
|
||||||
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
this.btnBeginSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-begin-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -415,6 +417,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ShapeSettingsAdvanced.temp
|
||||||
});
|
});
|
||||||
this.btnEndStyleMenu = (new Common.UI.Menu({
|
this.btnEndStyleMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 105px;',
|
style: 'min-width: 105px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-style" style="width: 105px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
@ -441,6 +444,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ShapeSettingsAdvanced.temp
|
||||||
});
|
});
|
||||||
this.btnEndSizeMenu = (new Common.UI.Menu({
|
this.btnEndSizeMenu = (new Common.UI.Menu({
|
||||||
style: 'min-width: 160px;',
|
style: 'min-width: 160px;',
|
||||||
|
additionalAlign: this.menuAddAlign,
|
||||||
items: [
|
items: [
|
||||||
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
{ template: _.template('<div id="shape-advanced-menu-end-size" style="width: 160px; margin: 0 5px;"></div>') }
|
||||||
]
|
]
|
||||||
|
|
Loading…
Reference in a new issue