Finished WindowAPI for the frontend
This commit is contained in:
11
WindowAPI/dist/helper/functions/WindowEventEmitter.d.ts
vendored
Normal file
11
WindowAPI/dist/helper/functions/WindowEventEmitter.d.ts
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
import { WindowEventName } from "../PackageTypes.js";
|
||||
import { WindowEvent } from "../EventData.js";
|
||||
export declare type WindowEventListener = (event: WindowEvent) => void;
|
||||
export declare abstract class WindowEventEmitter {
|
||||
protected _events: {
|
||||
[name: string]: WindowEventListener[];
|
||||
};
|
||||
abstract on(name: WindowEventName, listener: WindowEventListener): void;
|
||||
abstract removeListener(name: WindowEventName, listenerToRemove: WindowEventListener): void;
|
||||
abstract emit(name: WindowEventName, data: WindowEvent): void;
|
||||
}
|
||||
Reference in New Issue
Block a user