Fix broadcast pip seekbar (#10072)

This commit is contained in:
Michael Weimann 2023-02-06 13:15:20 +01:00 committed by GitHub
parent 5ba8ecabb5
commit 39fe72e53a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -258,17 +258,16 @@ class PipContainerInner extends React.Component<IProps, IState> {
} }
private createVoiceBroadcastPlaybackPipContent(voiceBroadcastPlayback: VoiceBroadcastPlayback): CreatePipChildren { private createVoiceBroadcastPlaybackPipContent(voiceBroadcastPlayback: VoiceBroadcastPlayback): CreatePipChildren {
if (this.state.viewedRoomId === voiceBroadcastPlayback.infoEvent.getRoomId()) { const content =
return ({ onStartMoving }) => ( this.state.viewedRoomId === voiceBroadcastPlayback.infoEvent.getRoomId() ? (
<div onMouseDown={onStartMoving}> <VoiceBroadcastPlaybackBody playback={voiceBroadcastPlayback} pip={true} />
<VoiceBroadcastPlaybackBody playback={voiceBroadcastPlayback} pip={true} /> ) : (
</div> <VoiceBroadcastSmallPlaybackBody playback={voiceBroadcastPlayback} />
); );
}
return ({ onStartMoving }) => ( return ({ onStartMoving }) => (
<div onMouseDown={onStartMoving}> <div key={voiceBroadcastPlayback.infoEvent.getId()} onMouseDown={onStartMoving}>
<VoiceBroadcastSmallPlaybackBody playback={voiceBroadcastPlayback} /> {content}
</div> </div>
); );
} }