mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-10-22 03:07:39 +00:00
Improve the Widget.prototype.removeChildDomNodes() method so that most subclasses won't need to override it
This commit is contained in:
@@ -103,16 +103,6 @@ CheckboxWidget.prototype.refresh = function(changedTiddlers) {
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
*/
|
||||
CheckboxWidget.prototype.removeChildDomNodes = function() {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
};
|
||||
|
||||
exports.checkbox = CheckboxWidget;
|
||||
|
||||
})();
|
||||
|
Reference in New Issue
Block a user