Success! Looks like we've fixed this one. According to our records the fix was applied for EXTGWT-3058 in 3.1 beta.
  1. #1
    Sencha Premium Member
    Join Date
    May 2013
    Posts
    21
    Vote Rating
    0
    ejohannes is on a distinguished road

      0  

    Default Does BorderLayoutContainer require collapsible areas to contain ContentPanel

    Does BorderLayoutContainer require collapsible areas to contain ContentPanel


    I have been adding GXT components to my existing GWT application.
    When I tried to use BorderLayoutContainer to create hidable areas, I ran into the exception:
    Caused by: java.lang.ClassCastException: com.sencha.gxt.widget.core.client.container.BorderLayoutContainer cannot be cast to com.sencha.gxt.widget.core.client.ContentPanel
    When I looked at the code, it appears that BorderLayoutContainer requires the top level component of the area to be a ContentPanel. Once I put ContentPanel into my areas, things work.

    I do see ContentPanel being used in the BorderLayoutContainer.

    But I see nothing in any documentation I have found that says that the North/South/East/West areas must contain a ContentPanel for them to have the ability to be hidden.

    My questions: Is it correct that ContentPanel is required? If so, why is this not explicitly stated in the javadoc and other documentation (examples are nice but they are not a substitute for documentation particularly when something is required)?

  2. #2
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,734
    Vote Rating
    90
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    In short, yes, it is required - without a header, there is no room to render the collapse icon.

    You are correct that we should have better javadocs in this area. It might also be reasonable to emit a warning in the case where a layout data is passed in that uses a feature that is incompatible with the child widget being used. I've moved this thread to the bugs section and filed it internally to make sure that we follow up on this.

  3. #3
    Sencha - GXT Dev Team
    Join Date
    Jan 2012
    Location
    Arlington, WA
    Posts
    484
    Vote Rating
    15
    branflake2267 will become famous soon enough

      0  

    Default


    Just an update, this issue has been fixed and is merged into the 3.1 beta branch.

Thread Participants: 2