|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.confluence.tinymceplugin.TinyMceEditor
public class TinyMceEditor
Field Summary | |
---|---|
static java.lang.String |
PLUGIN_KEY
|
static java.lang.String |
WEB_RESOURCES_KEY
|
Constructor Summary | |
---|---|
TinyMceEditor()
|
Method Summary | |
---|---|
java.lang.String |
escapeHtml(java.lang.String html)
Perform any necessary escaping of the HTML rendered by Confluence. |
java.lang.String |
getDivContentsTemplate()
Returns the div contents to display the editor itself. |
java.lang.String |
getEditorSpecificCss()
Return a string of CSS which will be appended to the standard stylesheet if it is requested from /styles/wysiwyg-action Note that it is up to the editor implementation to retrieve this stylesheet and apply it to the editor contents -- the page containing the editor is styled with the normal stylesheet. |
java.lang.String |
getJavascriptTemplate()
|
java.lang.String |
getResourcesKey()
Returns the complete module key of the editor's web resources to be included. |
boolean |
supportedUserAgent(java.lang.String userAgent)
Return true if the user agent string indicates a browser which is supported by this editor |
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 PLUGIN_KEY
public static final java.lang.String WEB_RESOURCES_KEY
Constructor Detail |
---|
public TinyMceEditor()
Method Detail |
---|
public java.lang.String getResourcesKey()
Editor
One of the web resources must return some javascript that allows Confluence to interface with the editor. The Javascript returned must define the folowing functions under the namespace AJS.Editor.Adapter: onShowEditor() -- this is called just after the DIV containing the editor is made visible. It is a hook where you can place any special code needed at this point. onHideEditor() -- this is called just before the DIV containing the editor is hidden. It is a hook where you can place any special code needed at this point. setEditorValue(newValue) -- put the text in newValue into the editor. This is called when the editor needs new content -- it is *not* called to set the initial content. That should be done either by providing the editor with the content as part of the initial HTML, or by calling javascript from editorOnLoad(). allowModeChange() -- return true if the editor is in a state where changes from rich text to markup and vice versa are allowed. getEditorHTML() -- return the current HTML contents of the editor. This *must* return a JavaScript string, not a JavaObject wrapping a java.lang.String! editorOnLoad() -- called in the page's onLoad handler, place any initialization needed at this point here. editorHasContentChanged() -- return true if the contents of the editor has been modified by the user since the last time editorResetContentChanged(). editorResetContentChanged() -- called to reset the contents change indicator
getResourcesKey
in interface Editor
public java.lang.String getDivContentsTemplate()
Editor
getDivContentsTemplate
in interface Editor
public boolean supportedUserAgent(java.lang.String userAgent)
Editor
supportedUserAgent
in interface Editor
public java.lang.String escapeHtml(java.lang.String html)
Editor
escapeHtml
in interface Editor
public java.lang.String getJavascriptTemplate()
getJavascriptTemplate
in interface Editor
public java.lang.String getEditorSpecificCss()
Editor
getEditorSpecificCss
in interface Editor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |