1. #1
    Sencha User
    Join Date
    Sep 2009
    Posts
    81
    Vote Rating
    0
    alupuli is on a distinguished road

      0  

    Default custom xtype

    custom xtype


    is it possible to add a custom xtype.
    any samples/ or previous post?

  2. #2
    Sencha User laurentParis's Avatar
    Join Date
    Aug 2010
    Location
    paris
    Posts
    246
    Vote Rating
    2
    laurentParis is on a distinguished road

      0  

    Default


    Code:
    var MyPanel = Ext.extend(Ext.Panel,  {
     title: 'My Panel'
    });
    Ext.reg('mypanel', MyPanel);
    after you can use mypanel on xtype
    Code:
    ...
    items: [{
      xtype: 'mypanel'
    }]...

  3. #3
    Sencha User
    Join Date
    Sep 2009
    Posts
    81
    Vote Rating
    0
    alupuli is on a distinguished road

      0  

    Default


    thank you

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,224
    Vote Rating
    859
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    There are two really... one for a component (extension or new) and one for a plug-in.

    Ext.reg is for a component
    Ext.preg is for a plug-in

    The about example will work with both just change to preg if a plug-in.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    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 in print!

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

Similar Threads

  1. ERROR in Getting Value From Custom Xtype
    By utpal_brsh in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 2 Jul 2010, 11:49 PM
  2. Portal + Custom Grids by XType
    By KimSchneider in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 9 Feb 2010, 1:43 AM
  3. difference between xtype and custom class... why??
    By tarini in forum Ext 2.x: Help & Discussion
    Replies: 7
    Last Post: 21 Jan 2009, 5:13 AM
  4. FormPanel - custom xtype ???
    By archmisha in forum Ext 2.x: Help & Discussion
    Replies: 9
    Last Post: 20 Oct 2008, 9:18 AM
  5. xtype:'textarea', to xtype:'htmleditor' problem
    By putty in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 2 Jul 2008, 11:11 PM

Thread Participants: 2