1. #21
    Ext JS Premium Member
    Join Date
    Sep 2011
    Posts
    62
    Vote Rating
    0
    ExtJSNinjas is on a distinguished road

      0  

    Default


    Quote Originally Posted by dongryphon View Post
    Is this a class derived from Ext.layout.container.Container ? Or just a configuration of border layouts?
    Sorry, I'm 100% really clear on which class you are referring to.

    We have an Ext.panel.Panel inside of our Viewport (fit layout), which is a border layout (created initially with configs). The border layout within the main center panel contains mostly other types of panels (grid, tree, etc) that are dynamically added to the main center panel (configs) depending on the context. On the west is a tree used for navigation, and to the north are various controls and toolbars.

    Please let me know what I am missing. Thanks for your insight.

  2. #22
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Quote Originally Posted by ExtJSNinjas View Post
    Sorry, I'm 100% really clear on which class you are referring to.

    We have an Ext.panel.Panel inside of our Viewport (fit layout), which is a border layout (created initially with configs). The border layout within the main center panel contains mostly other types of panels (grid, tree, etc) that are dynamically added to the main center panel (configs) depending on the context. On the west is a tree used for navigation, and to the north are various controls and toolbars.

    Please let me know what I am missing. Thanks for your insight.
    I was curious if you have implemented your own layout class. That is, a class derived from Ext.layout.container.Container. Things are much more exciting moving to 4.1 if you have implemented your own layout classes.

    It sounds like you are just configuring standard layouts and using then in dynamic ways (not just setup a instantiation time).
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  3. #23
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Quote Originally Posted by ExtJSNinjas View Post
    Sorry, I'm 100% really clear on which class you are referring to.

    We have an Ext.panel.Panel inside of our Viewport (fit layout), which is a border layout (created initially with configs). The border layout within the main center panel contains mostly other types of panels (grid, tree, etc) that are dynamically added to the main center panel (configs) depending on the context. On the west is a tree used for navigation, and to the north are various controls and toolbars.

    Please let me know what I am missing. Thanks for your insight.
    I was curious if you have implemented your own layout class. That is, a class derived from Ext.layout.container.Container. Things are much more exciting moving to 4.1 if you have implemented your own layout classes.

    It sounds like you are just configuring standard layouts and using then in dynamic ways (not just setup a instantiation time).
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  4. #24
    Ext JS Premium Member
    Join Date
    Sep 2011
    Posts
    62
    Vote Rating
    0
    ExtJSNinjas is on a distinguished road

      0  

    Default


    Quote Originally Posted by dongryphon View Post
    I was curious if you have implemented your own layout class. That is, a class derived from Ext.layout.container.Container. Things are much more exciting moving to 4.1 if you have implemented your own layout classes.

    It sounds like you are just configuring standard layouts and using then in dynamic ways (not just setup a instantiation time).
    Is there an example with custom layout classes deriving from Ext.layout.container.Container that we can look at? Thanks.
    Last edited by ExtJSNinjas; 28 Dec 2011 at 8:35 AM. Reason: typo

  5. #25
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Quote Originally Posted by ExtJSNinjas View Post
    Is there an example with custom layout classes deriving from Ext.layout.container.Container that we can look at? Thanks.
    There is the "center" layout in the layout browser, but it is pretty unique to being a form of "fit" layout.

    The best thing would be to look at a core layout that is close to your needs and model yours after that.

    I would be curious to know what you need in a custom layout, if you could share. This is a complex thing to build (always was really and is more so in 4.1) so I would not encourage folks to build their own layouts unless they need to do so. And if there are common needs out there, I would like to see if we can extend the set of core layouts to better address them.

    Not to say writing custom layouts is a no-no or bad practice. Rather it is a challenge to write one that is efficient (as we have witnessed first-hand internally during 4.1 development).
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  6. #26
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Quote Originally Posted by ExtJSNinjas View Post
    Here's the console output from one screen (content is dynamically added):

    [E] ----------------- FAILURE -----------------
    ++k132502842261740474<card> - size: calculated/calculated
    ++sel-1117<dock> - size: calculated/calculated
    ++sel-1117<fit> - size: calculated/calculated
    ++frm-1118<dock> - size: calculated/calculated
    ++frm-1118<anchor> - size: calculated/calculated
    --kv-1124<fit> - size: calculated/calculated
    triggeredBy: count=2
    kv-1124-bodyEl.height () dirty: false, setBy: ?
    kv-1124-bodyEl.width (1269) dirty: false, setBy: kv-1124<fieldcontainer>
    --kvitem-1125<dock> - size: calculated/calculated
    triggeredBy: count=2
    kvitem-1125.height () dirty: false, setBy: ?
    kvitem-1125.width (1269) dirty: false, setBy: kv-1124<fit>
    ++kvitem-1125<fit> - size: calculated/calculated
    ++kds-1120<field> - size: calculated/shrinkWrap
    ++kstr-1122<textfield> - size: calculated/shrinkWrap
    ++kstr-1123<textfield> - size: calculated/shrinkWrap
    ++kv-1124<fieldcontainer> - size: calculated/calculated
    The root cause goes like this:

    kv-1125's dock layout never got a height ("height ()" should be "height (100)" or something).

    Because kv-1124's fit layout never gave it one ("calculated/calculated" means the fit layout will be calculating width/height).

    Because kv-1124's fit layout never got its container's height ("bodyEl.height ()").

    Probably because kv-1124's component layout (fieldcontainer) never gave it one.

    Perhaps you could focus on that small part and make an example out of it?

    btw... there might be some over-nesting of containers as well. This would be a performance issue only (not a huge one probably). The card layout has a panel (sel-1117) w/fit layout and just a single panel (frm-1118). Perhaps frm-1118 could be moved up and sel-1117 removed. Sometimes these are architecturally induced, but just wanted to mention it as a potential optimization.
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  7. #27
    Ext JS Premium Member
    Join Date
    Sep 2011
    Posts
    62
    Vote Rating
    0
    ExtJSNinjas is on a distinguished road

      0  

    Default


    Quote Originally Posted by dongryphon View Post
    The root cause goes like this:

    kv-1125's dock layout never got a height ("height ()" should be "height (100)" or something).

    Because kv-1124's fit layout never gave it one ("calculated/calculated" means the fit layout will be calculating width/height).

    Because kv-1124's fit layout never got its container's height ("bodyEl.height ()").

    Probably because kv-1124's component layout (fieldcontainer) never gave it one.

    Perhaps you could focus on that small part and make an example out of it?

    btw... there might be some over-nesting of containers as well. This would be a performance issue only (not a huge one probably). The card layout has a panel (sel-1117) w/fit layout and just a single panel (frm-1118). Perhaps frm-1118 could be moved up and sel-1117 removed. Sometimes these are architecturally induced, but just wanted to mention it as a potential optimization.
    Commenting out one of the kv "layout: 'fit'" settings seems to have stopped those errors. Thanks for the input.

    Now I am seeing "Layout left connected: container-1106<anchor>" errors. Does this mean that there is a container with an "anchor" layout set, or with the "anchor" property set? I don't get a tree with this error message.

    We do have to keep the card layout, as it is used with dynamic controls in other contexts. Thanks, though.

  8. #28
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Quote Originally Posted by ExtJSNinjas View Post
    Commenting out one of the kv "layout: 'fit'" settings seems to have stopped those errors. Thanks for the input.
    Just curious which setting. If it is working for you, obviously your time will probably be focused elsewhere now... which is fine

    Quote Originally Posted by ExtJSNinjas View Post
    Now I am seeing "Layout left connected: container-1106<anchor>" errors. Does this mean that there is a container with an "anchor" layout set, or with the "anchor" property set? I don't get a tree with this error message.
    This message indicates that some layout didn't get a per-run property cleared. Not sure how that happens yet, but its effects are probably minor. We need to clear this up though since it will probably have some bad effects. Holding on to memory it does not need at a minimum.

    Quote Originally Posted by ExtJSNinjas View Post
    We do have to keep the card layout, as it is used with dynamic controls in other contexts. Thanks, though.
    I was actually looking at the two panels inside the card. The immediate child of the card (sel-1117) has a single child (frm-1118) that is 'fit' so you may not need sel-1117 and might be able to make frm-1118 a child of the card. Again, lots of "maybe" in that.
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  9. #29
    Ext JS Premium Member
    Join Date
    Sep 2011
    Posts
    62
    Vote Rating
    0
    ExtJSNinjas is on a distinguished road

      0  

    Default


    I have a question that is related to the duplicate id messages that I was seeing earlier in this thread. When a control (and thus sub-controls) is destroyed, is it no longer unregistered from either Ext.AbstractManager or Ext.ComponentManager? This seems to be the case now.

  10. #30
    Ext JS Premium Member tvanzoelen's Avatar
    Join Date
    Apr 2008
    Location
    Groningen - Netherlands
    Posts
    1,120
    Vote Rating
    30
    tvanzoelen has a spectacular aura about tvanzoelen has a spectacular aura about tvanzoelen has a spectacular aura about

      0  

    Default


    That [E] Layout left connected: form-1025<anchor> I have multiple times.
    In my case it is in the form.