[SSE] Fix Bug 33478.
This commit is contained in:
parent
9662133543
commit
c258a6d81b
|
@ -59,7 +59,8 @@ define([
|
||||||
enableKeyEvents : false,
|
enableKeyEvents : false,
|
||||||
beforeOpenHandler : null,
|
beforeOpenHandler : null,
|
||||||
additionalMenuItems : null,
|
additionalMenuItems : null,
|
||||||
showLast: true
|
showLast: true,
|
||||||
|
minWidth: -1
|
||||||
},
|
},
|
||||||
|
|
||||||
template: _.template([
|
template: _.template([
|
||||||
|
@ -86,6 +87,7 @@ define([
|
||||||
this.rootHeight = 0;
|
this.rootHeight = 0;
|
||||||
this.rendered = false;
|
this.rendered = false;
|
||||||
this.needFillComboView = false;
|
this.needFillComboView = false;
|
||||||
|
this.minWidth = this.options.minWidth;
|
||||||
|
|
||||||
this.fieldPicker = new Common.UI.DataView({
|
this.fieldPicker = new Common.UI.DataView({
|
||||||
cls: 'field-picker',
|
cls: 'field-picker',
|
||||||
|
@ -215,6 +217,8 @@ define([
|
||||||
width = this.cmpEl.width(),
|
width = this.cmpEl.width(),
|
||||||
height = this.cmpEl.height();
|
height = this.cmpEl.height();
|
||||||
|
|
||||||
|
if (width < this.minWidth) return;
|
||||||
|
|
||||||
if (this.rootWidth != width || this.rootHeight != height) {
|
if (this.rootWidth != width || this.rootHeight != height) {
|
||||||
this.rootWidth = width;
|
this.rootWidth = width;
|
||||||
this.rootHeight = height;
|
this.rootHeight = height;
|
||||||
|
@ -420,7 +424,7 @@ define([
|
||||||
|
|
||||||
var indexRec = store.indexOf(record),
|
var indexRec = store.indexOf(record),
|
||||||
countRec = store.length,
|
countRec = store.length,
|
||||||
maxViewCount = Math.floor((fieldPickerEl.width()) / (me.itemWidth + (me.itemMarginLeft || 0) + (me.itemMarginRight || 0) + (me.itemPaddingLeft || 0) + (me.itemPaddingRight || 0) +
|
maxViewCount = Math.floor(Math.max(fieldPickerEl.width(), me.minWidth) / (me.itemWidth + (me.itemMarginLeft || 0) + (me.itemMarginRight || 0) + (me.itemPaddingLeft || 0) + (me.itemPaddingRight || 0) +
|
||||||
(me.itemBorderLeft || 0) + (me.itemBorderRight || 0))),
|
(me.itemBorderLeft || 0) + (me.itemBorderRight || 0))),
|
||||||
newStyles = [];
|
newStyles = [];
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue