Results 1 to 3 of 3

Thread: "orientationchange" event does not fire in Chrome Mobile

Hybrid View

Previous Post Previous Post   Next Post Next Post
    Success! Looks like we've fixed this one. According to our records the fix was applied for TOUCH-3572 in a recent build.
  1. #1
    Ext JS Premium Member
    Join Date
    Nov 2011
    Posts
    8
    Vote Rating
    0
      0  

    Default "orientationchange" event does not fire in Chrome Mobile

    REQUIRED INFORMATION

    Framework version tested:

    • Touch 2.1.0-rc1
    Browser versions tested against:
    • Android 4.0.4 Chrome 18.0.1025308
    Description:
    • "orientationchange" event does not fire in Chrome Mobile
    Steps to reproduce the problem:
    • Run the test case below
    • Change the orientation and observe that the alert is not shown
    Test Case

    Code:
    Ext.application({
        name: 'ChromeOrientationTest',
      
        launch: function() {
            Ext.Viewport.on({
                orientationchange: function() {
                    alert(Ext.Viewport.getOrientation());
                }
            });
        }
    });
    Debugging Already Done

    I believe this bug was introduced in RC1 by this item in the changelog: "Chrome Mobile will now use the Default Viewport". For fun, I changed it back to use the Android Viewport and the issue went away. However, I believe the real fix is probably in the Default Viewport with the code below.

    Possible Fix

    change
    src\viewport\Default.js line 168
    Code:
    if (!Ext.os.is.Android) {
    to
    Code:
    if (!Ext.os.is.Android || Ext.browser.name == 'ChromeMobile') {

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,422
    Vote Rating
    1271
      0  

    Default

    Thanks for the report! I have opened a bug in our bug tracker.

  3. #3
    Sencha User Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Vote Rating
    19
      0  

    Default

    This has been fixed for the next release.

    Sencha Inc

    Jamie Avins

    @jamieavins

Posting Permissions

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