Fix Bug 55810
This commit is contained in:
parent
ba66b2522f
commit
5b98b5b183
|
@ -223,6 +223,7 @@ define([
|
||||||
listenStoreEvents: true,
|
listenStoreEvents: true,
|
||||||
allowScrollbar: true,
|
allowScrollbar: true,
|
||||||
scrollAlwaysVisible: false,
|
scrollAlwaysVisible: false,
|
||||||
|
minScrollbarLength: 40,
|
||||||
showLast: true,
|
showLast: true,
|
||||||
useBSKeydown: false,
|
useBSKeydown: false,
|
||||||
cls: ''
|
cls: ''
|
||||||
|
@ -272,6 +273,7 @@ define([
|
||||||
me.listenStoreEvents= (me.options.listenStoreEvents!==undefined) ? me.options.listenStoreEvents : true;
|
me.listenStoreEvents= (me.options.listenStoreEvents!==undefined) ? me.options.listenStoreEvents : true;
|
||||||
me.allowScrollbar = (me.options.allowScrollbar!==undefined) ? me.options.allowScrollbar : true;
|
me.allowScrollbar = (me.options.allowScrollbar!==undefined) ? me.options.allowScrollbar : true;
|
||||||
me.scrollAlwaysVisible = me.options.scrollAlwaysVisible || false;
|
me.scrollAlwaysVisible = me.options.scrollAlwaysVisible || false;
|
||||||
|
me.minScrollbarLength = me.options.minScrollbarLength || 40;
|
||||||
me.tabindex = me.options.tabindex || 0;
|
me.tabindex = me.options.tabindex || 0;
|
||||||
me.delayRenderTips = me.options.delayRenderTips || false;
|
me.delayRenderTips = me.options.delayRenderTips || false;
|
||||||
if (me.parentMenu)
|
if (me.parentMenu)
|
||||||
|
@ -355,7 +357,7 @@ define([
|
||||||
this.scroller = new Common.UI.Scroller({
|
this.scroller = new Common.UI.Scroller({
|
||||||
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
||||||
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
||||||
minScrollbarLength : 40,
|
minScrollbarLength : this.minScrollbarLength,
|
||||||
wheelSpeed: 10,
|
wheelSpeed: 10,
|
||||||
alwaysVisibleY: this.scrollAlwaysVisible
|
alwaysVisibleY: this.scrollAlwaysVisible
|
||||||
});
|
});
|
||||||
|
@ -548,7 +550,7 @@ define([
|
||||||
this.scroller = new Common.UI.Scroller({
|
this.scroller = new Common.UI.Scroller({
|
||||||
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
||||||
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
||||||
minScrollbarLength : 40,
|
minScrollbarLength : this.minScrollbarLength,
|
||||||
wheelSpeed: 10,
|
wheelSpeed: 10,
|
||||||
alwaysVisibleY: this.scrollAlwaysVisible
|
alwaysVisibleY: this.scrollAlwaysVisible
|
||||||
});
|
});
|
||||||
|
@ -816,7 +818,7 @@ define([
|
||||||
paddings = parseInt(menuRoot.css('padding-top')) + parseInt(menuRoot.css('padding-bottom')),
|
paddings = parseInt(menuRoot.css('padding-top')) + parseInt(menuRoot.css('padding-bottom')),
|
||||||
menuH = menuRoot.outerHeight(),
|
menuH = menuRoot.outerHeight(),
|
||||||
top = parseInt(menuRoot.css('top')),
|
top = parseInt(menuRoot.css('top')),
|
||||||
props = {minScrollbarLength : 40};
|
props = {minScrollbarLength : this.minScrollbarLength};
|
||||||
this.scrollAlwaysVisible && (props.alwaysVisibleY = this.scrollAlwaysVisible);
|
this.scrollAlwaysVisible && (props.alwaysVisibleY = this.scrollAlwaysVisible);
|
||||||
|
|
||||||
if (top + menuH > docH ) {
|
if (top + menuH > docH ) {
|
||||||
|
@ -987,7 +989,7 @@ define([
|
||||||
this.scroller = new Common.UI.Scroller({
|
this.scroller = new Common.UI.Scroller({
|
||||||
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
||||||
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
||||||
minScrollbarLength : 40,
|
minScrollbarLength : this.minScrollbarLength,
|
||||||
wheelSpeed: 10,
|
wheelSpeed: 10,
|
||||||
alwaysVisibleY: this.scrollAlwaysVisible
|
alwaysVisibleY: this.scrollAlwaysVisible
|
||||||
});
|
});
|
||||||
|
@ -1079,7 +1081,7 @@ define([
|
||||||
this.scroller = new Common.UI.Scroller({
|
this.scroller = new Common.UI.Scroller({
|
||||||
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
el: $(this.el).find('.inner').addBack().filter('.inner'),
|
||||||
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
useKeyboard: this.enableKeyEvents && !this.handleSelect,
|
||||||
minScrollbarLength : 40,
|
minScrollbarLength : this.minScrollbarLength,
|
||||||
wheelSpeed: 10,
|
wheelSpeed: 10,
|
||||||
alwaysVisibleY: this.scrollAlwaysVisible
|
alwaysVisibleY: this.scrollAlwaysVisible
|
||||||
});
|
});
|
||||||
|
@ -1287,7 +1289,7 @@ define([
|
||||||
paddings = parseInt(menuRoot.css('padding-top')) + parseInt(menuRoot.css('padding-bottom')),
|
paddings = parseInt(menuRoot.css('padding-top')) + parseInt(menuRoot.css('padding-bottom')),
|
||||||
menuH = menuRoot.outerHeight(),
|
menuH = menuRoot.outerHeight(),
|
||||||
top = parseInt(menuRoot.css('top')),
|
top = parseInt(menuRoot.css('top')),
|
||||||
props = {minScrollbarLength : 40};
|
props = {minScrollbarLength : this.minScrollbarLength};
|
||||||
this.scrollAlwaysVisible && (props.alwaysVisibleY = this.scrollAlwaysVisible);
|
this.scrollAlwaysVisible && (props.alwaysVisibleY = this.scrollAlwaysVisible);
|
||||||
|
|
||||||
if (top + menuH > docH ) {
|
if (top + menuH > docH ) {
|
||||||
|
|
|
@ -235,31 +235,31 @@ define([
|
||||||
var isExpanded = !record.get('isExpanded');
|
var isExpanded = !record.get('isExpanded');
|
||||||
record.set('isExpanded', isExpanded);
|
record.set('isExpanded', isExpanded);
|
||||||
this.store[(isExpanded) ? 'expandSubItems' : 'collapseSubItems'](record);
|
this.store[(isExpanded) ? 'expandSubItems' : 'collapseSubItems'](record);
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
} else
|
} else
|
||||||
Common.UI.DataView.prototype.onClickItem.call(this, view, record, e);
|
Common.UI.DataView.prototype.onClickItem.call(this, view, record, e);
|
||||||
},
|
},
|
||||||
|
|
||||||
expandAll: function() {
|
expandAll: function() {
|
||||||
this.store.expandAll();
|
this.store.expandAll();
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
},
|
},
|
||||||
|
|
||||||
collapseAll: function() {
|
collapseAll: function() {
|
||||||
this.store.collapseAll();
|
this.store.collapseAll();
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
},
|
},
|
||||||
|
|
||||||
expandToLevel: function(expandLevel) {
|
expandToLevel: function(expandLevel) {
|
||||||
this.store.expandToLevel(expandLevel);
|
this.store.expandToLevel(expandLevel);
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
},
|
},
|
||||||
|
|
||||||
expandRecord: function(record) {
|
expandRecord: function(record) {
|
||||||
if (record) {
|
if (record) {
|
||||||
record.set('isExpanded', true);
|
record.set('isExpanded', true);
|
||||||
this.store.expandSubItems(record);
|
this.store.expandSubItems(record);
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -267,7 +267,7 @@ define([
|
||||||
if (record) {
|
if (record) {
|
||||||
record.set('isExpanded', false);
|
record.set('isExpanded', false);
|
||||||
this.store.collapseSubItems(record);
|
this.store.collapseSubItems(record);
|
||||||
this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: this.scrollAlwaysVisible});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength, alwaysVisibleY: this.scrollAlwaysVisible});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -85,6 +85,14 @@ define([
|
||||||
storeUsers: this.getApplication().getCollection('Common.Collections.Users'),
|
storeUsers: this.getApplication().getCollection('Common.Collections.Users'),
|
||||||
storeMessages: this.getApplication().getCollection('Common.Collections.ChatMessages')
|
storeMessages: this.getApplication().getCollection('Common.Collections.ChatMessages')
|
||||||
});
|
});
|
||||||
|
this.panelChat.on('render:after', _.bind(this.onAfterRender, this));
|
||||||
|
},
|
||||||
|
|
||||||
|
onAfterRender: function(panel) {
|
||||||
|
var viewport = this.getApplication().getController('Viewport').getView('Viewport');
|
||||||
|
viewport.hlayout.on('layout:resizedrag', _.bind(function () {
|
||||||
|
panel && panel.updateScrolls();
|
||||||
|
}, this));
|
||||||
},
|
},
|
||||||
|
|
||||||
setMode: function(mode) {
|
setMode: function(mode) {
|
||||||
|
|
|
@ -262,7 +262,7 @@ define([
|
||||||
store.where({isRevision: false}).forEach(function(item){
|
store.where({isRevision: false}).forEach(function(item){
|
||||||
item.set('isVisible', needExpand);
|
item.set('isVisible', needExpand);
|
||||||
});
|
});
|
||||||
this.panelHistory.viewHistoryList.scroller.update({minScrollbarLength: 40});
|
this.panelHistory.viewHistoryList.scroller.update({minScrollbarLength: this.panelHistory.viewHistoryList.minScrollbarLength});
|
||||||
this.panelHistory.btnExpand.cmpEl.text(needExpand ? this.panelHistory.textHideAll : this.panelHistory.textShowAll);
|
this.panelHistory.btnExpand.cmpEl.text(needExpand ? this.panelHistory.textHideAll : this.panelHistory.textShowAll);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -136,7 +136,7 @@ define([
|
||||||
this.txtMessage.on('keydown', _.bind(this._onKeyDown, this));
|
this.txtMessage.on('keydown', _.bind(this._onKeyDown, this));
|
||||||
|
|
||||||
this.setupLayout();
|
this.setupLayout();
|
||||||
|
this.trigger('render:after', this);
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -492,7 +492,7 @@ define([
|
||||||
},
|
},
|
||||||
updateScrolls: function () {
|
updateScrolls: function () {
|
||||||
if (this.commentsView && this.commentsView.scroller) {
|
if (this.commentsView && this.commentsView.scroller) {
|
||||||
this.commentsView.scroller.update({minScrollbarLength: 40, alwaysVisibleY: true});
|
this.commentsView.scroller.update({minScrollbarLength: this.commentsView.minScrollbarLength, alwaysVisibleY: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -110,7 +110,7 @@ define([
|
||||||
for(var i=1; i<revisions.length; i++)
|
for(var i=1; i<revisions.length; i++)
|
||||||
revisions[i].set('isVisible', isExpanded);
|
revisions[i].set('isVisible', isExpanded);
|
||||||
}
|
}
|
||||||
this.scroller.update({minScrollbarLength: 40});
|
this.scroller.update({minScrollbarLength: this.minScrollbarLength});
|
||||||
} else
|
} else
|
||||||
Common.UI.DataView.prototype.onClickItem.call(this, view, record, e);
|
Common.UI.DataView.prototype.onClickItem.call(this, view, record, e);
|
||||||
me.btnExpand.cmpEl.text(me.storeHistory.hasCollapsed() ? me.textShowAll : me.textHideAll);
|
me.btnExpand.cmpEl.text(me.storeHistory.hasCollapsed() ? me.textShowAll : me.textHideAll);
|
||||||
|
|
|
@ -72,7 +72,8 @@ define([
|
||||||
emptyText: this.txtEmpty,
|
emptyText: this.txtEmpty,
|
||||||
emptyItemText: this.txtEmptyItem,
|
emptyItemText: this.txtEmptyItem,
|
||||||
style: 'border: none;',
|
style: 'border: none;',
|
||||||
delayRenderTips: true
|
delayRenderTips: true,
|
||||||
|
minScrollbarLength: 25
|
||||||
});
|
});
|
||||||
this.viewNavigationList.cmpEl.off('click');
|
this.viewNavigationList.cmpEl.off('click');
|
||||||
this.navigationMenu = new Common.UI.Menu({
|
this.navigationMenu = new Common.UI.Menu({
|
||||||
|
|
|
@ -1356,7 +1356,7 @@ define([
|
||||||
|
|
||||||
if(Common.Utils.InternalSettings.get('sse-settings-size-filter-window')) {
|
if(Common.Utils.InternalSettings.get('sse-settings-size-filter-window')) {
|
||||||
this.$window.find('.combo-values').css({'height': Common.Utils.InternalSettings.get('sse-settings-size-filter-window')[1] - 103 + 'px'});
|
this.$window.find('.combo-values').css({'height': Common.Utils.InternalSettings.get('sse-settings-size-filter-window')[1] - 103 + 'px'});
|
||||||
this.cellsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.cellsList.scroller.update({minScrollbarLength : this.cellsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -1684,7 +1684,7 @@ define([
|
||||||
this.configTo.asc_getFilterObj().asc_setType(Asc.c_oAscAutoFilterTypes.Filters);
|
this.configTo.asc_getFilterObj().asc_setType(Asc.c_oAscAutoFilterTypes.Filters);
|
||||||
|
|
||||||
// listView.isSuspendEvents = false;
|
// listView.isSuspendEvents = false;
|
||||||
listView.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
listView.scroller.update({minScrollbarLength : listView.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -1943,7 +1943,7 @@ define([
|
||||||
this.checkCellTrigerBlock = undefined;
|
this.checkCellTrigerBlock = undefined;
|
||||||
}
|
}
|
||||||
this.btnOk.setDisabled(this.cells.length<1);
|
this.btnOk.setDisabled(this.cells.length<1);
|
||||||
this.cellsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.cellsList.scroller.update({minScrollbarLength : this.cellsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
this.cellsList.cmpEl.toggleClass('scroll-padding', this.cellsList.scroller.isVisible());
|
this.cellsList.cmpEl.toggleClass('scroll-padding', this.cellsList.scroller.isVisible());
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -2027,7 +2027,7 @@ define([
|
||||||
else if (this.curSize.resize) {
|
else if (this.curSize.resize) {
|
||||||
var size = this.getSize();
|
var size = this.getSize();
|
||||||
this.$window.find('.combo-values').css({'height': size[1] - 100 + 'px'});
|
this.$window.find('.combo-values').css({'height': size[1] - 100 + 'px'});
|
||||||
this.cellsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.cellsList.scroller.update({minScrollbarLength : this.cellsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -2038,7 +2038,7 @@ define([
|
||||||
if (size[1] !== this.curSize.height) {
|
if (size[1] !== this.curSize.height) {
|
||||||
if (!this.curSize.resize) {
|
if (!this.curSize.resize) {
|
||||||
this.curSize.resize = true;
|
this.curSize.resize = true;
|
||||||
this.cellsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: false, suppressScrollX: true});
|
this.cellsList.scroller.update({minScrollbarLength : this.cellsList.minScrollbarLength, alwaysVisibleY: false, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
this.$window.find('.combo-values').css({'height': size[1] - 100 + 'px'});
|
this.$window.find('.combo-values').css({'height': size[1] - 100 + 'px'});
|
||||||
this.curSize.height = size[1];
|
this.curSize.height = size[1];
|
||||||
|
|
|
@ -431,7 +431,7 @@ define([
|
||||||
});
|
});
|
||||||
if (!equalArr) {
|
if (!equalArr) {
|
||||||
list.store.reset(arr);
|
list.store.reset(arr);
|
||||||
list.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
list.scroller.update({minScrollbarLength : list.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
list.dataViewItems.forEach(function (item, index) {
|
list.dataViewItems.forEach(function (item, index) {
|
||||||
item.$el.attr('draggable', true);
|
item.$el.attr('draggable', true);
|
||||||
item.$el.on('dragstart', _.bind(me.onItemsDragStart, me, eventIndex, list, item, index));
|
item.$el.on('dragstart', _.bind(me.onItemsDragStart, me, eventIndex, list, item, index));
|
||||||
|
@ -500,7 +500,7 @@ define([
|
||||||
});
|
});
|
||||||
if (!equalArr) {
|
if (!equalArr) {
|
||||||
this.fieldsList.store.reset(arr);
|
this.fieldsList.store.reset(arr);
|
||||||
this.fieldsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.fieldsList.scroller.update({minScrollbarLength : this.fieldsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
this.fieldsList.dataViewItems.forEach(function (item, index) {
|
this.fieldsList.dataViewItems.forEach(function (item, index) {
|
||||||
item.$el.attr('draggable', true);
|
item.$el.attr('draggable', true);
|
||||||
item.$el.on('dragstart', _.bind(me.onFieldsDragStart, me, item, index));
|
item.$el.on('dragstart', _.bind(me.onFieldsDragStart, me, item, index));
|
||||||
|
@ -633,7 +633,7 @@ define([
|
||||||
}
|
}
|
||||||
|
|
||||||
// listView.isSuspendEvents = false;
|
// listView.isSuspendEvents = false;
|
||||||
listView.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
listView.scroller.update({minScrollbarLength : listView.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -368,7 +368,7 @@ define([
|
||||||
});
|
});
|
||||||
|
|
||||||
this.optionsList.store.reset(arr);
|
this.optionsList.store.reset(arr);
|
||||||
this.optionsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.optionsList.scroller.update({minScrollbarLength : this.optionsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
},
|
},
|
||||||
|
|
||||||
getSettings: function() {
|
getSettings: function() {
|
||||||
|
|
|
@ -160,7 +160,7 @@ define([
|
||||||
throughIndex : 0
|
throughIndex : 0
|
||||||
}));
|
}));
|
||||||
this.columnsList.store.reset(arr);
|
this.columnsList.store.reset(arr);
|
||||||
this.columnsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.columnsList.scroller.update({minScrollbarLength : this.columnsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
} else {
|
} else {
|
||||||
this.props.asc_getColumnList().forEach(function (item, index) {
|
this.props.asc_getColumnList().forEach(function (item, index) {
|
||||||
store.at(index+1).set('value', item.asc_getVal());
|
store.at(index+1).set('value', item.asc_getVal());
|
||||||
|
@ -246,7 +246,7 @@ define([
|
||||||
this.checkCellTrigerBlock = undefined;
|
this.checkCellTrigerBlock = undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
listView.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
listView.scroller.update({minScrollbarLength : listView.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -119,7 +119,7 @@ define([
|
||||||
});
|
});
|
||||||
|
|
||||||
this.columnsList.store.reset(arr);
|
this.columnsList.store.reset(arr);
|
||||||
this.columnsList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true, suppressScrollX: true});
|
this.columnsList.scroller.update({minScrollbarLength : this.columnsList.minScrollbarLength, alwaysVisibleY: true, suppressScrollX: true});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue