|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.opencms.workplace.tools.A_CmsHtmlIconButton
public abstract class A_CmsHtmlIconButton
Default skeleton for an html icon button.
Field Summary | |
---|---|
static CmsMessageContainer |
EMPTY_MESSAGE
Constant for an empty message. |
protected java.lang.String |
m_id
unique id. |
Constructor Summary | |
---|---|
A_CmsHtmlIconButton(java.lang.String id)
Default Constructor. |
|
A_CmsHtmlIconButton(java.lang.String id,
CmsMessageContainer name,
CmsMessageContainer helpText,
java.lang.String iconPath,
boolean enabled)
Full Constructor. |
Method Summary | |
---|---|
static java.lang.String |
defaultButtonHtml(CmsHtmlIconButtonStyleEnum style,
java.lang.String id,
java.lang.String name,
java.lang.String helpText,
boolean enabled,
java.lang.String iconPath,
java.lang.String confirmationMessage,
java.lang.String onClick)
Generates a default html code for icon buttons. |
static java.lang.String |
defaultButtonHtml(CmsHtmlIconButtonStyleEnum style,
java.lang.String id,
java.lang.String helpId,
java.lang.String name,
java.lang.String helpText,
boolean enabled,
java.lang.String iconPath,
java.lang.String confirmationMessage,
java.lang.String onClick,
boolean singleHelp,
java.lang.String rightHtml)
Generates a default html code where several buttons can have the same help text. |
static java.lang.String |
defaultHelpHtml(java.lang.String helpId,
java.lang.String helpText)
Generates html for the helptext when having one helptext for several buttons. |
CmsMessageContainer |
getHelpText()
Returns the help text. |
java.lang.String |
getIconPath()
Returns the path to the icon. |
java.lang.String |
getId()
Returns the id of the html component. |
CmsMessageContainer |
getName()
Returns the display name. |
boolean |
isEnabled()
Returns if enabled or disabled. |
boolean |
isVisible()
Returns if visible or not. |
void |
setEnabled(boolean enabled)
Sets if enabled or disabled. |
void |
setHelpText(CmsMessageContainer helpText)
Sets the help Text. |
void |
setIconPath(java.lang.String iconPath)
Sets the icon Path. |
void |
setName(CmsMessageContainer name)
Sets the name. |
void |
setVisible(boolean visible)
Sets if visible or not. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.opencms.workplace.tools.I_CmsHtmlIconButton |
---|
buttonHtml |
Field Detail |
---|
public static final CmsMessageContainer EMPTY_MESSAGE
protected java.lang.String m_id
Constructor Detail |
---|
public A_CmsHtmlIconButton(java.lang.String id)
id
- the idpublic A_CmsHtmlIconButton(java.lang.String id, CmsMessageContainer name, CmsMessageContainer helpText, java.lang.String iconPath, boolean enabled)
id
- the idname
- the namehelpText
- the help texticonPath
- the path to the iconenabled
- if enabled or notMethod Detail |
---|
public static java.lang.String defaultButtonHtml(CmsHtmlIconButtonStyleEnum style, java.lang.String id, java.lang.String name, java.lang.String helpText, boolean enabled, java.lang.String iconPath, java.lang.String confirmationMessage, java.lang.String onClick)
style
- the style of the buttonid
- the idname
- the namehelpText
- the help textenabled
- if enabled or noticonPath
- the path to the iconconfirmationMessage
- the optional confirmation messageonClick
- the js code to execute
public static java.lang.String defaultButtonHtml(CmsHtmlIconButtonStyleEnum style, java.lang.String id, java.lang.String helpId, java.lang.String name, java.lang.String helpText, boolean enabled, java.lang.String iconPath, java.lang.String confirmationMessage, java.lang.String onClick, boolean singleHelp, java.lang.String rightHtml)
style
- the style of the buttonid
- the idhelpId
- the id of the helptext div tagname
- the name, if empty only the icon is displayedhelpText
- the help text, if empty no mouse events are generatedenabled
- if enabled or not, if not set be sure to take an according helptexticonPath
- the path to the icon, if empty only the name is displayedconfirmationMessage
- the confirmation messageonClick
- the js code to execute, if empty no link is generatedsingleHelp
- if set, no helptext is written, you have to use the defaultHelpHtml() method laterrightHtml
- optional html code that should come direct after the button
public static java.lang.String defaultHelpHtml(java.lang.String helpId, java.lang.String helpText)
helpId
- the id of the help texthelpText
- the help text
public CmsMessageContainer getHelpText()
I_CmsHtmlIconButton
getHelpText
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.getHelpText()
public java.lang.String getIconPath()
I_CmsHtmlIconButton
getIconPath
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.getIconPath()
public java.lang.String getId()
I_CmsHtmlIconButton
getId
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.getId()
public CmsMessageContainer getName()
I_CmsHtmlIconButton
getName
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.getName()
public boolean isEnabled()
I_CmsHtmlIconButton
isEnabled
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.isEnabled()
public boolean isVisible()
I_CmsHtmlIconButton
isVisible
in interface I_CmsHtmlIconButton
I_CmsHtmlIconButton.isVisible()
public void setEnabled(boolean enabled)
I_CmsHtmlIconButton
setEnabled
in interface I_CmsHtmlIconButton
enabled
- if enabled or disabledI_CmsHtmlIconButton.setEnabled(boolean)
public void setHelpText(CmsMessageContainer helpText)
I_CmsHtmlIconButton
setHelpText
in interface I_CmsHtmlIconButton
helpText
- the help Text to setI_CmsHtmlIconButton.setHelpText(org.opencms.i18n.CmsMessageContainer)
public void setIconPath(java.lang.String iconPath)
I_CmsHtmlIconButton
setIconPath
in interface I_CmsHtmlIconButton
iconPath
- the icon Path to setI_CmsHtmlIconButton.setIconPath(java.lang.String)
public void setName(CmsMessageContainer name)
I_CmsHtmlIconButton
setName
in interface I_CmsHtmlIconButton
name
- the name to setI_CmsHtmlIconButton.setName(org.opencms.i18n.CmsMessageContainer)
public void setVisible(boolean visible)
I_CmsHtmlIconButton
setVisible
in interface I_CmsHtmlIconButton
visible
- if visible or notI_CmsHtmlIconButton.setVisible(boolean)
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |