Additional logging for calling service

This commit is contained in:
Fedor Indutny 2022-08-16 16:52:09 -07:00 committed by GitHub
parent 932043c58f
commit 5a3c04d630
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 28 additions and 19 deletions

View file

@ -51,7 +51,7 @@ type SnapCandidate = {
export type PropsType = {
activeCall: ActiveCallType;
getGroupCallVideoFrameSource: (demuxId: number) => VideoFrameSource;
hangUpActiveCall: () => void;
hangUpActiveCall: (reason: string) => void;
hasLocalVideo: boolean;
i18n: LocalizerType;
setGroupCallVideoRequest: (_: Array<GroupCallVideoRequest>) => void;
@ -100,6 +100,10 @@ export const CallingPip = ({
setLocalPreview({ element: localVideoRef });
}, [setLocalPreview]);
const hangUp = React.useCallback(() => {
hangUpActiveCall('pip button click');
}, [hangUpActiveCall]);
const handleMouseMove = React.useCallback(
(ev: MouseEvent) => {
if (positionState.mode === PositionMode.BeingDragged) {
@ -294,7 +298,7 @@ export const CallingPip = ({
<button
aria-label={i18n('calling__hangup')}
className="module-calling-pip__button--hangup"
onClick={hangUpActiveCall}
onClick={hangUp}
type="button"
/>
<button