Disconnect other connected devices (of the same user) when joining an Element call (#9379)
This commit is contained in:
parent
ba5bd74ac8
commit
54008cff58
7 changed files with 160 additions and 20 deletions
|
@ -30,7 +30,7 @@ import {
|
|||
LiveContentSummaryWithCall,
|
||||
LiveContentType,
|
||||
} from "../components/views/rooms/LiveContentSummary";
|
||||
import { useCall, useJoinCallButtonDisabledTooltip } from "../hooks/useCall";
|
||||
import { useCall, useJoinCallButtonDisabled, useJoinCallButtonTooltip } from "../hooks/useCall";
|
||||
import { useRoomState } from "../hooks/useRoomState";
|
||||
import { ButtonEvent } from "../components/views/elements/AccessibleButton";
|
||||
import { useDispatcher } from "../hooks/useDispatcher";
|
||||
|
@ -45,12 +45,13 @@ interface JoinCallButtonWithCallProps {
|
|||
}
|
||||
|
||||
function JoinCallButtonWithCall({ onClick, call }: JoinCallButtonWithCallProps) {
|
||||
const tooltip = useJoinCallButtonDisabledTooltip(call);
|
||||
const tooltip = useJoinCallButtonTooltip(call);
|
||||
const disabled = useJoinCallButtonDisabled(call);
|
||||
|
||||
return <AccessibleTooltipButton
|
||||
className="mx_IncomingCallToast_joinButton"
|
||||
onClick={onClick}
|
||||
disabled={Boolean(tooltip)}
|
||||
disabled={disabled}
|
||||
tooltip={tooltip}
|
||||
kind="primary"
|
||||
>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue