close to the edge
Member
Sugestion: Only limit the size of the webm if original width/height is larger than the width/height set in option. Could that be an option?
I just tried to hack that in but my Javascript is awful and I don't know how to debug Chrome extensions, so I'm stuck. Here's what I changed:
Code:
if (items.constrainVideos) {
//video.width = items.pixelsWide;
var w = video.width;
video.width = Math.min(w, items.pixelsWide);
}
if (items.constrainVideosHeight) {
//video.style.maxHeight = items.pixelsHigh + 'px';
var h = video.height;
video.style.maxHeight = Math.min(h + 'px', items.pixelsHigh + 'px');
}
edit: It does seem to work for the height, but not the width. I'll play around some more