From 6933a3b807e1f51f25b907aee73e22732fb3fc4c Mon Sep 17 00:00:00 2001 From: Yanzhen Yu Date: Sun, 5 Apr 2020 22:31:47 +0800 Subject: [PATCH] use player dimension to calc scale when fullscreen --- src/Player.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Player.html b/src/Player.html index 0117dd38..4872eab0 100644 --- a/src/Player.html +++ b/src/Player.html @@ -101,8 +101,8 @@ this._width = width; this._height = height; const dimension = { - width: document.body.offsetWidth, - height: document.body.offsetHeight - controllerHeight, + width: this.refs.player.offsetWidth, + height: this.refs.player.offsetHeight - controllerHeight, }; this.set(dimension); this.updateScale(replayer.wrapper, {