1. #1
    Sencha User
    Join Date
    Aug 2009
    Posts
    7
    Vote Rating
    2
    brianpolk is on a distinguished road

      0  

    Question Changing Generated Class Names from My...

    Changing Generated Class Names from My...


    How do I set the class names of the classes that are created in Designer? i do not like the components/classes all having generated names starting with "My". I have MyGrid, MyGrid1, MyGrid2, MyPanel, etc. I've search the properties for each component, and right-clicked the classname everywhere I see it, nowhere can I find how to give the class a meaningful name.

  2. #2
    Sencha Premium Member
    Join Date
    Jan 2009
    Posts
    336
    Vote Rating
    101
    firefoxSafari is a glorious beacon of light firefoxSafari is a glorious beacon of light firefoxSafari is a glorious beacon of light firefoxSafari is a glorious beacon of light firefoxSafari is a glorious beacon of light firefoxSafari is a glorious beacon of light

      0  

    Default


    For the top-level components, I think you want to look at the jsClass attribute. Setting this should change the name in the Components tree and change the name in the generated .js files.

    The jsClass attribute is only available on the top-level components now. This is usually fine in the exported code because the other components are declared as items of the top one using xtype and so they don't explicitly extend a class. The name these things show up as in the Components tree in the Designer seems to be sensitive to the type of control. For example, the Form Fields take on the name attribute while grid panels that are children of a top-level container show as the title attribute.

  3. #3
    Sencha User abe.elias's Avatar
    Join Date
    Aug 2008
    Location
    Palo Alto, CA
    Posts
    407
    Vote Rating
    22
    abe.elias will become famous soon enough abe.elias will become famous soon enough

      0  

    Default


    @brianpolk This screencast might help http://www.extjs.com/blog/2010/04/22...he-screencast/