Migrate more events to EventBus

This commit is contained in:
redphx
2024-12-09 07:01:13 +07:00
parent 5fb0dec9f2
commit 7206c9e8bc
12 changed files with 59 additions and 64 deletions

View File

@@ -1,4 +1,4 @@
import { BxEvent } from "@/utils/bx-event";
import { BxEventBus } from "@/utils/bx-event-bus";
export abstract class BaseGameBarAction {
abstract $content: HTMLElement;
@@ -7,7 +7,7 @@ export abstract class BaseGameBarAction {
reset() {}
onClick(e: Event) {
BxEvent.dispatch(window, BxEvent.GAME_BAR_ACTION_ACTIVATED);
BxEventBus.Stream.emit('gameBar.activated', {});
};
render(): HTMLElement {