com.ephox.editlive.common
Class TextEvent.CustomAction

java.lang.Object
  extended by com.ephox.editlive.common.TextEvent.CustomAction
Enclosing class:
TextEvent

public class TextEvent.CustomAction
extends Object

The set of event codes used as the extra int in custom action events.


Field Summary
static int CUSTOM_PROPERTIES_DIALOG
          Indicates that a show custom properties dialog event should be fired.
static int GET_BODY
          Deprecated. No longer used.
static int GET_BOOKMARK_LIST
          Deprecated. No longer used.
static int GET_CHARACTER_COUNT
          Deprecated. No longer used.
static int GET_CURRENT_FILE
          Return the URL of the current file.
static int GET_DOCUMENT
          Deprecated. No longer used.
static int GET_HYPERLINK_AT_CURSOR
          Returns the hyperlink under the cursor
static int GET_SELECTED_TEXT
          Returns the currently selected text
static int GET_STYLES
          Deprecated. No longer used.
static int GET_WORD_AT_CURSOR
          Returns the word under the cursor
static int GET_WORD_COUNT
          Deprecated. No longer used.
static int INSERT_AND_EDIT_INLINE_TAG_ACTION
          Insert an inline tag and immediately trigger a custom properties dialog for it.
static int INSERT_HTML_ACTION
          Insert HTML at the caret position.
static int INSERT_HYPERLINK_ACTION
          Insert a hyperlink at the caret position.
static int INSERT_INLINE_TAG_ACTION
          Inserts an inline tag around the current selection.
static int IS_DIRTY
          Returns the isDirty value to the browser when using the ELJ applet
static int IS_VALID
          Deprecated. No longer used.
static int POST_DOCUMENT
          Posts the document to a specified URL using HTTP POST.
static int RAISE_EVENT
          Raise an event back to the browser.
static int SCROLL_TO
          Scroll to a specified anchor in the document, switching views if nessecary.
static int SET_BODY
          Deprecated. No longer used.
static int SET_DIRECTION
          Set the dir attribute to be used on the body when setting the source.
static int SET_DOCUMENT
          Deprecated. No longer used.
static int SET_HTTP_LAYER
          Deprecated. use HttpLayerManager.setManager(HttpLayer) instead
static int SET_PROPERTIES
          Sets the properties for an element.
static int SET_XML_NODE_VALUE
          Deprecated. No longer used.
static int UPLOAD_FILES
          Upload local files to the server.
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RAISE_EVENT

public static final int RAISE_EVENT
Raise an event back to the browser. Not available in the JavaBean.

See Also:
Constant Field Values

INSERT_HYPERLINK_ACTION

public static final int INSERT_HYPERLINK_ACTION
Insert a hyperlink at the caret position.

See Also:
Constant Field Values

INSERT_HTML_ACTION

public static final int INSERT_HTML_ACTION
Insert HTML at the caret position.

See Also:
Constant Field Values

GET_DOCUMENT

@Deprecated
public static final int GET_DOCUMENT
Deprecated. No longer used.
See Also:
Constant Field Values

GET_BODY

@Deprecated
public static final int GET_BODY
Deprecated. No longer used.
See Also:
Constant Field Values

GET_STYLES

@Deprecated
public static final int GET_STYLES
Deprecated. No longer used.
See Also:
Constant Field Values

SET_DOCUMENT

@Deprecated
public static final int SET_DOCUMENT
Deprecated. No longer used.
See Also:
Constant Field Values

SET_BODY

@Deprecated
public static final int SET_BODY
Deprecated. No longer used.
See Also:
Constant Field Values

GET_WORD_COUNT

@Deprecated
public static final int GET_WORD_COUNT
Deprecated. No longer used.
See Also:
Constant Field Values

GET_CHARACTER_COUNT

@Deprecated
public static final int GET_CHARACTER_COUNT
Deprecated. No longer used.
See Also:
Constant Field Values

SET_PROPERTIES

public static final int SET_PROPERTIES
Sets the properties for an element. Should be used in response to a custom properties dialog.

