Results 1 to 3 of 3

Thread: [OPEN] Mouse scrolling on a grid scrolls both horizontally and vertically

    Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJS-4017 in a recent build.
  1. #1
    Sencha User
    Join Date
    Feb 2011
    Posts
    40
    Vote Rating
    0
      0  

    Default [OPEN] Mouse scrolling on a grid scrolls both horizontally and vertically

    I'm starting to get worryingly familiar with submitting bug reports.

    REQUIRED INFORMATION


    Ext version tested:
    • Ext 4.0.2a


    Browser versions tested against:
    • FF3.6
    • Chromium 14


    Description:
    • When you scroll all the way to the bottom-right of a grid with both horizontal and vertical bars visible, then scroll up, it scrolls BOTH the horizontal and vertical bars at the same time. The horizontal then KEEPS scrolling to the left regardless of whether or not you scroll up or down.


    Steps to reproduce the problem:
    • Scroll all the way to the bottom right of the grid
    • Scroll up


    Test Case:

    Code:
    Ext.onReady(function() {
        var i, j;
    
        var fields = []
        for(j = 1; j <= 100; ++j) {
            fields.push('field'+j);
        }
    
        var dataItems = []
        for(i = 1; i <= 20; ++i) {
            var item = {}
            Ext.each(fields, function(field) {
                item[field] = field + ' ' + i;
            });
            dataItems.push(item);
        }
    
        var store = Ext.create('Ext.data.Store', {
            'fields': fields,
            data: {
                'items': dataItems
            },
            proxy: {
                type: 'memory',
                reader: {
                    type: 'json',
                    root: 'items'
                }
            }
        });
    
        var columns = []
        Ext.each(fields, function(column) {
            columns.push({
                dataIndex: column,
                header: column
            });
        });
        var grid = Ext.create('Ext.grid.Panel', {
            title: 'Lots of columns',
            store: store,
            selType: 'cellmodel',
            'columns': columns,
            height: 200,
    
            renderTo: 'container'
        });
    });
    --
    Asfand Qazi

  2. #2
    Sencha User
    Join Date
    Jun 2011
    Location
    Boston
    Posts
    86
    Vote Rating
    5
      0  

    Default

    This made it into 4.0.7. Meanwhile, here's an override:

    Code:
    Ext.override(Ext.EventObjectImpl, {
        correctWheelDelta: function (delta) {
            var scale = this.WHEEL_SCALE,
                ret = Math.round(delta/scale);
     
            if (!ret && delta) {
                ret = (delta < 0) ? -1 : 1;
            }
            return ret;
        }
    });

  3. #3
    Sencha User
    Join Date
    Sep 2011
    Posts
    31
    Vote Rating
    0
      0  

    Default

    Ext 4.0.7 is released, with the bug fixed? Perfect

    Edit: sorry, misread. It WILL be in Ext 4.0.7 when it is released.
    --
    Regards,
    Asfand Qazi
    Team 87 HTGT
    Sanger Institute

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •