| |
|
| net.mygwt.ui.client.widget.Component net.mygwt.ui.client.widget.Container net.mygwt.ui.client.widget.ScrollContainer net.mygwt.ui.client.widget.WidgetContainer net.mygwt.ui.client.widget.ContentPanel
ContentPanel | public class ContentPanel extends WidgetContainer implements SourcesMouseEvents(Code) | | A Container with an optional header that can be expanded and
collapsed.
- Styles:
- COLLAPSE, HEADER, CLOSE
- Events:
- BeforeExpand : (widget)
Fires before the panel is expanded. Listeners can set the
doit field to false to cancel the expand.
- Expand : (widget)
Fires after the panel is expanded
- BeforeCollapse : (widget)
Fires before the panel is collpased. Listeners can set the
doit field false to cancel the collapse.
- Collapse : (widget)
Fires after the panel is collapsed.
- BeforeClose : (widget)
Fires before a content panel is closed. Listeners can set the
doit field to false to cancel the operation.
- Close : (widget)
Fires after a content panel is closed.
- CSS:
- .my-cpanel ( the panel panel)
- .my-cpanel .my-cpanel-hdr-text (the header text)
- .my-cpanel-small ( smaller header section )
- .my-cpanel-small .my-cpanel-hdr-text (the header text)
|
Constructor Summary | |
public | ContentPanel() Creates a new content panel with a header. | public | ContentPanel(int style) Creates a new content panel. | public | ContentPanel(int style, String baseStyle) Creates a new content panel. |
body | protected SimplePanel body(Code) | | |
ContentPanel | public ContentPanel()(Code) | | Creates a new content panel with a header.
|
ContentPanel | public ContentPanel(int style)(Code) | | Creates a new content panel.
Parameters: style - the style information |
ContentPanel | public ContentPanel(int style, String baseStyle)(Code) | | Creates a new content panel.
Parameters: style - the style information Parameters: baseStyle - an alternate base style. |
addMouseListener | public void addMouseListener(MouseListener listener)(Code) | | Adds a listener interface to receive mouse events.
Parameters: listener - the listener interface to add |
afterCollapse | protected void afterCollapse()(Code) | | |
afterExpand | protected void afterExpand()(Code) | | |
afterRender | protected void afterRender()(Code) | | |
doAttachChildren | protected void doAttachChildren()(Code) | | |
doDetachChildren | protected void doDetachChildren()(Code) | | |
getAnimateCollapse | public boolean getAnimateCollapse()(Code) | | Returns true if animations are enabled.
the animation state |
getCollapse | public boolean getCollapse()(Code) | | Returns true if the panel can be collapsed.
the collapse state |
getFrame | public boolean getFrame()(Code) | | true if the panel is framed. |
getHeader | public Item getHeader()(Code) | | Returns the panel's header widget.
the header |
getLayoutTarget | public Element getLayoutTarget()(Code) | | |
getText | public String getText()(Code) | | Returns the panel's title text.
the text |
getTitleCollapse | public boolean getTitleCollapse()(Code) | | Returns true if clicks on the header will expand and
collapse the panel.
the title collpase state |
getToolBar | public ToolBar getToolBar()(Code) | | Returns the panel's tool bar.
the tool bar or null |
isExpanded | public boolean isExpanded()(Code) | | Returns true if the panel is expanded.
the expand state |
onCollapse | protected void onCollapse()(Code) | | |
onExpand | protected void onExpand()(Code) | | |
onRender | protected void onRender()(Code) | | |
onResize | protected void onResize(int width, int height)(Code) | | |
removeMouseListener | public void removeMouseListener(MouseListener listener)(Code) | | Removes a previously added listener interface.
Parameters: listener - the listener interface to remove |
setAnimateCollapse | public void setAnimateCollapse(boolean animateCollapse)(Code) | | Sets the animation state. When true , the expanding and
collpasing of the panel will be animated. Default value is
true .
Parameters: animateCollapse - true if enabled |
setCollapse | public void setCollapse(boolean collapse)(Code) | | Sets whether the panel can be collapsed. Default value is true .
Has no effect if called after the panel is rendered.
Parameters: collapse - true to enable collapsing |
setExpanded | public void setExpanded(boolean expanded)(Code) | | Sets the panel's expand state.
Parameters: expanded - true true to expand |
setFrame | public void setFrame(boolean frame)(Code) | | Sets whether the panel is framed. Default value is false .
Has no effect if called after the panel is rendered.
Parameters: frame - the frame state |
setIconStyle | public void setIconStyle(String style)(Code) | | Sets the panel's icon style.
Parameters: style - the icon style |
setPadding | public void setPadding(int padding)(Code) | | Sets the padding of the content element.
Parameters: padding - the new padding |
setStyle | public void setStyle(int style)(Code) | | Sets the panel's style. Has no effect if called after the panel is
rendered.
Parameters: style - the style |
setText | public void setText(String text)(Code) | | Sets the header's text. Does nothing if the header is not visible.
Parameters: text - the new header text |
setTitleCollapse | public void setTitleCollapse(boolean enabled)(Code) | | Sets the title collapse state. When true , the panel will be
expanded and collapsed when clicking on the header. Defualt value is
false .
Parameters: enabled - true to enable title collapsing |
setToolBar | public void setToolBar(ToolBar toolBar)(Code) | | Sets the panel's tool bar.
Parameters: toolBar - the toolbar |
Methods inherited from net.mygwt.ui.client.widget.Component | public void addListener(int eventType, Listener listener)(Code)(Java Doc) public void addStyleName(String style)(Code)(Java Doc) public void addWidgetListener(WidgetListener listener)(Code)(Java Doc) protected void afterRender()(Code)(Java Doc) protected Component blur()(Code)(Java Doc) public void disable()(Code)(Java Doc) protected void disableContextMenu(boolean disable)(Code)(Java Doc) public void disableTextSelection(boolean disable)(Code)(Java Doc) public void dispose()(Code)(Java Doc) public void enable()(Code)(Java Doc) public void enableEvents(boolean enable)(Code)(Java Doc) public boolean fireEvent(int type)(Code)(Java Doc) public boolean fireEvent(int type, BaseEvent be)(Code)(Java Doc) public boolean fireEvent(int eventType, Widget widget, Widget item)(Code)(Java Doc) public boolean fireEvent(int eventType, Widget widget, Widget item, int index)(Code)(Java Doc) public Component focus()(Code)(Java Doc) public Rectangle getBounds()(Code)(Java Doc) public Rectangle getBounds(boolean content)(Code)(Java Doc) protected Menu getContextMenu()(Code)(Java Doc) public Object getData()(Code)(Java Doc) public Object getData(String key)(Code)(Java Doc) public String getDisabledStyle()(Code)(Java Doc) public Element getElement()(Code)(Java Doc) protected Element getFocusElement()(Code)(Java Doc) public int getHeight()(Code)(Java Doc) public int getHeight(boolean content)(Code)(Java Doc) public String getId()(Code)(Java Doc) public int getStyle()(Code)(Java Doc) public ToolTip getToolTip()(Code)(Java Doc) public int getWidth()(Code)(Java Doc) public int getWidth(boolean content)(Code)(Java Doc) public void hide()(Code)(Java Doc) public boolean isDisposed()(Code)(Java Doc) public boolean isEnabled()(Code)(Java Doc) public boolean isRendered()(Code)(Java Doc) public boolean isVisible()(Code)(Java Doc) protected void onAttach()(Code)(Java Doc) public void onBaseEvent(BaseEvent be)(Code)(Java Doc) public void onBrowserEvent(Event event)(Code)(Java Doc) protected void onDestroy()(Code)(Java Doc) protected void onDetach()(Code)(Java Doc) protected void onDisable()(Code)(Java Doc) protected void onEnable()(Code)(Java Doc) protected void onHide()(Code)(Java Doc) protected void onHideContextMenu()(Code)(Java Doc) protected void onLoad()(Code)(Java Doc) protected void onRender()(Code)(Java Doc) protected void onResize(int width, int height)(Code)(Java Doc) protected void onRightClick(BaseEvent be)(Code)(Java Doc) protected void onShow()(Code)(Java Doc) protected void onShowContextMenu(int x, int y)(Code)(Java Doc) public void recalculate()(Code)(Java Doc) public void removeAllListeners()(Code)(Java Doc) public void removeFromParent()(Code)(Java Doc) public void removeListener(int eventType, Listener listener)(Code)(Java Doc) public void removeStyleName(String style)(Code)(Java Doc) public void removeWidgetListener(WidgetListener listener)(Code)(Java Doc) protected void render()(Code)(Java Doc) public void setBorders(boolean show)(Code)(Java Doc) public void setBounds(int x, int y, int width, int height)(Code)(Java Doc) public void setBounds(Rectangle rect)(Code)(Java Doc) protected void setContextMenu(Menu menu)(Code)(Java Doc) public void setData(Object data)(Code)(Java Doc) public void setData(String key, Object data)(Code)(Java Doc) public void setDisabledStyle(String style)(Code)(Java Doc) public void setElement(Element elem)(Code)(Java Doc) public void setEnabled(boolean enabled)(Code)(Java Doc) public void setHeight(int height)(Code)(Java Doc) public void setHeight(String height)(Code)(Java Doc) public void setId(String id)(Code)(Java Doc) public void setIntStyleAttribute(String attr, int value)(Code)(Java Doc) public void setPagePosition(int x, int y)(Code)(Java Doc) public void setPixelSize(int width, int height)(Code)(Java Doc) public void setSize(int width, int height)(Code)(Java Doc) public void setSize(String width, String height)(Code)(Java Doc) public void setStyleAttribute(String attr, String value)(Code)(Java Doc) public void setStyleName(String style)(Code)(Java Doc) public void setTitle(String title)(Code)(Java Doc) public void setToolTip(String text)(Code)(Java Doc) public void setToolTip(String title, String text)(Code)(Java Doc) public void setVisible(boolean visible)(Code)(Java Doc) public void setWidth(int width)(Code)(Java Doc) public void setWidth(String width)(Code)(Java Doc) public void show()(Code)(Java Doc) public void unhook(int type, EventListener listener)(Code)(Java Doc)
|
|
|
|