Java Doc for CycleButton.java in  » Ajax » gwtext-2.01 » com » gwtext » client » widgets » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Ajax » gwtext 2.01 » com.gwtext.client.widgets 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


com.gwtext.client.widgets.Component
   com.gwtext.client.widgets.Button
      com.gwtext.client.widgets.SplitButton
         com.gwtext.client.widgets.CycleButton

CycleButton
public class CycleButton extends SplitButton (Code)
A specialized SplitButton that contains a menu of CheckItem elements. The button automatically cycles through each menu item on click, raising the button's change event (or calling the button's changeHandler function, if supplied) for the active menu item. Clicking on the arrow section of the button displays the dropdown menu just like a normal SplitButton.

 
 

CycleButtonConfig config = new CycleButtonConfig(); config.setShowText(true); config.setPrependText("View as "); config.addItem(new CheckItem("text only", true)); config.addItem(new CheckItem("HTML", false)); config.setChangeHandler(new CycleButtonHandler() { public void execute(CycleButton self, CheckItem item) { MessageBox.alert("Change View", item.getText()); } });

CycleButton button = new CycleButton(config);




Constructor Summary
public  CycleButton()
     Create a new CycleButton.
public  CycleButton(CycleButtonListener listener)
     Create a new CycleButton.
public  CycleButton(CycleButtonListener listener, String icon)
     Create a new CycleButton.
public  CycleButton(JavaScriptObject jsObj)
    

Method Summary
public  voidaddItem(CheckItem item)
     Add a CheckItem config object to be used when creating the button's menu items.
native public  voidaddListener(CycleButtonListener listener)
     Add a CycleButton Listener.
native protected  JavaScriptObjectcreate(JavaScriptObject config)
    
native public  CheckItemgetActiveItem()
     Gets the currently active menu item.
public  StringgetPrependText()
    
public  StringgetShowText()
    
public  StringgetXType()
    
native public  voidsetActiveItem(CheckItem item)
     Sets the button's active menu item.
native public  voidsetActiveItem(CheckItem item, boolean supressEvent)
     Sets the button's active menu item.
public  voidsetPrependText(String prependText)
     A static string to prepend before the active item's text when displayed as the button's text (only applies when showText = true, defaults to '').
public  voidsetShowText(boolean showText)
     True to display the active item's text as the button text (defaults to false).
native public  voidtoggleSelected()
     This is normally called internally on button click, but can be called externally to advance the button's active item programmatically to the next one in the menu.


Constructor Detail
CycleButton
public CycleButton()(Code)
Create a new CycleButton.



CycleButton
public CycleButton(CycleButtonListener listener)(Code)
Create a new CycleButton.
Parameters:
  listener - the button listener



CycleButton
public CycleButton(CycleButtonListener listener, String icon)(Code)
Create a new CycleButton.
Parameters:
  listener - the button listener
Parameters:
  icon - icon image path



CycleButton
public CycleButton(JavaScriptObject jsObj)(Code)




Method Detail
addItem
public void addItem(CheckItem item) throws IllegalStateException(Code)
Add a CheckItem config object to be used when creating the button's menu items.
Parameters:
  item - check item config
throws:
  IllegalStateException - this property cannot be changed after the Component has been rendered



addListener
native public void addListener(CycleButtonListener listener)(Code)
Add a CycleButton Listener.
Parameters:
  listener - the listener



create
native protected JavaScriptObject create(JavaScriptObject config)(Code)



getActiveItem
native public CheckItem getActiveItem()(Code)
Gets the currently active menu item. the active menu item



getPrependText
public String getPrependText()(Code)
the prepend text



getShowText
public String getShowText()(Code)
the show text



getXType
public String getXType()(Code)



setActiveItem
native public void setActiveItem(CheckItem item)(Code)
Sets the button's active menu item.
Parameters:
  item - the item to activate



setActiveItem
native public void setActiveItem(CheckItem item, boolean supressEvent)(Code)
Sets the button's active menu item.
Parameters:
  item - the item to activate
