Ticket #1333 (closed defect: fixed)
inaccurate comment in XinhaCore.js
| Reported by: | guest | Owned by: | gogo |
|---|---|---|---|
| Priority: | normal | Milestone: | 0.96 |
| Component: | Xinha Core | Version: | trunk |
| Severity: | minor | Keywords: | |
| Cc: | ianb@… |
Description
This comment in XinhaCore?.js seems incorrect; the first argument should be the tooltip, and the last a callback (as can be seen just before it in the source):
/** ADDING CUSTOM BUTTONS
* ---------------------
*
*
* Example on how to add a custom button when you construct the Xinha:
*
* var editor = new Xinha("your_text_area_id");
* var cfg = editor.config; // this is the default configuration
* cfg.btnList["my-hilite"] =
* [ function(editor) { editor.surroundHTML('<span style="background:yellow">', '</span>'); }, // action
* "Highlight selection", // tooltip
* "my_hilite.gif", // image
* false // disabled in text mode
* ];
* cfg.toolbar.push(["linebreak", "my-hilite"]); // add the new button to the toolbar
*
Change History
Note: See
TracTickets for help on using
tickets.
