1. #1
    Sencha User
    Join Date
    Mar 2010
    Posts
    249
    Answers
    2
    Vote Rating
    1
    Ex_Soft is an unknown quantity at this point

      0  

    Default Answered: MVC && File Structure

    Answered: MVC && File Structure


    app.js
    Code:
    Ext.Loader.setConfig({
        enabled: true,
        disableCaching: false
    });
    
    Ext.application({
        name: "M3",
    
        appFolder: "app",
    
        autoCreateViewport: true
    });
    app/view/Viewport.js
    Code:
    Ext.define("M3.view.Viewport" , {
        extend: "Ext.container.Viewport",
        requires: ["maintbar"],
        layout: "fit",
        items: [
            {
                tbar: { xtype: "maintbar" } // Ext.create("M3.view.MainTbar")
            }
        ]
    });
    app/view/MainTbar.js
    Code:
    Ext.define("M3.view.MainTbar" ,{
        extend: "Ext.toolbar.Toolbar",
        alias : "widget.maintbar",
        items: [
            {
                xtype: "button",
                text: "DoIt!"
            }
        ]
    });
    Quote Originally Posted by console
    "NetworkError: 404 Not Found - http://localhost/maintbar.js"
    app/view/Viewport.js is successfully loaded when I use Ext.create("M3.view.MainTbar") instead of xtype. Why http://localhost/maintbar.js instead of http://localhost/app/view/maintbar.js?

  2. I think the 'requires' class name should be fully qualified:

    Code:
    Ext.define("M3.view.Viewport" , {
        extend: "Ext.container.Viewport",
        requires: ['M3.view.MainTbar'],
        layout: "fit",
        items: [
            {
                tbar: { xtype: "maintbar" } // Ext.create("M3.view.MainTbar")
            }
        ]
    });

  3. #2
    Sencha - Community Support Team friend's Avatar
    Join Date
    Apr 2011
    Posts
    895
    Answers
    106
    Vote Rating
    27
    friend has a spectacular aura about friend has a spectacular aura about

      0  

    Default


    I think the 'requires' class name should be fully qualified:

    Code:
    Ext.define("M3.view.Viewport" , {
        extend: "Ext.container.Viewport",
        requires: ['M3.view.MainTbar'],
        layout: "fit",
        items: [
            {
                tbar: { xtype: "maintbar" } // Ext.create("M3.view.MainTbar")
            }
        ]
    });

Thread Participants: 1

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..." hd porno faketaxi