mirror of
https://github.com/element-hq/element-web.git
synced 2024-12-16 19:05:23 +03:00
Add ref to callViewWrapper
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
parent
76f503666c
commit
2c9231641b
1 changed files with 8 additions and 2 deletions
|
@ -15,7 +15,7 @@ See the License for the specific language governing permissions and
|
|||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import React, { createRef } from 'react';
|
||||
|
||||
import CallView from "./CallView";
|
||||
import RoomViewStore from '../../../stores/RoomViewStore';
|
||||
|
@ -122,6 +122,8 @@ export default class CallPreview extends React.Component<IProps, IState> {
|
|||
};
|
||||
}
|
||||
|
||||
private callViewWrapper = createRef<HTMLDivElement>();
|
||||
|
||||
private initX = 0;
|
||||
private initY = 0;
|
||||
private lastX = DEFAULT_X_OFFSET;
|
||||
|
@ -230,7 +232,11 @@ export default class CallPreview extends React.Component<IProps, IState> {
|
|||
};
|
||||
|
||||
return (
|
||||
<div className="mx_CallPreview" style={style}>
|
||||
<div
|
||||
className="mx_CallPreview"
|
||||
style={style}
|
||||
ref={this.callViewWrapper}
|
||||
>
|
||||
<CallView
|
||||
call={this.state.primaryCall}
|
||||
secondaryCall={this.state.secondaryCall}
|
||||
|
|
Loading…
Reference in a new issue