From 006f0b00c602e592378c1452cb7243a6759759e4 Mon Sep 17 00:00:00 2001 From: David Baker Date: Tue, 20 Oct 2015 18:23:27 +0100 Subject: [PATCH] Try refing the container using a functiob as it currently seems to be endinh up with no refs some of the time --- src/skins/vector/views/molecules/voip/VideoView.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/skins/vector/views/molecules/voip/VideoView.js b/src/skins/vector/views/molecules/voip/VideoView.js index d590d1befd..196e1d6c53 100644 --- a/src/skins/vector/views/molecules/voip/VideoView.js +++ b/src/skins/vector/views/molecules/voip/VideoView.js @@ -38,13 +38,17 @@ module.exports = React.createClass({ return this.refs.local.getDOMNode(); }, + setContainer: function(c) { + this.container = c; + }, + onAction: function(payload) { switch (payload.action) { case 'video_fullscreen': - if (!this.refs.container) { + if (!this.container) { return; } - var element = this.refs.container.getDOMNode(); + var element = this.container.getDOMNode(); var requestMethod = element.requestFullScreen || element.webkitRequestFullScreen || element.mozRequestFullScreen || element.msRequestFullscreen; requestMethod.call(element); break; @@ -54,7 +58,7 @@ module.exports = React.createClass({ render: function() { var VideoFeed = sdk.getComponent('atoms.voip.VideoFeed'); return ( -
+