General memory clean up after destroy of last editor
|Reported by:||alfonsoml||Owned by:||alfonsoml|
This is a follow up of #4555
After talks with Fred and Garry, it seems that we can provide a generic memory clean up to free resources after the last instance of CKEditor is destroyed with just a few lines.
The idea of this patch is to clean up anything that might have been left around, but to avoid problems with pages that don't destroy all the editors we should keep the current protections.