-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Normal
-
Affects Version/s: 8.5.1.2
-
Component/s: Components
-
Security Level: Jimmy
-
ZK 8.5.2 S1
-
None
Steps to Reproduce
open rod-grid-column-scroll-pos.zul
scroll down until ROD loads new rows
hide a column (using the column menu popup, or the debug buttons below the grid)
Current Result
scroll position changes to an incorrect position
Expected Result
scroll position should be preserved
Debug Info
after showing/hiding a column the scroll paddings tpad/bpad are reset to a 0 height.
Workaround
init the grid's scroll-paddings when changing the column visibility
(causes a short flickering in FF, edge - chrome looks stable)
zk.afterLoad('zul.grid', function() { var xColumn = {}; zk.override(zul.grid.Column.prototype, xColumn, { setVisible : function() { var result = xColumn.setVisible.apply(this, arguments); setTimeout(() => this.getGrid()._initPadSizes(), 0); return result; } });//zk.override });//zk.afterLoad