Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

fix(virtual-background) Remove unused action type VIRTUAL_BACKGROUND_TRACK_CHANGED.

Jaya Allamsetty68f79e52e7d3
diff --git a/react/features/virtual-background/actionTypes.ts b/react/features/virtual-background/actionTypes.ts
index 3124340d23..1b0ff1d1f2 100644
--- a/react/features/virtual-background/actionTypes.ts
+++ b/react/features/virtual-background/actionTypes.ts
@@ -23,13 +23,3 @@ export const BACKGROUND_ENABLED = 'BACKGROUND_ENABLED';
* }}
*/
export const SET_VIRTUAL_BACKGROUND = 'SET_VIRTUAL_BACKGROUND';
-
-/**
- * The type which signals if the local track was changed due to a changes of the virtual background.
- *
- * @returns {{
- * type: VIRTUAL_BACKGROUND_TRACK_CHANGED
- *}}
- */
-
-export const VIRTUAL_BACKGROUND_TRACK_CHANGED = 'VIRTUAL_BACKGROUND_TRACK_CHANGED';
diff --git a/react/features/virtual-background/actions.ts b/react/features/virtual-background/actions.ts
index d1ef6699f8..af4ed4fc96 100644
--- a/react/features/virtual-background/actions.ts
+++ b/react/features/virtual-background/actions.ts
@@ -3,7 +3,7 @@ import { IStore } from '../app/types';
// @ts-ignore
import { createVirtualBackgroundEffect } from '../stream-effects/virtual-background';
-import { BACKGROUND_ENABLED, SET_VIRTUAL_BACKGROUND, VIRTUAL_BACKGROUND_TRACK_CHANGED } from './actionTypes';
+import { BACKGROUND_ENABLED, SET_VIRTUAL_BACKGROUND } from './actionTypes';
import logger from './logger';
import { VirtualBackgroundOptions } from './types';
@@ -73,16 +73,3 @@ export function backgroundEnabled(backgroundEffectEnabled: boolean) {
backgroundEffectEnabled
};
}
-
-/**
- * Signals if the local track was changed due to a changes of the virtual background.
- *
- * @returns {{
- * type: VIRTUAL_BACKGROUND_TRACK_CHANGED
- * }}
- */
-export function virtualBackgroundTrackChanged() {
- return {
- type: VIRTUAL_BACKGROUND_TRACK_CHANGED
- };
-}
diff --git a/react/features/virtual-background/components/VirtualBackgroundDialog.tsx b/react/features/virtual-background/components/VirtualBackgroundDialog.tsx
index f841483558..77fdf85a92 100644
--- a/react/features/virtual-background/components/VirtualBackgroundDialog.tsx
+++ b/react/features/virtual-background/components/VirtualBackgroundDialog.tsx
@@ -26,7 +26,7 @@ import { Tooltip } from '../../base/tooltip';
// @ts-ignore
import { getLocalVideoTrack } from '../../base/tracks';
// @ts-ignore
-import { toggleBackgroundEffect, virtualBackgroundTrackChanged } from '../actions';
+import { toggleBackgroundEffect } from '../actions';
import { BACKGROUNDS_LIMIT, IMAGES, type Image, VIRTUAL_BACKGROUND_TYPE } from '../constants';
// @ts-ignore
import { toDataURL } from '../functions';
@@ -439,7 +439,6 @@ function VirtualBackground({
dispatch(hideDialog());
logger.info(`Virtual background type: '${typeof options.backgroundType === 'undefined'
? 'none' : options.backgroundType}' applied!`);
- dispatch(virtualBackgroundTrackChanged());
}, [ dispatch, options, _localFlipX ]);
// Prevent the selection of a new virtual background if it has not been applied by default