Skip to content
Snippets Groups Projects
Commit 5c30ae16 authored by Karishma Chadha's avatar Karishma Chadha
Browse files

Rename function for clarity.

parent 2ca0d834
No related branches found
No related tags found
No related merge requests found
......@@ -16,17 +16,17 @@ class ModalVideoManager {
}
enableVideo (onPermissionSuccess, afterFrameDraw) {
enableVideo (onPermissionSuccess, onVideoLoaded) {
const thisContext = this;
this._videoProvider.enableVideo(afterFrameDraw).then(() => {
this._videoProvider.enableVideo(onVideoLoaded).then(() => {
if (onPermissionSuccess) onPermissionSuccess();
const ctx = thisContext._canvas.getContext('2d');
ctx.scale(-1, 1);
ctx.translate(thisContext._canvasWidth * -1, 0);
if (afterFrameDraw) {
if (onVideoLoaded) {
thisContext._videoProvider.video.onloadeddata = () => {
afterFrameDraw();
onVideoLoaded();
};
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment