Fixed #2039: widget.clone's problem

Fixed #2039: widget.clone's problem