Package org.adempiere.webui.factory
Class ButtonFactory
- java.lang.Object
-
- org.adempiere.webui.factory.ButtonFactory
-
public class ButtonFactory extends Object
Factory class to create button with consistent look and feel- Author:
- hengsin
-
-
Constructor Summary
Constructors Constructor Description ButtonFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Button
createButton(String label, String image, String tooltiptext)
static Button
createNamedButton(String name)
Create named button with default stylestatic Button
createNamedButton(String name, boolean withText, boolean withImage)
static boolean
isWithImage()
static boolean
isWithText()
-
-
-
Method Detail
-
isWithText
public static final boolean isWithText()
- Returns:
- true if button should have text label
-
isWithImage
public static final boolean isWithImage()
- Returns:
- true if button should include an image icon
-
createNamedButton
public static Button createNamedButton(String name)
Create named button with default style- Parameters:
name
-- Returns:
- new button instance
-
createNamedButton
public static Button createNamedButton(String name, boolean withText, boolean withImage)
- Parameters:
name
- button name. If withText is true, the name will be used to lookup the button label from ad_messagewithText
- text buttonwithImage
- image button- Returns:
- new button instance
-
-