Put call on hold when transfer dialog is opened (#7669)
And take it off hold if the dialog is cancelled. Also changes the onFinished signature of invitedialog which claimed to return an array of strings but never did, so now it just returns a boolean.
This commit is contained in:
parent
b04d2de313
commit
7c20eb9b74
3 changed files with 30 additions and 15 deletions
|
@ -21,8 +21,6 @@ import { MatrixCall } from 'matrix-js-sdk/src/webrtc/call';
|
|||
import { _t } from '../../../languageHandler';
|
||||
import ContextMenu, { IProps as IContextMenuProps, MenuItem } from '../../structures/ContextMenu';
|
||||
import CallHandler from '../../../CallHandler';
|
||||
import InviteDialog, { KIND_CALL_TRANSFER } from '../dialogs/InviteDialog';
|
||||
import Modal from '../../../Modal';
|
||||
import { replaceableComponent } from "../../../utils/replaceableComponent";
|
||||
|
||||
interface IProps extends IContextMenuProps {
|
||||
|
@ -52,10 +50,7 @@ export default class CallContextMenu extends React.Component<IProps> {
|
|||
};
|
||||
|
||||
onTransferClick = () => {
|
||||
Modal.createTrackedDialog(
|
||||
'Transfer Call', '', InviteDialog, { kind: KIND_CALL_TRANSFER, call: this.props.call },
|
||||
/*className=*/"mx_InviteDialog_transferWrapper", /*isPriority=*/false, /*isStatic=*/true,
|
||||
);
|
||||
CallHandler.instance.showTransferDialog(this.props.call);
|
||||
this.props.onFinished();
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue