You found a bug! We've classified it as TOUCH-2624 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha User
    Join Date
    Jan 2009
    Posts
    10
    Vote Rating
    0
    dtnghia is on a distinguished road

      0  

    Default Navigation View - Blank Screen shown up after double tap Back button

    Navigation View - Blank Screen shown up after double tap Back button


    Kitchen Sink application crashed and shown a blank screen after couple times tap/double tap on the Back button



    REQUIRED INFORMATION



    Ext version tested:
    • Sencha Touch 2 GA
    Browser versions tested against:
    • safari (iOs 4.3.3)
    DOCTYPE tested against:
    • N/A
    Description:
    • Kitchen Sink crashed and shown a blank screen if you quick tap/double tap on the Back button to go back to the list view.
    Steps to reproduce the problem:
    • Open Kitchen Sink demo on iPhone (iOS 4.3.3)
    • Try to select any list item (User Interface, Animation, ..) then quickly tap/double tap the Back button to return the main view.
    • Repeat previous step couple times (40 to 60 times)
    The result that was expected:
    • The list view should be shown whenever you tap on Back button
    The result that occurs instead:HELPFUL INFORMATION


    Screenshot or Video:

    Debugging already done:

    Possible fix:

    Additional CSS used:

    Operating System:
    • iOs (iPhone 4.3.3)
    Thank to sencha team for your work.

  2. #2
    Sencha User Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Vote Rating
    20
    Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough

      0  

    Default


    Thank you for the report.

    Sencha Inc

    Jamie Avins

    @jamieavins

  3. #3
    Sencha User
    Join Date
    Jan 2009
    Posts
    10
    Vote Rating
    0
    dtnghia is on a distinguished road

      0  

    Default


    Root cause of this bug might be the animation effect on the back event.
    I tested on the desktop and found the list view was applied style with "-webkit-transform".
    I added "back" listener to the navigation view to remove that style and it looked working well.
    Code:
    listeners: {
    	            	    	back: function(view) {
                          Ext.defer(function() { view.element.dom.removeAttribute("style"); }, 200);
    	            	   }, 
    	            	    	scope: this
    Also found this
    http://stackoverflow.com/questions/4...elect-elements
    Looks like it has the same problem and solution with mine.

  4. #4
    Sencha User
    Join Date
    Apr 2012
    Posts
    164
    Vote Rating
    9
    in4p will become famous soon enough

      0  

    Default


    Thanks @dtnghia. This bug was causing a serious UI issue and your code helped. For my own case, I had to go a level further down in removing the style:
    Code:
    view.getActiveItem().element.dom.removeAttribute("style");
    Sencha team, any update on when this release will be fixed? I've encountered it in my apps on iOS, Android and the Blackberry Playbook. Especially on older devices with slower rendering capabilities, the user is more prone to tap the back button multiple taps further increasing the frequency that this issue is encountered.

    Quote Originally Posted by dtnghia View Post
    Root cause of this bug might be the animation effect on the back event.
    I tested on the desktop and found the list view was applied style with "-webkit-transform".
    I added "back" listener to the navigation view to remove that style and it looked working well.
    Code:
    listeners: {
                                back: function(view) {
                          Ext.defer(function() { view.element.dom.removeAttribute("style"); }, 200);
                           }, 
                                scope: this
    Also found this
    http://stackoverflow.com/questions/4...elect-elements
    Looks like it has the same problem and solution with mine.

  5. #5
    Sencha User
    Join Date
    Feb 2014
    Posts
    102
    Vote Rating
    0
    prateek204 is on a distinguished road

      0  

    Default


    Is this issue resolved?I'm using sencha touch 2.3.1 and still have this issue in windows phone. My app works fine in android and IOS.

    I tried removing the styles for the back button. Now I can see the previous page after clicking the back button twice, but now I can't click on the views to go to another view.
    Any way to resolve this?
    Thanks

  6. #6
    Sencha User
    Join Date
    Jun 2014
    Posts
    2
    Vote Rating
    0
    rfc2822 is on a distinguished road

      0  

    Default Workaround

    Workaround


    I have encountered this bug, too.

    My workaround is to set the onBackButtonTap method to
    Code:
    single: true
    and add it again after the animation has finished (in config/control/nav/pop).

    Code:
    var nav = Ext.define('MyApp.controller.Navigation', {
        extend: 'Ext.app.Controller',
        
        config: {
            refs: {
                nav: 'navigation'
            },
            control: {
                nav: {
                    pop: 'addBackButtonListener',
                    initialize: 'initialize'
                }
            }
        },
    
        initialize: function() {
            // HACK: override back button listener
            this.getNav().getNavigationBar().removeListener('back', nav.onBackButtonTap, nav);
            this.addBackButtonListener();
        },
        
        addBackButtonListener: function() {
            var nav = this.getNav();
            var navBar = nav.getNavigationBar();
            navBar.on({
                back: nav.onBackButtonTap,
                scope: nav,
                single: true
            });
        }
    });