public class FancyFileUpload
extends com.google.gwt.user.client.ui.Composite
implements com.google.gwt.user.client.ui.HasText, com.google.gwt.user.client.ui.HasWordWrap, com.google.gwt.user.client.ui.SourcesChangeEvents
FancyFileUpload class is use to upload images from client in the UI| Modifier and Type | Class and Description |
|---|---|
protected class |
FancyFileUpload.UploadDisplay
Class used for the display of filename to be uploaded,
and handling the update of the display states.
|
| Modifier and Type | Field and Description |
|---|---|
int |
DELETED_STATE |
int |
EMPTY_STATE
State definitions
|
int |
FAILED_STATE |
int |
PENDING_STATE |
int |
UPLOADED_STATE |
int |
UPLOADING_STATE |
| Constructor and Description |
|---|
FancyFileUpload(ImageUploaderDialog owner,
String templateName) |
| Modifier and Type | Method and Description |
|---|---|
void |
addChangeListener(com.google.gwt.user.client.ui.ChangeListener listener)
Add a change listener
|
int |
getCheckForFileNameDelay()
Return the delay value set for checking a file.
|
int |
getPendingDelay()
Return value set for pending delay.
|
String |
getText()
Get the text from the widget - which in reality will be retrieving any
value set in the Label element of the display widget.
|
int |
getUploadState()
Retrieve the status of the upload widget.
|
boolean |
getWordWrap()
Return if the label in the display widget is wordwrapped or not.
|
void |
removeChangeListener(com.google.gwt.user.client.ui.ChangeListener listener)
Remove a change listener
|
void |
setCheckForFileNameDelay(int newDelay)
Set the delay for checking for a filename to appear in the FileUpload widget
Might be useful if there are performance issues.
|
void |
setPendingDelay(int newDelay)
Set the delay value indicating how long a file will remain in
pending mode
prior to the upload action taking place.
|
void |
setText(String text)
Cannot set the text of a File Upload Widget, so raise an exception.
|
void |
setWordWrap(boolean wrap)
Set the word wrap value of the label in the display widget.
|
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidgetaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString, unsinkEventspublic final int EMPTY_STATE
public final int PENDING_STATE
public final int UPLOADING_STATE
public final int UPLOADED_STATE
public final int DELETED_STATE
public final int FAILED_STATE
public FancyFileUpload(ImageUploaderDialog owner, String templateName)
owner - the callertemplateName - .public String getText()
getText in interface com.google.gwt.user.client.ui.HasTextpublic void setText(String text)
setText in interface com.google.gwt.user.client.ui.HasTexttext - .public int getUploadState()
public void setCheckForFileNameDelay(int newDelay)
newDelay - .public void setPendingDelay(int newDelay)
newDelay - .public int getCheckForFileNameDelay()
public int getPendingDelay()
public boolean getWordWrap()
getWordWrap in interface com.google.gwt.user.client.ui.HasWordWrappublic void setWordWrap(boolean wrap)
setWordWrap in interface com.google.gwt.user.client.ui.HasWordWrapwrap - .public void addChangeListener(com.google.gwt.user.client.ui.ChangeListener listener)
addChangeListener in interface com.google.gwt.user.client.ui.SourcesChangeEventslistener - ,public void removeChangeListener(com.google.gwt.user.client.ui.ChangeListener listener)
removeChangeListener in interface com.google.gwt.user.client.ui.SourcesChangeEventslistener - .Copyright © 2014. All Rights Reserved.