From 856d0eea6cd006939bdd928c97036fbdfddcc346 Mon Sep 17 00:00:00 2001 From: Bill Date: Mon, 16 Aug 2021 01:44:22 -0400 Subject: [PATCH] Add RoomWidgetUpdateSongEvent --- .../room/events/RoomWidgetUpdateSongEvent.ts | 35 +++++++++++++++++++ src/views/room/events/index.ts | 1 + 2 files changed, 36 insertions(+) create mode 100644 src/views/room/events/RoomWidgetUpdateSongEvent.ts diff --git a/src/views/room/events/RoomWidgetUpdateSongEvent.ts b/src/views/room/events/RoomWidgetUpdateSongEvent.ts new file mode 100644 index 00000000..a676a06a --- /dev/null +++ b/src/views/room/events/RoomWidgetUpdateSongEvent.ts @@ -0,0 +1,35 @@ +import { RoomWidgetUpdateEvent } from './RoomWidgetUpdateEvent'; + +export class RoomWidgetUpdateSongEvent extends RoomWidgetUpdateEvent +{ + public static PLAYING_CHANGED: string = 'RWUSE_PLAYING_CHANGED'; + public static DATA_RECEIVED: string = 'RWUSE_DATA_RECEIVED'; + + private _songId: number; + private _songName: string; + private _songAuthor: string; + + constructor(type: string, songId: number, songName: string, songAuthor: string) + { + super(type); + + this._songId = songId; + this._songName = songName; + this._songAuthor = songAuthor; + } + + public get songId(): number + { + return this._songId; + } + + public get songName(): string + { + return this._songName; + } + + public get songAuthor(): string + { + return this._songAuthor; + } +} diff --git a/src/views/room/events/index.ts b/src/views/room/events/index.ts index b11465ce..151396d1 100644 --- a/src/views/room/events/index.ts +++ b/src/views/room/events/index.ts @@ -19,6 +19,7 @@ export * from './RoomWidgetUpdateInfostandPetEvent'; export * from './RoomWidgetUpdateInfostandRentableBotEvent'; export * from './RoomWidgetUpdateInfostandUserEvent'; export * from './RoomWidgetUpdateRentableBotChatEvent'; +export * from './RoomWidgetUpdateSongEvent'; export * from './RoomWidgetUpdateUserDataEvent'; export * from './RoomWidgetUseProductBubbleEvent'; export * from './UseProductItem';