Looks like we cannot reproduce this. Please provide another test case to reproduce this issue.
  1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    46
    Vote Rating
    3
    svendahlstrand is on a distinguished road

      0  

    Default Exception is thrown when carousel is destroyed

    Exception is thrown when carousel is destroyed


    REQUIRED INFORMATION
    Project Type:
    • Touch 2.2.0
    Description:
    • When destroying a carousel an exception will be thrown if the carousel contains items that has been flipped.
    Steps to reproduce the problem:
    • Create a carousel with a couple of panels with card layouts.
    • Flip one of the cards.
    • Destroy the carousel.
    The result that was expected:
    • The carousel should be destroyed and no exception should be thrown.
    The result that occurs instead:
    • Exception is thrown: Uncaught TypeError: Cannot call method 'getParent' of undefined Flip.js:38.
    HELPFUL INFORMATION
    Screenshot, Project, or Video:
    • See the app.js example below. Use it in a newly generated 2.2.0 app to trigger the exception.
    Code:
    // DO NOT DELETE - this directive is required for Sencha Cmd packages to work.
    //@require @packageOverrides
    
    
    //<debug>
    Ext.Loader.setPath({
        'Ext': 'touch/src',
        'test': 'app'
    });
    //</debug>
    
    
    Ext.application({
        name: 'test',
    
    
        requires: [
            'Ext.MessageBox',
            'Ext.Carousel'
        ],
    
    
        views: [
            'Main'
        ],
    
    
        icon: {
            '57': 'resources/icons/Icon.png',
            '72': 'resources/icons/Icon~ipad.png',
            '114': 'resources/icons/Icon@2x.png',
            '144': 'resources/icons/Icon~ipad@2x.png'
        },
    
    
        isIconPrecomposed: true,
    
    
        startupImage: {
            '320x460': 'resources/startup/320x460.jpg',
            '640x920': 'resources/startup/640x920.png',
            '768x1004': 'resources/startup/768x1004.png',
            '748x1024': 'resources/startup/748x1024.png',
            '1536x2008': 'resources/startup/1536x2008.png',
            '1496x2048': 'resources/startup/1496x2048.png'
        },
    
    
        launch: function() {
            var cards = Ext.create('Ext.Carousel', {
                fullscreen : true,
                items: [
                {
                  layout: 'card',
                  items: [
                    { html : 'Front' },
                    { html : 'Back' }
                  ]
                },
                {
                  layout: 'card',
                  items: [
                    { html : 'Front' },
                    { html : 'Back' }
                  ]
                }
                ]
            });
    
    
            // If you comment away this line the exception won't be thrown.
            cards.getAt(1).animateActiveItem(1, { type: 'flip' });
    
    
            Ext.defer(function () {
              cards.destroy();
            }, 3000);
        },
    
    
        onUpdated: function() {
            Ext.Msg.confirm(
                "Application Update",
                "This application has just successfully been updated to the latest version. Reload now?",
                function(buttonId) {
                    if (buttonId === 'yes') {
                        window.location.reload();
                    }
                }
            );
        }
    });

  2. #2
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    8,191
    Vote Rating
    63
    aconran is just really nice aconran is just really nice aconran is just really nice aconran is just really nice aconran is just really nice

      0  

    Default


    Moved to Sencha Touch bugs forum.
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  3. #3
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,714
    Vote Rating
    438
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    This has already been fixed for the next (ST 2.2.1) release.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    http://www.JSONPLint.com - Source to lint your JSONP!

    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 almost in print!

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