-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
State wrapper error in AmplitudeKeypadDialog #220
Comments
A few things...
show( order, enterCallback, closeCallback ) {
// ... do stuff specific to AmplitudeKeypadDialog
super.show();
}
|
I investigated this approach, and it looks promising. But it was not entirely straightforward, and I ran into problems with emphasized harmonics not behaving properly, followed by a crash. So I bailed for now, and will defer until we resume work on this sim. |
When this sim was converted to TypeScript in 600727c, the following change was made: public override hide(): void {
super.hide();
this.interruptSubtreeInput();
- this.closeCallback();
+ this.closeCallback && this.closeCallback(); This fixed the crash during fuzzing. But the list of emphasized harmonics (managed via So I'll leave this issue open, to be investigated when work resumes on a PhET-iO version of this sim. |
When fuzz testing the State wrapper with
phet-io-wrappers/state/?sim=fourier-making-waves&phetioDebug&fuzz
, this error occurs:AmplitudeKeypadDialog is this dialog, opened by pressing on one of the amplitude values shown above the amplitude sliders.
AmplitudeKeypadDialog has field
this.closeCallback
. It's set whenshow
is called, then called (and cleared) whenhide
is called. So what I guess is happening is that the dialog is somehow being opened by the State wrapper without callingshow
.AmplitudeKeypadDialog has another field,
this.enterCallback
, that I suspect would have a similar problem. It's set whenshow
is called, then called (and cleared) when the Enter button is pressed.The text was updated successfully, but these errors were encountered: