Looks like we cannot reproduce this. Please provide another test case to reproduce this issue.
  1. #1
    Sencha User armode's Avatar
    Join Date
    Nov 2011
    Location
    Germany / Darmstadt
    Posts
    64
    Vote Rating
    4
    armode is on a distinguished road

      0  

    Default orientationchange event fires not on iPhone in landscape modus

    orientationchange event fires not on iPhone in landscape modus


    REQUIRED INFORMATION
    Ext version tested:
    • ST 2.2
    Browser versions tested against:
    • mobile Safari
    DOCTYPE tested against:
    • <!DOCTYPE HTML>
    Description:

    I had a strange problem with the orientationchange event, which wasn't fired on my iPhone, when I turned my phone from portrait to landscape mode.

    Today I figuered out, that the event doesn't fire, when I'm in Safari's full screen mode. I'm talking not about the home screen web app feature, but about the button in Safari's bottom toolbar to maximize the screen. This button was added with iOS 6 and appears only on an iPhone in landscape mode.

    And the second thing what prevents that the event will be fired, is the viewport option autoMaximize: true

    Steps to reproduce the problem:


    Launch the demo app on your iPhone with iOS 6 in Safari. Go to landscape mode and activate the "full screen option" (screenshot) There're other issues that the resizing is not correct, so better reload the app. Switch now from portrait to landscape mode and back. You'll see the alert msg only in portrait mode. If you set autoMaximize to false or deactivate the full screen mode the event is fired correctly.

    The result that was expected:
    • Fires when the Viewport orientation has changed
    • no matter if mobile Safari is in fullscreen mode
    • no matter if viewports autoMaximize is true or false
    The result that occurs instead:
    • if viewports autoMaximize is true and mobile Safari is in fullscreen mode the event fires only from landscape to portrait mode
    • it doesn't fire, when you switch from portrait to landscape mode!
    Test Case:
    app.js
    Code:
    Ext.application({
    ...
        viewport: {
            autoMaximize: true
        }
    ...
    view: Main.js
    Code:
    Ext.define('lastTest.view.Main', {
        extend: 'Ext.tab.Panel',
        xtype: 'main',
    ...
        initialize: function() {
            Ext.Viewport.on('orientationchange', 'handleOrientationchange', this, {
                buffer: 50
            });
        },
    ...
        handleOrientationchange: function() {
            Ext.Msg.alert('Ext.version.version:', Ext.version.version);
        }
    HELPFUL INFORMATION
    Screenshot or Video:

    Foto 23.05.13 16 26 32.png

    I created a demo app with sencha cmd and just added a listener to the orientationchange event. When the event is fired, an alert message appears.

    Video and Demo Apps with ST 2.1.1 and 2.2: https://www.dropbox.com/sh/xmn2texpad7dlcg/3j4lnUCaF6

    See this URL for live test case: http://www31.winplan-online.de/bugDemo/index.html

    Operating System:
    • iOS 6 not iOS simulator

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,065
    Vote Rating
    852
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Using 2.2.0 this alerted me before and after going fullscreen:

    Code:
    Ext.Viewport.on('orientationchange', function() {
        alert('change');
    });
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User armode's Avatar
    Join Date
    Nov 2011
    Location
    Germany / Darmstadt
    Posts
    64
    Vote Rating
    4
    armode is on a distinguished road

      0  

    Default


    I generated a second test app with ST 2.2 and have the same problems.

    You can download it here: https://www.dropbox.com/sh/xmn2texpad7dlcg/3j4lnUCaF6

    There's a short video, too, which shows the problem. By the way, if I test this with the iOS Simulator, the events were fired correctly. But not not on my iPhone

  4. #4
    Sencha User armode's Avatar
    Join Date
    Nov 2011
    Location
    Germany / Darmstadt
    Posts
    64
    Vote Rating
    4
    armode is on a distinguished road

      0  

    Default


    I have updated my first thread and used your bug template. Hope this helps to reproduce my problem...

  5. #5
    Sencha User armode's Avatar
    Join Date
    Nov 2011
    Location
    Germany / Darmstadt
    Posts
    64
    Vote Rating
    4
    armode is on a distinguished road

      0  

    Default


    I had the chance to test this bug on a second device (iPhone 5 with iOS 6.1.3) at the weekend. It's definitely reproducible.

    I created a demo app for live testing: http://www31.winplan-online.de/bugDemo/index.html
    It includes instruction to reproduce the bug...

  6. #6
    Sencha User armode's Avatar
    Join Date
    Nov 2011
    Location
    Germany / Darmstadt
    Posts
    64
    Vote Rating
    4
    armode is on a distinguished road

      0  

    Default


    I've created another test app with the 2.3b and it's fixed!

    Thx and greetings from the SenchaCon