Skip to content

Commit

Permalink
simplify codes
Browse files Browse the repository at this point in the history
  • Loading branch information
minggo committed Jun 14, 2023
1 parent 4910bea commit 3c8b7f1
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions cocos/ui/widget-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -228,9 +228,8 @@ function refreshScene () {
}
const i = 0;
let widget: Widget | null = null;
const iterator = widgetManager._activeWidgetsIterator;
for (iterator.i = 0; iterator.i < activeWidgets.length; ++iterator.i) {
widget = activeWidgets[iterator.i];
for (let i = 0; i < activeWidgets.length; ++i) {
widget = activeWidgets[i];
if (widget._dirty) {
align(widget.node, widget);
widget._dirty = false;
Expand Down

0 comments on commit 3c8b7f1

Please sign in to comment.