Results 1 to 3 of 3

Thread: Makes Ext components re-read its initialConfig?

  1. #1
    Sencha Premium Member ethraza's Avatar
    Join Date
    Jun 2007
    Location
    Brazil
    Posts
    378

    Question Makes Ext components re-read its initialConfig?

    If I have something like:

    localization_options = 'Options';

    {
    ...
    id: 'myform',
    ...
    xtype: 'fieldset',
    title: localization_options,
    items: [{
    ...
    }
    localization_options = 'Opes';

    Ext.getCmp('myform').reSet(config); <- Magic method goes here!!!

    And wold be better if the magic method cold be called after the component has been rendered.

    There is a way to make the components re-read their options or a better solution to make things dynamic?

    Thanks

    ps. I wold love JS to have the options to do like in PHP... (title: @localization_options)
    LAMPE (Linux / Apache / MySQL / PHP / ExtJs)

  2. #2
    Sencha User VinylFox's Avatar
    Join Date
    Mar 2007
    Location
    Baltimore, MD
    Posts
    1,501

    Default

    After the component has been created, you will need to use the appropriate setter/getter to make these types of changes.

    ie:
    PHP Code:
    this.setTitle('bla'
    re-reading the config and updating the Component is not a realistic option.

  3. #3
    Sencha Premium Member steffenk's Avatar
    Join Date
    Jul 2007
    Location
    Haan, Germany
    Posts
    2,675

    Default

    A component is built with an initial config. Then you have an object where you can't change private properties any longer.
    It's the same in php where you set internal values in constructor, but you can't call the constructor 2nd time with your instance.
    vg Steffen
    --------------------------------------
    Release Manager of TYPO3 4.5

Similar Threads

  1. initialConfig in 1.0.2.12
    By MrRoyce in forum Ext Designer: Help & Discussion
    Replies: 7
    Last Post: 2 Sep 2010, 7:59 AM
  2. Replies: 7
    Last Post: 1 Jun 2009, 8:57 AM
  3. Ext.NET - makes sense?
    By Kigorw in forum Community Discussion
    Replies: 9
    Last Post: 17 Dec 2008, 6:27 AM
  4. [2.0.2] BorderLayout initialConfig collapsible bug
    By crenix in forum Ext 2.x: Bugs
    Replies: 0
    Last Post: 14 Apr 2008, 11:39 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •