mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2025-12-30 11:22:31 +00:00
fix(shared-video): Removes disable pointer for non moderators. (#15399)
* fix(shared-video): Removes disable pointer for non moderators. It fixes an issue where people can see ads from YouTube, allowing them to click the Skip Ad button. If you by mistake pause, the next time sync will unpuase it. * squash: Remove unused.
This commit is contained in:
@@ -4,7 +4,6 @@ import { connect } from 'react-redux';
|
||||
// @ts-expect-error
|
||||
import Filmstrip from '../../../../../modules/UI/videolayout/Filmstrip';
|
||||
import { IReduxState } from '../../../app/types';
|
||||
import { getLocalParticipant } from '../../../base/participants/functions';
|
||||
import { getVerticalViewMaxWidth } from '../../../filmstrip/functions.web';
|
||||
import { getToolboxHeight } from '../../../toolbox/functions.web';
|
||||
import { isSharedVideoEnabled } from '../../functions';
|
||||
@@ -39,11 +38,6 @@ interface IProps {
|
||||
*/
|
||||
isEnabled: boolean;
|
||||
|
||||
/**
|
||||
* Is the video shared by the local user.
|
||||
*/
|
||||
isOwner: boolean;
|
||||
|
||||
/**
|
||||
* Whether or not the user is actively resizing the filmstrip.
|
||||
*/
|
||||
@@ -124,17 +118,15 @@ class SharedVideo extends Component<IProps> {
|
||||
* @returns {React$Element}
|
||||
*/
|
||||
render() {
|
||||
const { isEnabled, isOwner, isResizing } = this.props;
|
||||
const { isEnabled, isResizing } = this.props;
|
||||
|
||||
if (!isEnabled) {
|
||||
return null;
|
||||
}
|
||||
|
||||
const className = !isResizing && isOwner ? '' : 'disable-pointer';
|
||||
|
||||
return (
|
||||
<div
|
||||
className = { className }
|
||||
className = { (isResizing && 'disable-pointer') || '' }
|
||||
id = 'sharedVideo'
|
||||
style = { this.getDimensions() }>
|
||||
{this.getManager()}
|
||||
@@ -152,19 +144,16 @@ class SharedVideo extends Component<IProps> {
|
||||
* @returns {IProps}
|
||||
*/
|
||||
function _mapStateToProps(state: IReduxState) {
|
||||
const { ownerId, videoUrl } = state['features/shared-video'];
|
||||
const { videoUrl } = state['features/shared-video'];
|
||||
const { clientHeight, clientWidth } = state['features/base/responsive-ui'];
|
||||
const { visible, isResizing } = state['features/filmstrip'];
|
||||
|
||||
const localParticipant = getLocalParticipant(state);
|
||||
|
||||
return {
|
||||
clientHeight,
|
||||
clientWidth,
|
||||
filmstripVisible: visible,
|
||||
filmstripWidth: getVerticalViewMaxWidth(state),
|
||||
isEnabled: isSharedVideoEnabled(state),
|
||||
isOwner: ownerId === localParticipant?.id,
|
||||
isResizing,
|
||||
videoUrl
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user