You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

actions.ts 635B

123456789101112131415161718192021
  1. import { openDialog } from '../base/dialog/actions';
  2. // @ts-ignore
  3. import { DesktopPicker } from './components';
  4. /**
  5. * Signals to open a dialog with the DesktopPicker component.
  6. *
  7. * @param {Object} options - Desktop sharing settings.
  8. * @param {Function} onSourceChoose - The callback to invoke when
  9. * a DesktopCapturerSource has been chosen.
  10. * @returns {Object}
  11. */
  12. export function showDesktopPicker(options: { desktopSharingSources?: any; } = {}, onSourceChoose: Function) {
  13. const { desktopSharingSources } = options;
  14. return openDialog(DesktopPicker, {
  15. desktopSharingSources,
  16. onSourceChoose
  17. });
  18. }