PDA

View Full Version : [CLOSED] Scroll bar in grid panel stops responding



Albinoswordfish
25 Jun 2011, 1:48 PM
REQUIRED INFORMATION


Ext version tested:

Ext 4.0.2a


Browser versions tested against:

FF3.6.18
Chrome


Description:

When using a grid panel, if the the number of columns change using the reconfigure() method and a scroll bar recalculation occurs, sometimes the horizontal scroll bar stops responding as in the scroll bar shows up with the correct dimensions, however moving the scroll does not change the view. I'm not sure if it's related but I found a post which states a similar behavior regarding the scroll bar randomly becoming non responsive. The link can be found in the debug section.


Steps to reproduce the problem:

Create a grid panel with enough columns to force a horizontal scroll bar
call reconfigure() with a small amount of columns so that the horizontal scroll bar doesn't show up.
call reconfigure() with the original set of columns


The result that was expected:

Horizontal scroll bar continues to be responsive and be able to scroll through the grid panel.


The result that occurs instead:

Scroll bar shows up but doesn't move the grid panel view when the scroll bar is moved


HELPFUL INFORMATION

Debugging already done:

http://www.sencha.com/forum/showthread.php?137317-4.0.2a-Strange-scrollbar-behavior&highlight=scroll


Operating System:
[LIST]
WinXP

mitchellsimoens
25 Jun 2011, 5:41 PM
The scroll bars are getting an over haul. Thank you for your report though.

westy
27 Jul 2011, 11:50 PM
Hmm, have seen this happen with the tree too.
Hopefully that'll get picked up in the overhaul as well.

What release that targetting Mitchell?

Cheers,
Westy

mitchellsimoens
28 Jul 2011, 4:57 AM
Hmm, have seen this happen with the tree too.
Hopefully that'll get picked up in the overhaul as well.

What release that targetting Mitchell?

Cheers,
Westy

Unfortunately 4.1 will have lots of Grid improvements including scrolling. 4.1 looks to go into beta in Aug/Sept time.

madhu4extjs
19 Aug 2011, 10:46 AM
Ext version tested:

Ext 4.0.2a


Browser versions tested against:

FF6.0
Chrome 13.0
Safari 5.0.5


Steps to reproduce the problem:

http://dev.sencha.com/deploy/ext-4.0.2a/examples/layout-browser/layout-browser.html
Combination Examples > Tabs with Nested Layouts > Inner Tab 2 > Nested Grid
Maximize the browser window so that the scroll bar does not show up
Minimize it to get back the scroll bar
Again, Maximize the browser
Now on, if you minimize the browser, the scroll appears but the data in the grid does not scroll when the scroll bar is moved.

The result that was expected:

Vertical scroll bar continues to be responsive and be able to scroll through the grid panel.


The result that occurs:


FF 6.0

Scroll bar shows up but doesn't move the grid panel view when the scroll bar is moved

Chrome 13.0

OK - It works even after repeated maximize/minimize cycles

Safari 5.0.5

OK - It works even after repeated maximize/minimize cycles


OS:

WinXP

James Goddard
22 Aug 2011, 4:18 AM
Unfortunately 4.1 will have lots of Grid improvements including scrolling. 4.1 looks to go into beta in Aug/Sept time.

Does this mean Sencha is no longer supporting or fixing bugs in 4.0.x?

madhu4extjs
22 Aug 2011, 9:12 AM
http://www.sencha.com/blog/what-to-expect-in-ext-js-4-1/

Going by the above blog post, I think upgrading to 4.1 is the only choice. Its not clear whether the Grid related fixes will be ported back to 4.0.x.

Hope 4.1 is released as promised.

regards,
Madhu

dj
29 Aug 2011, 4:10 AM
Looks like I hit the same bug - the following workaround seems to work:


Add this to you overrides file:


Ext.require('Ext.grid.Panel', function(){
Ext.grid.Panel.override({
scrollerFix: function(){
var me = this,
vertScroller = me.getVerticalScroller(),
horzScroller = me.getHorizontalScroller();
if (vertScroller && vertScroller.scrollEl && vertScroller.scrollEl.dom) {
vertScroller.mun(vertScroller.scrollEl, 'scroll', vertScroller.onElScroll, vertScroller);
vertScroller.mon(vertScroller.scrollEl, 'scroll', vertScroller.onElScroll, vertScroller);
}
if (horzScroller && horzScroller.scrollEl && horzScroller.scrollEl.dom) {
horzScroller.mun(horzScroller.scrollEl, 'scroll', horzScroller.onElScroll, horzScroller);
horzScroller.mon(horzScroller.scrollEl, 'scroll', horzScroller.onElScroll, horzScroller);
}
}
});
});


... and then call the #scrollerFix method when you encounter the bug. I call it in an load event handler of the grid's store.

SebTardif
16 Sep 2011, 6:04 AM
Maybe related to the following which has simpler workaround -> http://www.sencha.com/forum/showthread.php?137993-4.0.2-only-layout-fit-grid-scrollbar-when-used-does-not-scroll-content&p=649561#post649561

dj
16 Sep 2011, 10:27 AM
Yes, this fix looks better / is more elegant