Adds keyboard shortcuts for calling
This commit is contained in:
parent
1b052ad16b
commit
fa7b7fcd08
6 changed files with 311 additions and 90 deletions
|
@ -39,6 +39,10 @@ import { missingCaseError } from '../util/missingCaseError';
|
|||
import * as KeyboardLayout from '../services/keyboardLayout';
|
||||
import { useActivateSpeakerViewOnPresenting } from '../hooks/useActivateSpeakerViewOnPresenting';
|
||||
import { CallingAudioIndicator } from './CallingAudioIndicator';
|
||||
import {
|
||||
useActiveCallShortcuts,
|
||||
useKeyboardShortcuts,
|
||||
} from '../hooks/useKeyboardShortcuts';
|
||||
|
||||
export type PropsType = {
|
||||
activeCall: ActiveCallType;
|
||||
|
@ -140,6 +144,9 @@ export const CallScreen: React.FC<PropsType> = ({
|
|||
toggleSpeakerView
|
||||
);
|
||||
|
||||
const activeCallShortcuts = useActiveCallShortcuts(hangUpActiveCall);
|
||||
useKeyboardShortcuts(activeCallShortcuts);
|
||||
|
||||
const toggleAudio = useCallback(() => {
|
||||
setLocalAudio({
|
||||
enabled: !hasLocalAudio,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue