mirror of
https://github.com/videojs/video.js.git
synced 2024-11-28 08:58:46 +02:00
Merge branch 'feature/independent-full-window'
This commit is contained in:
commit
9b881cdf13
@ -1,3 +1,4 @@
|
||||
* Made full-window mode more independent
|
||||
* Added rakefile for release generation
|
||||
--------------------------------------------------------------------------------
|
||||
^ ADD NEW CHANGES ABOVE ^
|
||||
|
@ -539,7 +539,7 @@ _V_.Player = _V_.Component.extend({
|
||||
},
|
||||
|
||||
enterFullWindow: function(){
|
||||
this.videoIsFullScreen = true;
|
||||
this.videoIsFullWindow = true;
|
||||
|
||||
// Storing original doc overflow value to return to when fullscreen is off
|
||||
this.docOrigOverflow = document.documentElement.style.overflow;
|
||||
@ -559,12 +559,16 @@ _V_.Player = _V_.Component.extend({
|
||||
|
||||
fullWindowOnEscKey: function(event){
|
||||
if (event.keyCode == 27) {
|
||||
this.cancelFullScreen();
|
||||
if (this.videoIsFullScreen == true) {
|
||||
this.cancelFullScreen();
|
||||
} else {
|
||||
this.exitFullWindow();
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
exitFullWindow: function(){
|
||||
this.videoIsFullScreen = false;
|
||||
this.videoIsFullWindow = false;
|
||||
_V_.removeEvent(document, "keydown", this.fullWindowOnEscKey);
|
||||
|
||||
// Unhide scroll bars.
|
||||
|
Loading…
Reference in New Issue
Block a user