Opened 10 years ago

Closed 6 years ago

#9464 closed defect (patchwelcome)

vertical scroll position is reset when resizing columns of a grid

Reported by: Mars Agliullin Owned by:
Priority: high Milestone: future
Component: DojoX Grid Version: 1.3.0
Keywords: grid vertical scroll Cc:
Blocked By: Blocking:

Description

How to reproduce with attached html:

  1. Make browser window small, so there is vertical scrollbar.
  2. Scroll it to the bottom.
  3. Resize any column of the lower grid.

What happens: vertical scrollbar's position is reset to top

What is expected: column resize should not impact scrollbar's position

This behaviour was observed on FF3.0 & IE6. Didn't test on other browsers.

Cause of bug: body of the grid with enabled autoHeight is hidden before column resize. Without grid's body scrollbar may disappear if there's enough space. When grid's body is shown again scrollbar's position is reset to top.

Idea of fix: explicitly replace grid's height with its actual value before resize, so vertical size of content doesn't change. Reset height to 'auto' afterwards.

BTW, the same behaviour is observed when columns are sorted. Attached patch doesn't fix that.

Attachments (2)

pane1_grid.html (3.0 KB) - added by Mars Agliullin 10 years ago.
grid_vscroll_patch.diff (759 bytes) - added by Mars Agliullin 10 years ago.

Download all attachments as: .zip

Change History (7)

Changed 10 years ago by Mars Agliullin

Attachment: pane1_grid.html added

Changed 10 years ago by Mars Agliullin

Attachment: grid_vscroll_patch.diff added

comment:1 Changed 10 years ago by Nathan Toone

Milestone: tbd1.5
Owner: changed from Bryan Forbes to Nathan Toone

comment:2 Changed 10 years ago by Mars Agliullin

My patch is under CLA. Just forgot to mark it as such.

comment:3 Changed 9 years ago by Nathan Toone

Milestone: 1.5future
Owner: Nathan Toone deleted

Moving my tickets to future, as I am not currently working on them.

comment:4 Changed 6 years ago by bill

DojoX Grid and EnhancedGrid are deprecated in favor of dgrid and gridx.

You should upgrade your code to use one of those two grids.

We will consider patches to the old DojoX Grid code though.

comment:5 Changed 6 years ago by bill

Resolution: patchwelcome
Status: newclosed
Note: See TracTickets for help on using tickets.