[richfaces-issues] [JBoss JIRA] Commented: (RF-5195) need to correct oncahnge handler
Alexandr Levkovsky (JIRA)
jira-events at lists.jboss.org
Fri Dec 5 10:59:37 EST 2008
[ https://jira.jboss.org/jira/browse/RF-5195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12441409#action_12441409 ]
Alexandr Levkovsky commented on RF-5195:
----------------------------------------
For all Editor event attributes (oninit, onchange, onsave, onsetup) was added wrapping in javascript function.
First parameter of all wrappers is 'event' - Event onstance with name "Init" or "Change" and so on. Event also have event.rich.component - Richfaces Editor component instance and event.rich.tinyMceInstance - Tiny MCE editor instance.
All other parameters same as in tyny MCE API: you can see them on http://wiki.moxiecode.com/index.php/TinyMCE:Configuration
So values for this attributes should contain function calls.
Usage examples:
oninit="myCustomOnInitFunction(event);"
onchange="myCustomOnChangeFunction(event, inst);"
onsetup="myCustomOnSetupFunction(event, ed);"
onsave="myCustomOnSaveFunction(event, element_id, html, body);"
NOTE: onsave fuction have html parameter - this is editor content and also should return some html to be saved. See example on http://wiki.moxiecode.com/index.php/TinyMCE:Configuration/save_callback. If it will not return some value - nothing will be saved.
NOTE: Not allowed to add function which submit form with your editor to onsave event - because onsave callback called after every submit of the editor form - the browser will hang up with cycling
> need to correct oncahnge handler
> --------------------------------
>
> Key: RF-5195
> URL: https://jira.jboss.org/jira/browse/RF-5195
> Project: RichFaces
> Issue Type: Task
> Components: planning_all
> Affects Versions: 3.3.0
> Reporter: Ilya Shaikovsky
> Assignee: Alexandr Levkovsky
> Priority: Critical
> Fix For: 3.3.0
>
> Time Spent: 2 hours
> Remaining Estimate: 0 minutes
>
> In current state we could not use support or jsFunction in order to submit the changes. Only poll or command components could be used to submit outside.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the richfaces-issues
mailing list