See Also:
Constant Field Values

CUSTOM_PROPERTIES_DIALOG

public static final int CUSTOM_PROPERTIES_DIALOG
Indicates that a show custom properties dialog event should be fired. Note that this event should not be intercepted by the bean as it's value does not contain the properties for the element. Instead, intercept the TextEvent.SHOW_CUSTOM_PROPERTIES event.

The extra string value must be the name of the element to get the properties for (eg: img).

See Also:
Constant Field Values

UPLOAD_FILES

public static final int UPLOAD_FILES
Upload local files to the server. Currently this only applies to local images.

See Also:
Constant Field Values

GET_CURRENT_FILE

public static final int GET_CURRENT_FILE
Return the URL of the current file. The current file will be an empty string if the document was not opened via an open dialog or been saved via a save dialog.

See Also:
Constant Field Values

IS_VALID

@Deprecated
public static final int IS_VALID
Deprecated. No longer used.
See Also:
Constant Field Values

GET_SELECTED_TEXT

public static final int GET_SELECTED_TEXT
Returns the currently selected text

See Also:
Constant Field Values

POST_DOCUMENT

public static final int POST_DOCUMENT
Posts the document to a specified URL using HTTP POST. The extra string must be of the form:

{fieldName}##ephox##{url}##ephox##{handleResponse}(##ephox##{callback})

Where:

fieldName
the name of the field to post the document as in the POST. Equivalent to name on a form element.
url
the URL to post to
handleResponse
how to handle the response. One of callback to callback to a JavaScript method (must specify callback) or saveToDisk to save the response as a file to disk.
callback
the JavaScript method to callback to. This is only required when handleResponse is callback, otherwise it is ignored.

See Also:
Constant Field Values

SET_XML_NODE_VALUE

@Deprecated
public static final int SET_XML_NODE_VALUE
Deprecated. No longer used.
See Also:
Constant Field Values

INSERT_INLINE_TAG_ACTION

public static final int INSERT_INLINE_TAG_ACTION
Inserts an inline tag around the current selection. The value should be the name of the tag to insert.

See Also:
Constant Field Values

IS_DIRTY

public static final int IS_DIRTY
Returns the isDirty value to the browser when using the ELJ applet

See Also:
Constant Field Values

SET_HTTP_LAYER

@Deprecated
public static final int SET_HTTP_LAYER
Deprecated. use HttpLayerManager.setManager(HttpLayer) instead
See Also:
Constant Field Values

SCROLL_TO

public static final int SCROLL_TO
Scroll to a specified anchor in the document, switching views if nessecary. The extra string must specify the name of the view and the anchor to switch to separated by a colon (:). Note that the anchor is not prefixed with a #. Eg: myview:myanchor.

For EditLive! or when switching views is not desired, the view and colon can be omitted. Eg: myanchor.

See Also:
Constant Field Values

GET_WORD_AT_CURSOR

public static final int GET_WORD_AT_CURSOR
Returns the word under the cursor

See Also:
Constant Field Values

GET_HYPERLINK_AT_CURSOR

public static final int GET_HYPERLINK_AT_CURSOR
Returns the hyperlink under the cursor

See Also:
Constant Field Values

GET_BOOKMARK_LIST

@Deprecated
public static final int GET_BOOKMARK_LIST
Deprecated. No longer used.
See Also:
Constant Field Values

INSERT_AND_EDIT_INLINE_TAG_ACTION

public static final int INSERT_AND_EDIT_INLINE_TAG_ACTION
Insert an inline tag and immediately trigger a custom properties dialog for it.

The extra string must be the JavaScript function to call back to followed by the name of the tag to insert separated by a colon (:).

See Also:
Constant Field Values

SET_DIRECTION

public static final int SET_DIRECTION
Set the dir attribute to be used on the body when setting the source. The extra string must be the value for the dir attribute to have.

See Also:
Constant Field Values

Copyright (c) 2005-2012 Ephox Pty Ltd. All rights reserved.