Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
bsorrentino committed Aug 3, 2021
1 parent 629d976 commit 70d9ceb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -1156,7 +1156,7 @@ GA.plugins = function(ga) {
//Sine
sine: function(x) {return Math.sin(x * Math.PI / 2);},
sineSquared: function(x) {return Math.pow(Math.sin(x * Math.PI / 2), 2);},
sineCubed: function(x) {return Math.pow(Math.sin(x * Math.PI / 2), 2);},
sineCubed: function(x) {return Math.pow(Math.sin(x * Math.PI / 2), 3);},
inverseSine: function(x) {return 1 - Math.sin((1 - x) * Math.PI / 2);},
inverseSineSquared: function(x) {return 1 - Math.pow(Math.sin((1 - x) * Math.PI / 2), 2);},
inverseSineCubed: function(x) {return 1 - Math.pow(Math.sin((1 - x) * Math.PI / 2), 3);},
Expand Down Expand Up @@ -4556,15 +4556,15 @@ GA.plugins = function(ga) {
//`requestFullscreen` is used by `enableFullscreen` to launch
//fullscreen mode.
ga.requestFullScreen = function() {
if (!document.fullscreenEnabled) {
if (document.fullscreenEnabled && document.fullscreenElement !== null) {
ga.canvas.requestFullscreen();
}
};

//`exitFullscreen` is used by `enableFullscreen` to exit
//fullscreen mode.
ga.exitFullScreen = function() {
if (document.fullscreenEnabled) {
if (document.fullscreenEnabled && document.fullscreenElement === null) {
document.exitFullscreen();
}
};
Expand Down

0 comments on commit 70d9ceb

Please sign in to comment.