Parameters:
  supressEvent - true to prevent the button's change event from firing (defaults to false)



setPrependText
public void setPrependText(String prependText)(Code)
A static string to prepend before the active item's text when displayed as the button's text (only applies when showText = true, defaults to '').
Parameters:
  prependText - the prepend text



setShowText
public void setShowText(boolean showText)(Code)
True to display the active item's text as the button text (defaults to false).
Parameters:
  showText - true to display item's text



toggleSelected
native public void toggleSelected()(Code)
This is normally called internally on button click, but can be called externally to advance the button's active item programmatically to the next one in the menu. If the current item is the last one in the menu the active item will be set to the first item in the menu.



Methods inherited from com.gwtext.client.widgets.SplitButton
native public void addListener(SplitButtonListener listener)(Code)(Java Doc)
native protected JavaScriptObject create(JavaScriptObject config)(Code)(Java Doc)
public String getArrowTooltip()(Code)(Java Doc)
public String getXType()(Code)(Java Doc)
public void setArrowTooltip(String arrowTooltip) throws IllegalStateException(Code)(Java Doc)

Methods inherited from com.gwtext.client.widgets.Button
native public void addListener(ButtonListener listener)(Code)(Java Doc)
native protected JavaScriptObject create(JavaScriptObject config)(Code)(Java Doc)
public void focus()(Code)(Java Doc)
public boolean getBindToForm()(Code)(Java Doc)
native public Element getButtonElement()(Code)(Java Doc)
public String getClickEvent()(Code)(Java Doc)
protected JavaScriptObject getConfigPrototype()(Code)(Java Doc)
public boolean getHandleMouseEvents()(Code)(Java Doc)
public String getIcon()(Code)(Java Doc)
public String getIconCls()(Code)(Java Doc)
public String getMenuAlign()(Code)(Java Doc)
public int getMinWidth()(Code)(Java Doc)
public int getTabIndex()(Code)(Java Doc)
public String getText()(Code)(Java Doc)
public String getToggleGroup()(Code)(Java Doc)
public String getTooltip()(Code)(Java Doc)
public String getTooltipType()(Code)(Java Doc)
public String getType()(Code)(Java Doc)
public String getXType()(Code)(Java Doc)
native public boolean hasVisibleMenu()(Code)(Java Doc)
native public void hideMenu()(Code)(Java Doc)
public boolean isDisabled()(Code)(Java Doc)
public boolean isEnableToggle()(Code)(Java Doc)
public boolean isPressed()(Code)(Java Doc)
native public boolean isRepeat()(Code)(Java Doc)
public void setClickEvent(String clickEvent) throws IllegalStateException(Code)(Java Doc)
public void setEnableToggle(boolean enableToggle)(Code)(Java Doc)
public void setFormBind(boolean bindToForm)(Code)(Java Doc)
public void setHandleMouseEvents(boolean handleMouseEvents) throws IllegalStateException(Code)(Java Doc)
public void setHidden(boolean hidden)(Code)(Java Doc)
public void setIcon(String icon)(Code)(Java Doc)
public void setIconCls(String iconCls)(Code)(Java Doc)
public void setMenu(Menu menu) throws IllegalStateException(Code)(Java Doc)
public void setMenuAlign(String anchorPosition)(Code)(Java Doc)
public void setMinWidth(int minWidth) throws IllegalStateException(Code)(Java Doc)
public void setPressed(boolean pressed)(Code)(Java Doc)
public void setRepeat(boolean repeat)(Code)(Java Doc)
public void setRepeat(ClickRepeaterConfig qconfig)(Code)(Java Doc)
public void setTabIndex(int tabIndex) throws IllegalStateException(Code)(Java Doc)
public void setTemplate(Template template)(Code)(Java Doc)
public void setText(String text)(Code)(Java Doc)
public void setToggleGroup(String toggleGroup) throws IllegalStateException(Code)(Java Doc)
public void setTooltip(String tooltip)(Code)(Java Doc)
public void setTooltip(String title, String text)(Code)(Java Doc)
public void setTooltip(QuickTipsConfig qtipConfig) throws IllegalStateException(Code)(Java Doc)
public void setTooltipType(boolean quickTip) throws IllegalStateException(Code)(Java Doc)
public void setType(String type) throws IllegalStateException(Code)(Java Doc)
native public void showMenu()(Code)(Java Doc)
public void toggle()(Code)(Java Doc)
public void toggle(boolean state)(Code)(Java Doc)

