Skip to content

Commit 3f7b314

Browse files
committed
Fixed a bug that layoutComponent is undefinedFixed a bug that layoutComponent is undefined
1 parent 8cfd5c6 commit 3f7b314

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

frameworks/js-bindings/bindings/script/studio/parsers/timelineParser-2.x.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,8 @@
293293
widget.setColor(getColor(color));
294294

295295
var layoutComponent = ccui.LayoutComponent.bindLayoutComponent(widget);
296+
if(!layoutComponent)
297+
return;
296298

297299
var positionXPercentEnabled = json["PositionPercentXEnable"] || false;
298300
var positionYPercentEnabled = json["PositionPercentYEnable"] || false;

0 commit comments

Comments
 (0)