|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectTextBoxBase
com.vaadin.client.ui.VTextField
public class VTextField
This class represents a basic text input field with one row.
| Field Summary | |
|---|---|
static java.lang.String |
CLASSNAME
The input node CSS classname. |
static java.lang.String |
CLASSNAME_FOCUS
This CSS classname is added to the input node on hover. |
ApplicationConnection |
client
For internal use only. |
boolean |
listenTextChangeEvents
For internal use only. |
java.lang.String |
paintableId
For internal use only. |
static int |
TEXTCHANGE_EVENTS
For internal use only. |
java.lang.String |
textChangeEventMode
For internal use only. |
int |
textChangeEventTimeout
|
java.lang.String |
valueBeforeEdit
For internal use only. |
| Constructor Summary | |
|---|---|
|
VTextField()
|
protected |
VTextField(Element node)
|
| Method Summary | |
|---|---|
void |
attachCutEventListener(Element el)
For internal use only. |
protected void |
detachCutEventListener(Element el)
|
static void |
flushChangesFromFocusedTextField()
|
int |
getMaxLength()
|
protected boolean |
isWordwrap()
|
protected void |
onAttach()
|
void |
onBlur(BlurEvent event)
|
void |
onBrowserEvent(Event event)
|
void |
onChange(ChangeEvent event)
|
protected void |
onCut()
|
protected void |
onDetach()
|
void |
onFocus(FocusEvent event)
|
void |
onKeyDown(KeyDownEvent event)
|
void |
setColumns(int columns)
|
void |
setImmediate(boolean immediate)
|
void |
setInputPrompt(java.lang.String inputPrompt)
|
void |
setMaxLength(int newMaxLength)
For internal use only. |
protected void |
setMaxLengthToElement(int newMaxLength)
|
void |
setReadOnly(boolean readOnly)
|
protected boolean |
updateCursorPosition()
Updates the cursor position variable if it has changed since the last update. |
void |
updateFieldContent(java.lang.String text)
For internal use only. |
protected void |
updateMaxLength(int maxLength)
This method is responsible for updating the DOM or otherwise ensuring that the given max length is enforced. |
void |
valueChange(boolean blurred)
Called when the field value might have changed and/or the field was blurred. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String CLASSNAME
public static final java.lang.String CLASSNAME_FOCUS
public java.lang.String paintableId
public ApplicationConnection client
public java.lang.String valueBeforeEdit
public static final int TEXTCHANGE_EVENTS
TODO When GWT adds ONCUT, add it there and remove workaround. See http://code.google.com/p/google-web-toolkit/issues/detail?id=4030
Also note that the cut/paste are not totally crossbrowsers compatible. E.g. in Opera mac works via context menu, but on via File->Paste/Cut. Opera might need the polling method for 100% working textchanceevents. Eager polling for a change is bit dum and heavy operation, so I guess we should first try to survive without.
public boolean listenTextChangeEvents
public java.lang.String textChangeEventMode
public int textChangeEventTimeout
| Constructor Detail |
|---|
public VTextField()
protected VTextField(Element node)
| Method Detail |
|---|
public void onBrowserEvent(Event event)
public void setReadOnly(boolean readOnly)
public void updateFieldContent(java.lang.String text)
protected void onCut()
public void attachCutEventListener(Element el)
protected void detachCutEventListener(Element el)
protected void onDetach()
protected void onAttach()
public void setMaxLength(int newMaxLength)
protected void updateMaxLength(int maxLength)
maxLength - The new max lengthprotected void setMaxLengthToElement(int newMaxLength)
public int getMaxLength()
public void onChange(ChangeEvent event)
public void valueChange(boolean blurred)
blurred - true if the field was blurredprotected boolean updateCursorPosition()
public static void flushChangesFromFocusedTextField()
public void onFocus(FocusEvent event)
public void onBlur(BlurEvent event)
public void setColumns(int columns)
public void onKeyDown(KeyDownEvent event)
public void setImmediate(boolean immediate)
public void setInputPrompt(java.lang.String inputPrompt)
protected boolean isWordwrap()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||