mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-08-13 00:19:17 +02:00
Migrate more events to EventBus
This commit is contained in:
@@ -3,11 +3,7 @@ window.BX_EXPOSED.streamSession = this;
|
||||
const orgSetMicrophoneState = this.setMicrophoneState.bind(this);
|
||||
this.setMicrophoneState = state => {
|
||||
orgSetMicrophoneState(state);
|
||||
|
||||
const evt = new Event(BxEvent.MICROPHONE_STATE_CHANGED);
|
||||
evt.microphoneState = state;
|
||||
|
||||
window.dispatchEvent(evt);
|
||||
window.BxEventBus.Stream.emit('microphone.state.changed', { state });
|
||||
};
|
||||
|
||||
window.dispatchEvent(new Event(BxEvent.STREAM_SESSION_READY));
|
||||
|
Reference in New Issue
Block a user