Threaded View

    You found a bug! We've classified it as EXTJS-7665 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha Premium Member
    Join Date
    Aug 2007
    Location
    The Netherlands
    Posts
    51
    Vote Rating
    3
    extjs@kingsquare.nl is on a distinguished road

      0  

    Exclamation Ext.app.Controller.views are not loaded by Application

    Ext.app.Controller.views are not loaded by Application


    REQUIRED INFORMATION


    Ext version tested:
    • Ext 4.0.7, 4.1.2 and 4.1.3

    Browser versions tested against:
    • Chrome
    • IE
    • FF

    DOCTYPE tested against:
    • HTML5

    Description:
    • When defining 'views' on a controller, and that controller would be used in an Application, one would expect it would by loaded BEFORE the Application.launch() callback. As stated in several comments in the manual, this isn't the case.

    Steps to reproduce the problem:
    Load up an Application with a Controller with a View, where the view is declared in the views-property on the controller. Note how the view is not available after launch so JavaScript breaks.

    The result that was expected:
    A working application

    The result that occurs instead:
    A JavaScript error because the view-class isn't loaded

    Test Case:
    app/app.js
    Code:
    Ext.application({
        controllers: [
    		'MyController'
    	],
    
        name: 'myApp',
    	launch: function () {
    		//this is undefined, but should be the view
    		console.log(myApp.view.MyView);
    	}
    })
    controller/MyController.js
    Code:
    Ext.define('myApp.controller.MyController', {
    	extend: 'Ext.app.Controller',
    	views: ['MyView']
    });
    view/MyView.js
    Code:
    Ext.define('myApp.view.MyView', {
    	extend: 'Ext.panel.Panel'
    });

    HELPFUL INFORMATION

    At this moment, one can work around this issue by adding the views to the 'requires'-property on the controller, but this is annoying.

    Earlier versions of ExtJs (e.g. 4.0.2a) didn't have this issue)
    Last edited by extjs@kingsquare.nl; 31 Oct 2012 at 1:03 AM. Reason: typo

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..."