0

I've got an MVC application that works fine on IE and Chrome but fails to call Ext application launch on Firefox. The application is declared as:

Ext.application({
        name: 'uoozo.piko',

    appFolder: '/piko/desktop',
    controllers: [
        'AppController',
        'ImageController',
        'HistogramController',
        'EffectsController',
        'EffectEditController',
        'SocialController',
        'PicturesController'
    ],

    launch: function()
    {
        Ext.create('Ext.container.Viewport', {
            layout: 'fit',

            items: {
                xtype: "AppView"
            }
        });
    }
});

When I try loading this application in Firefox, my controllers and their associated views load but launch is not called. If I comment out the controllers then the application launches fine. I don't understand what the problem is? Also, why does this inconsistency exist between firefox and other browsers?

Thanks

jenson-button-event
  • 18,101
  • 11
  • 89
  • 155
GlGuru
  • 756
  • 2
  • 10
  • 21
  • Did you check the firebug console? – Todd Smith Jul 03 '13 at 23:21
  • Yes. The firebug console doesn't show anything useful. No errors, just a bunch of extjs warnings that always show up whether the app works or not. – GlGuru Jul 04 '13 at 06:00
  • is that everything, i mean where's your requires for AppView? presumably your warnings are because you are not including the files you need. might be worth posting some, u never know it might shed some light. id have to check but does a view port auto render itself to ext.getBody(). another possibility is caching of your js files... – jenson-button-event Jul 04 '13 at 11:55
  • The requires for views are done as part of the controller in the views config part of the controller. As I mentioned previously, I have debugged and the Javascript files for the views and controllers are getting loaded and evaluated. My launch function isn't getting called at all so don't think where the viewport gets rendered is strictly valid right now. What do you mean by javascript caching? – GlGuru Jul 04 '13 at 14:48
  • Figured this one out. Variable scopes behave differently in firefox. I was getting an exception in one of the controllers really early in application start-up because one of the variables being accessed in that function was coming up as undefined and causing an exception. The big problem is that Firefox shows all errors and warnings in the same color and spews out so many warnings with ExtJS that the real problem got lost in the sea of yellow. – GlGuru Jul 05 '13 at 12:52

1 Answers1

0

Figured this one out. Variable scopes behave differently in firefox. I was getting an exception in one of the controllers really early in application start-up because one of the variables being accessed in that function was coming up as undefined and causing an exception. The big problem is that Firefox shows all errors and warnings in the same color and spews out so many warnings with ExtJS that the real problem got lost in the sea of yellow.

GlGuru
  • 756
  • 2
  • 10
  • 21