Changes between Initial Version and Version 1 of Ticket #16674


Ignore:
Timestamp:
Feb 5, 2013, 1:28:48 AM (9 years ago)
Author:
bill
Comment:

In general what you described in the ticket description works. But you need to either set a height on the outer ContentPane, or set doLayout=false.

Content will not be hidden because dijit/layout/ContentPane has a default setting of overflow: auto from dijit.css:

.dijitContentPane {
   display: block;
   overflow: auto;
}

Now, your fiddle is actually a ContentPane that contains a TitlePane, not another ContentPane. So I think there's an issue with TitlePane.resize() not doing the right thing, i.e. nothing.

Changing the ticket summary appropriately. But regardless, what you want is to set doLayout=false on the ContentPane.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #16674

    • Property Priority changed from undecided to low
    • Property Summary changed from Single child of ContentPane doesn't resize as content added to TitlePane: resize() should do nothing
  • Ticket #16674 – Description

    initial v1  
    1 If a ContentPane has a single child ContentPane, the child gets a fixed height (style="height: whateverpx"). As content is added to that child (whether by addChild() or directly manipulating the dom), the fixed height stays, and the new content is hidden if it exceeds the container. Here's a jsfiddle:
     1If a !ContentPane has a single child !ContentPane, the child gets a fixed height (style="height: whateverpx"). As content is added to that child (whether by addChild() or directly manipulating the dom), the fixed height stays, and the new content is hidden if it exceeds the container. Here's a jsfiddle:
    22
    33http://jsfiddle.net/ZGd3K/4/
    44
    5 As you click the Add button, it adds content to the child ContentPane, which is hidden as it exceeds the height that was explicitly added by the parent ContentPane.
     5As you click the Add button, it adds content to the child !ContentPane, which is hidden as it exceeds the height that was explicitly added by the parent !ContentPane.
    66
    77I think the problem is in dijit/Layout/_ContentPaneResizeMixin._layoutChildren():