Browse Source

make sure stretch works with video

embed
Hakim El Hattab 11 years ago
parent
commit
0a021845df
  1. 4
      js/reveal.js
  2. 4
      js/reveal.min.js

4
js/reveal.js

@ -1081,8 +1081,8 @@ var Reveal = (function(){
// Consider the aspect ratio of media elements // Consider the aspect ratio of media elements
if( /(img|video)/gi.test( element.nodeName ) ) { if( /(img|video)/gi.test( element.nodeName ) ) {
var nw = element.naturalWidth, var nw = element.naturalWidth || element.videoWidth,
nh = element.naturalHeight; nh = element.naturalHeight || element.videoHeight;
var es = Math.min( width / nw, remainingHeight / nh ); var es = Math.min( width / nw, remainingHeight / nh );

4
js/reveal.min.js

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save