@API(type=EXTENDABLE, src=PUBLIC) public abstract class AbstractInplaceEditor extends java.lang.Object implements InplaceEditor
Constructor and Description |
---|
AbstractInplaceEditor() |
Modifier and Type | Method and Description |
---|---|
void |
addEditingListener(InplaceEditingListener editingListener)
Adds a listener to receive edit notifications:
-
InplaceEditingListener.editingCanceled() to remove the editor and
cancel the edit operation. |
void |
commitValue()
Commit the given value inside the document without stopping the editing.
|
protected void |
fireCommitValue(EditingEvent event)
Notify the interested listeners that the current value must be committed.
|
protected void |
fireEditingCanceled()
Notify the interested listeners that the editing was canceled.
|
protected void |
fireEditingOccured()
Notify the interested listeners that an edit occurred inside the editor.
|
protected void |
fireEditingStopped(EditingEvent event)
Notify the interested listeners that the editing stopped.
|
protected void |
fireNextEditLocationRequested()
Notify the interested listeners that the next edit position was requested.
|
protected void |
firePreviousEditLocationRequested()
Notify the interested listeners that the previous edit position was requested.
|
protected java.lang.Boolean |
getBoolean(AuthorInplaceContext context,
java.lang.String key)
Gets a boolean from the properties set on the form control.
|
boolean |
insertContent(java.lang.String content)
An insert text event was received by the author page and redirected to this currently active form control.
|
void |
refresh(AuthorInplaceContext context)
While this editor is inside an editing session a document change was detected
that didn't originated form this editor.
|
void |
removeEditingListener(InplaceEditingListener editingListener)
Removes a listener that receives editing events.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
cancelEditing, getEditorComponent, getScrollRectangle, getValue, requestFocus, stopEditing
getDescription
protected void fireEditingStopped(EditingEvent event)
event
- Editing event.protected void fireEditingCanceled()
protected void fireEditingOccured()
protected void fireNextEditLocationRequested()
protected void firePreviousEditLocationRequested()
public final void addEditingListener(InplaceEditingListener editingListener)
InplaceEditor
InplaceEditingListener.editingCanceled()
to remove the editor and
cancel the edit operation.
- InplaceEditingListener.editingOccured()
to signal modification in
the editor. This event marks the editor as dirty and it's value will be
committed when a InplaceEditingListener.editingStopped(EditingEvent)
is received.
- InplaceEditingListener.editingStopped(EditingEvent)
to end editing
and commit it's value if needed. The value is usually committed ONLY if
a InplaceEditingListener.editingOccured()
was fired. See
InplaceEditingListener.editingStopped(EditingEvent)
for more information.addEditingListener
in interface InplaceEditor
editingListener
- Editing listener.InplaceEditor.addEditingListener(ro.sync.ecss.extensions.api.editor.InplaceEditingListener)
public final void removeEditingListener(InplaceEditingListener editingListener)
InplaceEditor
removeEditingListener
in interface InplaceEditor
editingListener
- Editing listener.InplaceEditor.removeEditingListener(ro.sync.ecss.extensions.api.editor.InplaceEditingListener)
protected void fireCommitValue(EditingEvent event)
event
- Editing event.protected java.lang.Boolean getBoolean(AuthorInplaceContext context, java.lang.String key)
context
- The context.key
- The property key.Boolean.TRUE
, Boolean.FALSE
, or null
if the property is not set.public void refresh(AuthorInplaceContext context)
InplaceEditor
this editor edits an attribute and the same attribute was externally modified. In this situation is recommended for the editor to update the current value.
refresh
in interface InplaceEditor
context
- An updated editing context for this editor.InplaceEditor.refresh(ro.sync.ecss.extensions.api.editor.AuthorInplaceContext)
public boolean insertContent(java.lang.String content)
InplaceEditor
insertContent
in interface InplaceEditor
content
- Content to be inserted.true
if the event was handled or false
if the form control can do nothing with the string. For example a text field
can insert the text inside it but a check box form control can do nothing with it.
If false
is returned the form control editing session will be
stopped and the author page will handle the event instead.InplaceEditor.insertContent(java.lang.String)
public void commitValue()
InplaceEditor
commitValue
in interface InplaceEditor
InplaceEditor.commitValue()
© Copyright SyncRO Soft SRL 2002 - 2015. All rights reserved.