Fields inherited from com.gwtext.client.widgets.Component
protected JavaScriptObject config(Code)(Java Doc)
protected String id(Code)(Java Doc)

Methods inherited from com.gwtext.client.widgets.Component
public void addClass(String cls)(Code)(Java Doc)
native public void addClassCreated(String cls)(Code)(Java Doc)
native public void addEvent(String events)(Code)(Java Doc)
public void addEvents(String[] events)(Code)(Java Doc)
protected void addListener(String event, JavaScriptObject fn)(Code)(Java Doc)
native public void addListener(String event, Function funtion)(Code)(Java Doc)
native protected void addListener(ComponentListener listener)(Code)(Java Doc)
protected void afterRender()(Code)(Java Doc)
protected void beforeDestroy()(Code)(Java Doc)
protected void check() throws IllegalStateException(Code)(Java Doc)
public Component cloneComponent()(Code)(Java Doc)
public Component cloneComponent(Component overrides)(Code)(Java Doc)
native protected JavaScriptObject cloneConfig(JavaScriptObject config)(Code)(Java Doc)
abstract protected JavaScriptObject create(JavaScriptObject config)(Code)(Java Doc)
native public void destroy()(Code)(Java Doc)
public void disable()(Code)(Java Doc)
public void enable()(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void error(String message) throws IllegalStateException(Code)(Java Doc)
public void focus()(Code)(Java Doc)
native public void focus(boolean selectText)(Code)(Java Doc)
native public void focus(boolean selectText, int delay)(Code)(Java Doc)
public Element getApplyTo()(Code)(Java Doc)
protected String getAttribute(String attribute)(Code)(Java Doc)
protected boolean getAttributeAsBoolean(String attribute)(Code)(Java Doc)
protected float getAttributeAsFloat(String attribute)(Code)(Java Doc)
protected int getAttributeAsInt(String attribute)(Code)(Java Doc)
protected JavaScriptObject getAttributeAsJavaScriptObject(String attribute)(Code)(Java Doc)
public boolean getAutoShow()(Code)(Java Doc)
public String getCls()(Code)(Java Doc)
native protected static JavaScriptObject getComponentJS(String id)(Code)(Java Doc)
public JavaScriptObject getConfig()(Code)(Java Doc)
abstract protected JavaScriptObject getConfigPrototype()(Code)(Java Doc)
public String getCtCls()(Code)(Java Doc)
public String getDisabledClass()(Code)(Java Doc)
native public ExtElement getEl()(Code)(Java Doc)
native protected Element getElement(JavaScriptObject jsObj)(Code)(Java Doc)
public Element getElement()(Code)(Java Doc)
public String getHideMode()(Code)(Java Doc)
public boolean getHideParent()(Code)(Java Doc)
public String getId()(Code)(Java Doc)
native public String getItemId()(Code)(Java Doc)
public JavaScriptObject getJsObj()(Code)(Java Doc)
public int getOffsetHeight()(Code)(Java Doc)
public int getOffsetWidth()(Code)(Java Doc)
public JavaScriptObject getOrCreateJsObj()(Code)(Java Doc)
native public Container getOwnerContainer()(Code)(Java Doc)
public Element getRenderTo()(Code)(Java Doc)
public String[] getStateEvents()(Code)(Java Doc)
public String getStateId()(Code)(Java Doc)
public String getStyle()(Code)(Java Doc)
protected Element getStyleElement()(Code)(Java Doc)
public String getTitle()(Code)(Java Doc)
public String getXType()(Code)(Java Doc)
native public String getXTypes()(Code)(Java Doc)
public int hashCode()(Code)(Java Doc)
public void hide()(Code)(Java Doc)
protected void initComponent()(Code)(Java Doc)
public boolean isCreated()(Code)(Java Doc)
public boolean isDisabled()(Code)(Java Doc)
public boolean isHidden()(Code)(Java Doc)
native public boolean isRendered()(Code)(Java Doc)
native public boolean isVisible()(Code)(Java Doc)
native public boolean isXType(String xtype)(Code)(Java Doc)
native public boolean isXType(String xtype, boolean shallow)(Code)(Java Doc)
protected void onDestroy()(Code)(Java Doc)
native public void removeClass(String cls)(Code)(Java Doc)
native public void render(String id)(Code)(Java Doc)
native public void render(String id, String position)(Code)(Java Doc)
native public void render(String id, int position)(Code)(Java Doc)
native public void render(Element element)(Code)(Java Doc)
native public void render(Element element, String position)(Code)(Java Doc)
native public void render(Element element, int position)(Code)(Java Doc)
public void setApplyTo(Element element) throws IllegalStateException(Code)(Java Doc)
protected void setAttribute(String attribute, String value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, String value, boolean allowPostCreate, boolean allowPostRendered)(Code)(Java Doc)
protected void setAttribute(String attribute, int[] value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, int[] value, boolean allowPostCreate, boolean allowPostRender)(Code)(Java Doc)
protected void setAttribute(String attribute, long value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, double value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, int value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, int value, boolean allowPostCreate, boolean allowPostRender)(Code)(Java Doc)
protected void setAttribute(String attribute, Date value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, JavaScriptObject value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, JavaScriptObject value, boolean allowPostCreate, boolean allowPostRender)(Code)(Java Doc)
protected void setAttribute(String attribute, String[] value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, String[] value, boolean allowPostCreate, boolean allowPostRender)(Code)(Java Doc)
protected void setAttribute(String attribute, boolean value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, boolean value, boolean allowPostCreate, boolean allowPostRendered)(Code)(Java Doc)
protected void setAttribute(String attribute, Element value, boolean allowPostCreate)(Code)(Java Doc)
protected void setAttribute(String attribute, Element value, boolean allowPostCreate, boolean allowPostRendered)(Code)(Java Doc)
public void setAutoEl(String autoEl)(Code)(Java Doc)
public void setAutoShow(boolean autoShow) throws IllegalStateException(Code)(Java Doc)
public void setCls(String cls)(Code)(Java Doc)
public void setCtCls(String ctCls) throws IllegalStateException(Code)(Java Doc)
public void setDisabled(boolean disabled)(Code)(Java Doc)
public void setDisabledClass(String disabledClass)(Code)(Java Doc)
public void setEl(Element el) throws IllegalStateException(Code)(Java Doc)
public void setEl(String elementID) throws IllegalStateException(Code)(Java Doc)
public void setHeight(String height)(Code)(Java Doc)
public void setHideMode(String hideMode)(Code)(Java Doc)
public void setHideParent(boolean hideParent) throws IllegalStateException(Code)(Java Doc)
final public void setId(String id) throws IllegalStateException(Code)(Java Doc)
public void setRenderTo(Element elem) throws IllegalStateException(Code)(Java Doc)
public void setStateEvents(String[] stateEvents) throws IllegalStateException(Code)(Java Doc)
public void setStateId(String stateId) throws IllegalStateException(Code)(Java Doc)
public void setStyle(String style) throws IllegalStateException(Code)(Java Doc)
public void setTitle(String title)(Code)(Java Doc)
public void setVisible(boolean visible)(Code)(Java Doc)
public void setWidth(String width)(Code)(Java Doc)
public void show()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.