Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: Combobox and jQuery and IE - Dropdown Position Offset

  1. #1

    Default Combobox and jQuery and IE - Dropdown Position Offset

    I was trying to track down a bug in my code locally, but I've isolated it to jQuery and IE. A combobox appears to be offset by several pixels. The attached image is from:

    Examples and Demos/Form and ComboBox/Dynamic Forms

    The bug is also present in the current API examples...
    Attached Images Attached Images

  2. #2
    Sencha User
    Join Date
    Mar 2007
    Location
    New York, NY
    Posts
    6,956

    Default

    Your will have to post this to the jquery dimensions plugin. It provides those coordinates when using jQuery.

  3. #3
    Ext JS Premium Member
    Join Date
    Apr 2007
    Posts
    298

    Default

    Is this the same as the serious bug when migrating from 1.0 to 1.0.1 with jquery?

    Just open http://extjs.com/deploy/ext/examples...edit-grid.html, select the jquery adapter and scroll down in the table. Now click on "Light"-column und you will have the same offset as the scroll offset.

    Or have I missed another bug report?

    JOERN

  4. #4

    Default

    Quote Originally Posted by jheid View Post
    Is this the same as the serious bug when migrating from 1.0 to 1.0.1 with jquery?

    Just open http://extjs.com/deploy/ext/examples...edit-grid.html, select the jquery adapter and scroll down in the table. Now click on "Light"-column und you will have the same offset as the scroll offset.

    Or have I missed another bug report?

    JOERN
    I can't duplicate the test case that you describe with IE6 and jQuery . We must be talking about different bugs..

  5. #5
    Sencha User
    Join Date
    Mar 2007
    Location
    New York, NY
    Posts
    6,956

    Default

    Offsets are calculated differently based on the container of the element. Somewhere, the jQuery plugin is missing part of the calculation. To be honest, I am not sure what it is missing.

  6. #6
    Ext JS Premium Member
    Join Date
    Apr 2007
    Posts
    298

    Default

    Quote Originally Posted by jack.slocum View Post
    Offsets are calculated differently based on the container of the element. Somewhere, the jQuery plugin is missing part of the calculation. To be honest, I am not sure what it is missing.
    Yes, but the example (and my application) works perfectly with 1.0 and the problem occured with 1.0.1 (same jquery.js and dimensions.js).

    Could you see the problem with the demo (I tested it with IE 7 and FF 2.0.x)?

  7. #7
    Sencha User
    Join Date
    Mar 2007
    Location
    New York, NY
    Posts
    6,956

    Default

    Try adding this somewhere after Ext:

    Code:
    Ext.lib.Dom.getXY = function(){
            var o = jQuery(el).offset();
            return [o.left,  o.top];
    }

  8. #8

    Default

    Quote Originally Posted by jack.slocum View Post
    Try adding this somewhere after Ext:

    Code:
    Ext.lib.Dom.getXY = function(){
            var o = jQuery(el).offset();
            return [o.left,  o.top];
    }
    IE error: 'el' is undefined

  9. #9
    Sencha User
    Join Date
    Mar 2007
    Posts
    7,854

    Default

    That should be
    Code:
    Ext.lib.Dom.getXY = function(el){
            var o = jQuery(el).offset();
            return [o.left,  o.top];
    }\

  10. #10
    Ext JS Premium Member
    Join Date
    Apr 2007
    Posts
    298

    Default

    Quote Originally Posted by jack.slocum View Post
    Try adding this somewhere after Ext:

    Code:
    Ext.lib.Dom.getXY = function(el){
            var o = jQuery(el).offset();
            return [o.left,  o.top];
    }
    Thanks, it works.

Page 1 of 2 12 LastLast

Posting Permissions

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