Ticket #6668 (assigned enhancement)
destroy() option to not remove dom node
| Reported by: | bill | Owned by: | dante |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.2 |
| Component: | Dijit | Version: | 1.1.0 |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Keep Widget.destroy() working the same as today, where it destroys _Widget.domNode, but add parameter to destroy() such that _Widget.destroy(true) does:
- for behavioral widgets it leaves the original dom node in place, just removing the behavior
- eventually (not for milestone 1.2) for templated widgets, it will revert the widget to it's original source dom node. In the case of form widgets, the original dom node is an <input>, and the form widget's value should be written to that input, so that form submit works as if the widget still existed. This will hopefully make the back/forward button not erase or "misalign" the values the user previously input into the form. (Have to be a bit careful w/this one though because currently for performance reasons we destroy the original dom node)
This requires removing the finalize parameter from destroy(), but it's unused anyway so that shouldn't be an issue.
Attachments
Change History
Note: See
TracTickets for help on using
tickets.