Package org.adempiere.webui.editor
Class WButtonEditor
- java.lang.Object
-
- org.adempiere.webui.editor.WEditor
-
- org.adempiere.webui.editor.WButtonEditor
-
- All Implemented Interfaces:
PropertyChangeListener
,EventListener
,IProcessButton
,org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>
public class WButtonEditor extends WEditor implements IProcessButton
This class is based on org.compiere.grid.ed.VButton written by Jorg Janke.- Author:
- Jorg Janke Modifications - UI Compatibility, ashley
-
-
Field Summary
Fields Modifier and Type Field Description static String
EDITOR_ATTRIBUTE
-
Fields inherited from class org.adempiere.webui.editor.WEditor
component, gridField, gridTab, INIT_EDIT_EVENT, label, listeners, mandatory, MAX_DISPLAY_LENGTH, popupMenu, readOnly, tableEditor
-
-
Constructor Summary
Constructors Constructor Description WButtonEditor(GridField gridField)
WButtonEditor(GridField gridField, boolean tableEditor, IEditorConfiguration editorConfiguration)
WButtonEditor(GridField gridField, int rowIndex)
WButtonEditor(GridField gridField, int rowIndex, boolean tableEditor, IEditorConfiguration editorConfiguration)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addActionListener(ActionListener actionListener)
IADTabpanel
getADTabpanel()
Button
getComponent()
String
getDisplay()
String[]
getEvents()
GridField
getGridField()
int
getProcess_ID()
Get AD_Process_IDObject
getValue()
HashMap<String,String>
getValues()
boolean
isMandatory()
boolean
isReadWrite()
boolean
isSearchable()
void
onEvent(org.zkoss.zk.ui.event.Event event)
boolean
removeActionListener(ActionListener actionListener)
void
setADTabpanel(IADTabpanel adTabpanel)
void
setMandatory(boolean mandatory)
Set whether the editor represents a mandatory field.void
setReadWrite(boolean readWrite)
void
setValue(Object value)
-
Methods inherited from class org.adempiere.webui.editor.WEditor
addChangeLogMenu, addTextEditorMenu, addValueChangeListener, applyFieldStyles, applyLabelStyles, buildStyle, cleanColumnName, dynamicDisplay, dynamicDisplay, fillHorizontal, fireValueChange, focusNext, getColumnName, getDescription, getDisplayComponent, getDisplayTextForGridView, getLabel, getPopupMenu, getStyleEvaluatee, isComponentOfEditor, isMandatoryStyle, isNullOrEmpty, isProcessParameter, isShowPreference, isVisible, isZoomable, propertyChange, removeValuechangeListener, setBackground, setBackground, setChangeEventWhenEditing, setColumnName, setComponent, setFieldStyle, setGridTab, setLabelStyle, setProcessParameter, setTableEditor, setVisible, showMenu, toString, updateLabelStyle, updateStyle, updateStyle
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.adempiere.webui.editor.IProcessButton
getColumnName, getDescription
-
-
-
-
Field Detail
-
EDITOR_ATTRIBUTE
public static final String EDITOR_ATTRIBUTE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
WButtonEditor
public WButtonEditor(GridField gridField)
- Parameters:
gridField
-
-
WButtonEditor
public WButtonEditor(GridField gridField, int rowIndex)
- Parameters:
gridField
-rowIndex
-
-
WButtonEditor
public WButtonEditor(GridField gridField, boolean tableEditor, IEditorConfiguration editorConfiguration)
- Parameters:
gridField
-tableEditor
-editorConfiguration
-
-
WButtonEditor
public WButtonEditor(GridField gridField, int rowIndex, boolean tableEditor, IEditorConfiguration editorConfiguration)
- Parameters:
gridField
-rowIndex
-tableEditor
-editorConfiguration
-
-
-
Method Detail
-
getProcess_ID
public int getProcess_ID()
Description copied from interface:IProcessButton
Get AD_Process_ID- Specified by:
getProcess_ID
in interfaceIProcessButton
- Returns:
- AD_Process_ID or 0
-
getGridField
public GridField getGridField()
- Overrides:
getGridField
in classWEditor
- Returns:
- grid field for this editor ( can be null )
-
getDisplay
public String getDisplay()
- Specified by:
getDisplay
in interfaceIProcessButton
- Specified by:
getDisplay
in classWEditor
- Returns:
- display text
-
isMandatory
public boolean isMandatory()
- Overrides:
isMandatory
in classWEditor
- Returns:
- boolean
-
setMandatory
public void setMandatory(boolean mandatory)
Description copied from class:WEditor
Set whether the editor represents a mandatory field.- Overrides:
setMandatory
in classWEditor
- Parameters:
mandatory
- whether the field is mandatory
-
getComponent
public Button getComponent()
- Overrides:
getComponent
in classWEditor
- Returns:
- Component
-
isReadWrite
public boolean isReadWrite()
- Specified by:
isReadWrite
in classWEditor
- Returns:
- editable
-
setReadWrite
public void setReadWrite(boolean readWrite)
- Specified by:
setReadWrite
in classWEditor
-
addActionListener
public void addActionListener(ActionListener actionListener)
-
removeActionListener
public boolean removeActionListener(ActionListener actionListener)
-
onEvent
public void onEvent(org.zkoss.zk.ui.event.Event event) throws Exception
- Specified by:
onEvent
in interfaceorg.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>
- Throws:
Exception
-
setADTabpanel
public void setADTabpanel(IADTabpanel adTabpanel)
-
getADTabpanel
public IADTabpanel getADTabpanel()
- Specified by:
getADTabpanel
in interfaceIProcessButton
-
isSearchable
public boolean isSearchable()
- Overrides:
isSearchable
in classWEditor
- Returns:
- true if usable in find window, false otherwise
-
-