Add register to API for registering reusable function chains

This commit is contained in:
2023-11-16 22:39:51 +02:00
parent 02fc13803f
commit 9c362d6a5d
4 changed files with 35 additions and 22 deletions

View File

@ -1,13 +1,13 @@
import { type Editor } from "../main";
import { Event } from "./AbstractEvents";
import { AbstractEvent } from "./AbstractEvents";
export class RestEvent extends Event {
export class RestEvent extends AbstractEvent {
constructor(length: number, app: Editor) {
super(app);
this.values["noteLength"] = length;
}
_fallbackMethod = (): Event => {
_fallbackMethod = (): AbstractEvent => {
return RestEvent.createRestProxy(this.values["noteLength"], this.app);
};