Skip to content

Commit

Permalink
js: fix condition error cause print error log
Browse files Browse the repository at this point in the history
  • Loading branch information
penfeizhou committed Aug 4, 2023
1 parent 411ca69 commit a9c5281
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions doric-js/bundle/doric-lib.es5.js
Original file line number Diff line number Diff line change
Expand Up @@ -1371,12 +1371,12 @@ var Panel = /** @class */ (function () {
return diryData;
};
Panel.prototype.onRenderFinished = function () {
this.callingRenderFinishedCallback = false;
this.callingRenderFinishedCallback = true;
this.onRenderFinishedCallback.forEach(function (e) {
e();
});
this.onRenderFinishedCallback.length = 0;
this.callingRenderFinishedCallback = true;
this.callingRenderFinishedCallback = false;
};
Panel.prototype.addOnRenderFinishedCallback = function (cb) {
if (this.callingRenderFinishedCallback) {
Expand Down
4 changes: 2 additions & 2 deletions doric-js/bundle/doric-lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -1049,12 +1049,12 @@ class Panel {
return diryData;
}
onRenderFinished() {
this.callingRenderFinishedCallback = false;
this.callingRenderFinishedCallback = true;
this.onRenderFinishedCallback.forEach(e => {
e();
});
this.onRenderFinishedCallback.length = 0;
this.callingRenderFinishedCallback = true;
this.callingRenderFinishedCallback = false;
}
addOnRenderFinishedCallback(cb) {
if (this.callingRenderFinishedCallback) {
Expand Down
4 changes: 2 additions & 2 deletions doric-js/bundle/doric-vm.js
Original file line number Diff line number Diff line change
Expand Up @@ -2589,12 +2589,12 @@ class Panel {
return diryData;
}
onRenderFinished() {
this.callingRenderFinishedCallback = false;
this.callingRenderFinishedCallback = true;
this.onRenderFinishedCallback.forEach(e => {
e();
});
this.onRenderFinishedCallback.length = 0;
this.callingRenderFinishedCallback = true;
this.callingRenderFinishedCallback = false;
}
addOnRenderFinishedCallback(cb) {
if (this.callingRenderFinishedCallback) {
Expand Down
4 changes: 2 additions & 2 deletions doric-js/lib/src/ui/panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -222,12 +222,12 @@ export class Panel {
return diryData;
}
onRenderFinished() {
this.callingRenderFinishedCallback = false;
this.callingRenderFinishedCallback = true;
this.onRenderFinishedCallback.forEach(e => {
e();
});
this.onRenderFinishedCallback.length = 0;
this.callingRenderFinishedCallback = true;
this.callingRenderFinishedCallback = false;
}
addOnRenderFinishedCallback(cb) {
if (this.callingRenderFinishedCallback) {
Expand Down
4 changes: 2 additions & 2 deletions doric-js/src/ui/panel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -259,12 +259,12 @@ export abstract class Panel {
}

onRenderFinished() {
this.callingRenderFinishedCallback = false
this.callingRenderFinishedCallback = true
this.onRenderFinishedCallback.forEach(e => {
e()
})
this.onRenderFinishedCallback.length = 0
this.callingRenderFinishedCallback = true
this.callingRenderFinishedCallback = false
}

addOnRenderFinishedCallback(cb: () => void) {
Expand Down

0 comments on commit a9c5281

Please sign in to comment.