clone: reallow cloning a clone's child (#127)

This commit is contained in:
bordun 2018-03-26 23:43:22 +02:00
parent 53432fe33f
commit 2f451b3917
2 changed files with 7 additions and 8 deletions

View file

@ -90,15 +90,8 @@ class Clone extends Widget {
isValidCloneTarget(widget) {
if (widget.contains(this) || this.contains(widget)) return false
return !(widget.contains(this) || this.contains(widget))
var parent = widget.parent
while (parent && parent !== widgetManager) {
if (parent.getProp('type') === 'clone') return false
parent = parent.parent
}
return true
}
cleanClone() {