A widget that consists of a header and a content panel that discloses the
content when a user clicks on the header.
CSS Style Rules
.gwt-DisclosurePanel { the panel's primary style }
.gwt-DisclosurePanel-open { dependent style set when panel is open }
.gwt-DisclosurePanel-closed { dependent style set when panel is closed }
.header { the header section }
.content { the content section }
The header and content sections can be easily selected using css with a child
selector: .gwt-DisclosurePanel-open .header { ... }
Constructor Summary
public
DisclosurePanel() Creates an empty DisclosurePanel that is initially closed.
public
DisclosurePanel(DisclosurePanelImages images, String headerText, boolean isOpen) Creates a DisclosurePanel with the specified header text, an initial
open/close state and a bundle of images to be used in the default header
widget.
public
DisclosurePanel(String headerText) Creates a DisclosurePanel that will be initially closed using the specified
text in the header.
public
DisclosurePanel(String headerText, boolean isOpen) Creates a DisclosurePanel with the specified header text and an initial
open/close state.
public
DisclosurePanel(Widget header) Creates a DisclosurePanel that will be initially closed using a widget as
the header.
public
DisclosurePanel(Widget header, boolean isOpen) Creates a DisclosurePanel using a widget as the header and an initial
open/close state.
Creates a DisclosurePanel with the specified header text, an initial
open/close state and a bundle of images to be used in the default header
widget.
Parameters: images - a bundle that provides disclosure panel specific images Parameters: headerText - the text to be displayed in the header Parameters: isOpen - the initial open/close state of the content panel
Creates a DisclosurePanel that will be initially closed using the specified
text in the header.
Parameters: headerText - the text to be displayed in the header.
DisclosurePanel
public DisclosurePanel(String headerText, boolean isOpen)(Code)
Creates a DisclosurePanel with the specified header text and an initial
open/close state.
Parameters: headerText - the text to be displayed in the header Parameters: isOpen - the initial open/close state of the content panel
Creates a DisclosurePanel that will be initially closed using a widget as
the header.
Parameters: header - the widget to be used as a header
DisclosurePanel
public DisclosurePanel(Widget header, boolean isOpen)(Code)
Creates a DisclosurePanel using a widget as the header and an initial
open/close state.
Parameters: header - the widget to be used as a header Parameters: isOpen - the initial open/close state of the content panel
Gets a
HasText instance to provide access to the headers's text, if
the header widget does provide such access.
a reference to the header widget if it implements HasText,null otherwise
Removes an event handler from the panel.
Parameters: handler - the handler to be removed
setContent
final public void setContent(Widget content)(Code)
Sets the content widget which can be opened and closed by this panel. If
there is a preexisting content widget, it will be detached.
Parameters: content - the widget to be used as the content panel
setHeader
final public void setHeader(Widget headerWidget)(Code)
Sets the widget used as the header for the panel.
Parameters: headerWidget - the widget to be used as the header