|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xwiki.gwt.user.client.ui.wizard.AbstractNavigationAwareWizardStep org.xwiki.gwt.user.client.ui.wizard.AbstractInteractiveWizardStep org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractSelectorWizardStep<D> org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractListSelectorWizardStep<EntityLink<C>,E> org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractEntityListSelectorWizardStep<ImageConfig,Attachment> org.xwiki.gwt.wysiwyg.client.plugin.image.ui.CurrentPageImageSelectorWizardStep
public class CurrentPageImageSelectorWizardStep
Wizard step to select an image from the list of images attached to a page.
Constructor Summary | |
---|---|
CurrentPageImageSelectorWizardStep(WikiServiceAsync wikiService,
boolean useLinkDestination)
Creates a new image selector that displays the images attached to the link destination page. |
Method Summary | |
---|---|
protected void |
fetchData(com.google.gwt.user.client.rpc.AsyncCallback<List<Attachment>> callback)
Fetches the list of items to be displayed in this list from the server. |
protected ListItem<Attachment> |
fillList(List<Attachment> attachments,
Attachment selectedAttachment)
Fills the list with the given data and returns the item that matches the specified item. |
protected ListItem<Attachment> |
getListItem(Attachment image)
|
protected ListItem<Attachment> |
getNewOptionListItem()
|
String |
getNextStep()
Returns the key of the next step in the wizard. |
protected String |
getSelectErrorMessage()
|
protected String |
getSelectHelpLabel()
|
void |
onSelection(com.google.gwt.event.logical.shared.SelectionEvent<ListItem<Attachment>> event)
|
protected void |
saveSelectedValue(com.google.gwt.user.client.rpc.AsyncCallback<Boolean> async)
Saves the current selection in this panel in the data managed by this wizard step, if all validation goes well on the submit time. |
Methods inherited from class org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractEntityListSelectorWizardStep |
---|
isSelectedByDefault |
Methods inherited from class org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractListSelectorWizardStep |
---|
addNavigationListener, display, displayError, getErrorLabel, getList, getSelectedItem, hideError, init, onCancel, onDoubleClick, onKeyUp, onSubmit, refreshList, removeNavigationListener, setActive, setNewOptionOnTop |
Methods inherited from class org.xwiki.gwt.wysiwyg.client.widget.wizard.util.AbstractSelectorWizardStep |
---|
getData, getResult, initializeSelection |
Methods inherited from class org.xwiki.gwt.user.client.ui.wizard.AbstractInteractiveWizardStep |
---|
getStepTitle, isAutoSubmit, setStepTitle |
Methods inherited from class org.xwiki.gwt.user.client.ui.wizard.AbstractNavigationAwareWizardStep |
---|
getDirectionName, getValidDirections, setDirectionName, setNextStep, setValidDirections |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CurrentPageImageSelectorWizardStep(WikiServiceAsync wikiService, boolean useLinkDestination)
wikiService
- the service used to retrieve the list of image attachmentsuseLinkDestination
- true
to consider that the link destination is the current page, false
to consider that the link origin is the current pageMethod Detail |
---|
protected String getSelectHelpLabel()
getSelectHelpLabel
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
protected String getSelectErrorMessage()
getSelectErrorMessage
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
protected void fetchData(com.google.gwt.user.client.rpc.AsyncCallback<List<Attachment>> callback)
fetchData
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
callback
- the callback to notify when the fetching is done.protected ListItem<Attachment> fillList(List<Attachment> attachments, Attachment selectedAttachment)
fillList
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
attachments
- the list of data to fill the listselectedAttachment
- the data to be matched
public String getNextStep()
WizardStep.onSubmit(AsyncCallback)
has returned successfully, so the computing of the next step can be done safely
at WizardStep.onSubmit(AsyncCallback)
time.
getNextStep
in interface WizardStep
getNextStep
in class AbstractNavigationAwareWizardStep
protected ListItem<Attachment> getListItem(Attachment image)
getListItem
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
image
- the data to build a list item representation for.
protected ListItem<Attachment> getNewOptionListItem()
getNewOptionListItem
in class AbstractListSelectorWizardStep<EntityLink<ImageConfig>,Attachment>
null
if no such item
should be appended to the list.public void onSelection(com.google.gwt.event.logical.shared.SelectionEvent<ListItem<Attachment>> event)
onSelection
in interface com.google.gwt.event.logical.shared.SelectionHandler<ListItem<Attachment>>
protected void saveSelectedValue(com.google.gwt.user.client.rpc.AsyncCallback<Boolean> async)
saveSelectedValue
in class AbstractEntityListSelectorWizardStep<ImageConfig,Attachment>
async
- the object to be notified after the selected value is savedAbstractEntityListSelectorWizardStep.saveSelectedValue(AsyncCallback)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |