Use arrow function notation when registering click listener for...

...quick menu buttons
This commit is contained in:
Jordan Irwin 2024-06-23 21:41:17 -07:00
parent 46e399b30f
commit a6ddc99d8d
No known key found for this signature in database
GPG key ID: E3E358C2F44C290A

View file

@ -52,7 +52,9 @@ export abstract class QuickMenuButton extends Component {
// listen for click events
// FIXME: do we need to store this value for potential cleanup?
new ElementClickListener(this.componentElement).onClick = this.onClick;
new ElementClickListener(this.componentElement).onClick = (evt: Event) => {
this.onClick(evt);
};
this.update();
}