Skip to content

Commit

Permalink
Use widget id as argument for registry.remove as it takes an id and n…
Browse files Browse the repository at this point in the history
…ot a widget instance.

Add destroyRecursive method becuase containers check for and call destroyRecursive in their destroyDecendants cleanup.
  • Loading branch information
justindoherty committed Apr 24, 2012
1 parent c867a52 commit 68695b3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions extensions/DijitRegistry.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,14 @@ function(declare, registry){
this._resizeHandle.remove();
}
},

destroyRecursive: function() {
this.destroy();
},

destroy: function(){
this.inherited(arguments);
registry.remove(this);
registry.remove(this.id);
},

getChildren: function(){
Expand All @@ -38,4 +42,4 @@ function(declare, registry){
return [];
}
});
});
});

0 comments on commit 68695b3

Please sign in to comment.