[SSE] Change color buttons for rules format
This commit is contained in:
parent
b5e9e4943f
commit
58276fdf3b
|
@ -390,21 +390,18 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template',
|
||||||
cls : 'btn-toolbar',
|
cls : 'btn-toolbar',
|
||||||
iconCls : 'toolbar__icon btn-fontcolor',
|
iconCls : 'toolbar__icon btn-fontcolor',
|
||||||
hint : this.textColor,
|
hint : this.textColor,
|
||||||
split : true,
|
|
||||||
additionalAlign: this.menuAddAlign,
|
additionalAlign: this.menuAddAlign,
|
||||||
color: '000000',
|
color: '000000',
|
||||||
menu : true
|
menu : true
|
||||||
});
|
});
|
||||||
this.mnuTextColorPicker = initNewColor(this.btnTextColor);
|
this.mnuTextColorPicker = initNewColor(this.btnTextColor);
|
||||||
this.btnTextColor.on('color:select', _.bind(this.onFormatTextColorSelect, this));
|
this.btnTextColor.on('color:select', _.bind(this.onFormatTextColorSelect, this));
|
||||||
this.btnTextColor.on('click', _.bind(this.onFormatTextColor, this));
|
|
||||||
|
|
||||||
this.btnFillColor = new Common.UI.ButtonColored({
|
this.btnFillColor = new Common.UI.ButtonColored({
|
||||||
parentEl: $('#format-rules-fillcolor'),
|
parentEl: $('#format-rules-fillcolor'),
|
||||||
cls : 'btn-toolbar',
|
cls : 'btn-toolbar',
|
||||||
iconCls : 'toolbar__icon btn-paracolor',
|
iconCls : 'toolbar__icon btn-paracolor',
|
||||||
hint : this.fillColor,
|
hint : this.fillColor,
|
||||||
split : true,
|
|
||||||
additionalAlign: this.menuAddAlign,
|
additionalAlign: this.menuAddAlign,
|
||||||
color: '000000',
|
color: '000000',
|
||||||
transparent: true,
|
transparent: true,
|
||||||
|
@ -412,7 +409,6 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template',
|
||||||
});
|
});
|
||||||
this.mnuFillColorPicker = initNewColor(this.btnFillColor);
|
this.mnuFillColorPicker = initNewColor(this.btnFillColor);
|
||||||
this.btnFillColor.on('color:select', _.bind(this.onFormatFillColorSelect, this));
|
this.btnFillColor.on('color:select', _.bind(this.onFormatFillColorSelect, this));
|
||||||
this.btnFillColor.on('click', _.bind(this.onFormatFillColor, this));
|
|
||||||
|
|
||||||
this.btnBorders = new Common.UI.Button({
|
this.btnBorders = new Common.UI.Button({
|
||||||
parentEl : $('#format-rules-borders'),
|
parentEl : $('#format-rules-borders'),
|
||||||
|
@ -1682,10 +1678,6 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template',
|
||||||
this.previewFormat();
|
this.previewFormat();
|
||||||
},
|
},
|
||||||
|
|
||||||
onFormatTextColor: function(btn, e) {
|
|
||||||
this.mnuTextColorPicker.trigger('select', this.mnuTextColorPicker, this.mnuTextColorPicker.currentColor, true);
|
|
||||||
},
|
|
||||||
|
|
||||||
onFormatFillColorSelect: function(btn, color, fromBtn) {
|
onFormatFillColorSelect: function(btn, color, fromBtn) {
|
||||||
this.btnFillColor.currentColor = color;
|
this.btnFillColor.currentColor = color;
|
||||||
this.mnuFillColorPicker.currentColor = color;
|
this.mnuFillColorPicker.currentColor = color;
|
||||||
|
@ -1695,10 +1687,6 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template',
|
||||||
this.previewFormat();
|
this.previewFormat();
|
||||||
},
|
},
|
||||||
|
|
||||||
onFormatFillColor: function(picker, btn, e) {
|
|
||||||
this.mnuFillColorPicker.trigger('select', this.mnuFillColorPicker, this.mnuFillColorPicker.currentColor, true);
|
|
||||||
},
|
|
||||||
|
|
||||||
onNumberFormatSelect: function(combo, record) {
|
onNumberFormatSelect: function(combo, record) {
|
||||||
!this.xfsFormat && (this.xfsFormat = new Asc.asc_CellXfs());
|
!this.xfsFormat && (this.xfsFormat = new Asc.asc_CellXfs());
|
||||||
this.xfsFormat.asc_setNumFormatInfo(record.format);
|
this.xfsFormat.asc_setNumFormatInfo(record.format);
|
||||||
|
|
Loading…
Reference in a new issue