Refactor screen share picker internals

This commit is contained in:
Fedor Indutny
2024-09-19 18:03:44 -07:00
committed by GitHub
parent 855b1c03b0
commit d0b8a2991f
25 changed files with 547 additions and 244 deletions

View File

@@ -1,6 +1,7 @@
// Copyright 2020 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
import type { ReadonlyDeep } from 'type-fest';
import type { AudioDevice, Reaction as CallReaction } from '@signalapp/ringrtc';
import type { ConversationType } from '../state/ducks/conversations';
import type { AciString, ServiceIdString } from './ServiceId';
@@ -19,13 +20,13 @@ export enum CallViewMode {
Presentation = 'Presentation',
}
export type PresentableSource = {
export type PresentableSource = ReadonlyDeep<{
appIcon?: string;
id: string;
name: string;
isScreen: boolean;
thumbnail: string;
};
}>;
export type PresentedSource = {
id: string;
@@ -54,7 +55,7 @@ export type ActiveCallBaseType = {
outgoingRing: boolean;
pip: boolean;
presentingSource?: PresentedSource;
presentingSourcesAvailable?: Array<PresentableSource>;
presentingSourcesAvailable?: ReadonlyArray<PresentableSource>;
settingsDialogOpen: boolean;
showNeedsScreenRecordingPermissionsWarning?: boolean;
showParticipantsList: boolean;