mirror of
https://github.com/konvajs/konva.git
synced 2026-03-03 16:58:33 +08:00
@@ -60,8 +60,11 @@
|
||||
* @returns {Container}
|
||||
*/
|
||||
add: function(child) {
|
||||
if (child.getParent()) {
|
||||
child.moveTo(this);
|
||||
return;
|
||||
}
|
||||
var children = this.children;
|
||||
|
||||
this._validateAdd(child);
|
||||
child.index = children.length;
|
||||
child.parent = this;
|
||||
|
||||
Reference in New Issue
Block a user