|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.click.control.AbstractControl org.apache.click.control.Field org.apache.click.control.Button org.apache.click.control.Submit org.apache.click.control.ImageSubmit
public class ImageSubmit
Provides an ImageSubmit control: <input type='image' src='edit.gif'>.
Submit
,
Button
,
Serialized FormField Summary | |
---|---|
protected String |
src
The image path src attribute. |
protected int |
x
The image pixel x coordinate clicked on by the user, the default value is -1. |
protected int |
y
The image pixel y coordinate clicked on by the user, the default value is -1. |
Fields inherited from class org.apache.click.control.Submit |
---|
clicked |
Fields inherited from class org.apache.click.control.Field |
---|
disabled, error, focus, form, help, label, labelStyle, labelStyleClass, parentStyleClassHint, parentStyleHint, readonly, required, tabindex, title, trim, validate, value |
Fields inherited from class org.apache.click.control.AbstractControl |
---|
actionListener, attributes, behaviors, headElements, listener, listenerMethod, messages, name, parent, styles |
Fields inherited from interface org.apache.click.Control |
---|
CONTROL_MESSAGES |
Constructor Summary | |
---|---|
ImageSubmit()
Create an ImageSubmit button with no name defined. |
|
ImageSubmit(String name)
Create a ImageSubmit button with the given name. |
|
ImageSubmit(String name,
String src)
Create a ImageSubmit button with the given name and image src path. |
|
ImageSubmit(String name,
String src,
Object listener,
String method)
Create a ImageSubmit button with the given name, image src path, listener object and listener method. |
Method Summary | |
---|---|
void |
bindRequestValue()
Bind the request submission, setting the field Submit.clicked ,
x and y if defined in the request. |
String |
getSrc()
Return the image src path attribute. |
String |
getType()
Return the input type: 'image'. |
int |
getX()
Return the image x pixel coordinate clicked on by the user. |
int |
getY()
Return the image y pixel coordinate clicked on by the user. |
boolean |
onProcess()
Process the submit event and return true to continue event processing. |
void |
render(HtmlStringBuffer buffer)
Render the HTML representation of the ImageButton. |
void |
setSrc(String src)
Set the image src path attribute. |
Methods inherited from class org.apache.click.control.Submit |
---|
getCancelJavaScriptValidation, isClicked, setCancelJavaScriptValidation |
Methods inherited from class org.apache.click.control.Button |
---|
getControlSizeEst, getOnClick, getTag, setOnClick |
Methods inherited from class org.apache.click.control.Field |
---|
getError, getErrorLabel, getFocus, getFocusJavaScript, getForm, getHelp, getId, getLabel, getLabelStyle, getLabelStyleClass, getParentStyleClassHint, getParentStyleHint, getRequestValue, getState, getTabIndex, getTextAlign, getTitle, getValidate, getValidationJavaScript, getValue, getValueObject, getWidth, isDisabled, isHidden, isReadonly, isRequired, isTrim, isValid, removeState, renderTagBegin, restoreState, saveState, setDisabled, setError, setErrorMessage, setErrorMessage, setFocus, setForm, setHelp, setLabel, setLabelStyle, setLabelStyleClass, setListener, setParent, setParentStyleClassHint, setParentStyleHint, setReadonly, setRequired, setState, setTabIndex, setTextAlign, setTitle, setTrim, setValidate, setValue, setValueObject, setWidth, validate |
Methods inherited from class org.apache.click.control.AbstractControl |
---|
addBehavior, addStyleClass, appendAttributes, dispatchActionEvent, getActionListener, getAttribute, getAttributes, getBehaviors, getContext, getHeadElements, getHtmlImports, getMessage, getMessage, getMessages, getName, getPage, getParent, getStyle, getStyles, hasAttribute, hasAttributes, hasBehaviors, hasStyles, isAjaxTarget, onDeploy, onDestroy, onInit, onRender, removeBehavior, removeStyleClass, renderTagEnd, setActionListener, setAttribute, setId, setName, setStyle, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected String src
protected int x
protected int y
Constructor Detail |
---|
public ImageSubmit(String name)
name
- the button namepublic ImageSubmit(String name, String src)
name
- the button namesrc
- the image src path attributepublic ImageSubmit(String name, String src, Object listener, String method)
name
- the button namesrc
- the image src path attributelistener
- the listener target objectmethod
- the listener method to callpublic ImageSubmit()
Method Detail |
---|
public String getType()
getType
in class Submit
public String getSrc()
public void setSrc(String src)
src
- the image src path attributepublic int getX()
public int getY()
public void bindRequestValue()
Submit.clicked
,
x
and y
if defined in the request.
bindRequestValue
in class Submit
public boolean onProcess()
onProcess
in interface Control
onProcess
in class Submit
Submit.onProcess()
public void render(HtmlStringBuffer buffer)
render
in interface Control
render
in class Button
buffer
- the specified buffer to render the control's output toAbstractControl.toString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |