From 9ef6e085c8d864e13882dd5f94051317e7ad9078 Mon Sep 17 00:00:00 2001 From: Chris Adams Date: Thu, 20 Jun 2013 15:17:44 -0400 Subject: [PATCH] viewer.js: update onfullscreenchange handler comment --- src/viewer.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/viewer.js b/src/viewer.js index 05054eff..8232b9fa 100644 --- a/src/viewer.js +++ b/src/viewer.js @@ -631,9 +631,12 @@ $.extend( $.Viewer.prototype, $.EventHandler.prototype, $.ControlDock.prototype, if( $.supportsFullScreen ){ THIS[ this.hash ].onfullscreenchange = function() { - // The event object doesn't carry information about the - // fullscreen state of the browser, but it is possible to - // retrieve it through the fullscreen API + /* + fullscreenchange events don't include the new fullscreen status so we need to + retrieve the current status from the fullscreen API. See: + https://developer.mozilla.org/en-US/docs/Web/Reference/Events/fullscreenchange + */ + if( $.isFullScreen() ){ _this.setFullPage( true ); } else {