2023-07-14 12:09:12 +02:00
|
|
|
/*
|
2024-09-06 17:56:18 +01:00
|
|
|
Copyright 2023, 2024 New Vector Ltd.
|
2023-07-14 12:09:12 +02:00
|
|
|
|
2024-09-06 17:56:18 +01:00
|
|
|
SPDX-License-Identifier: AGPL-3.0-only OR GPL-3.0-only
|
|
|
|
Please see LICENSE files in the repository root for full details.
|
2023-07-14 12:09:12 +02:00
|
|
|
*/
|
|
|
|
|
|
|
|
import { Streams } from "electron";
|
|
|
|
|
|
|
|
type DisplayMediaCallback = (streams: Streams) => void;
|
|
|
|
|
|
|
|
let displayMediaCallback: DisplayMediaCallback | null;
|
|
|
|
|
|
|
|
export const getDisplayMediaCallback = (): DisplayMediaCallback | null => {
|
|
|
|
return displayMediaCallback;
|
|
|
|
};
|
|
|
|
|
|
|
|
export const setDisplayMediaCallback = (callback: DisplayMediaCallback | null): void => {
|
|
|
|
displayMediaCallback = callback;
|
|
|
|
};
|