Add media subtype & fix resizing
This commit is contained in:
@@ -325,12 +325,12 @@
|
||||
if((this.videoWidth > maxVideoWidth) || (this.videoHeight > maxVideoHeight)) {
|
||||
if ((this.videoWidth / maxVideoWidth) > (this.videoHeight / maxVideoHeight)) {
|
||||
videoWidth = maxVideoWidth;
|
||||
videoHeight = parseInt(this.videoHeight / (this.videoWidth / videoWidth), 10);
|
||||
videoHeight = Math.round(this.videoHeight / (this.videoWidth / videoWidth));
|
||||
$This.width(videoWidth);
|
||||
$This.height(videoHeight);
|
||||
} else {
|
||||
videoHeight = maxVideoHeight;
|
||||
videoWidth = parseInt(this.videoWidth / (this.videoHeight / videoHeight), 10);
|
||||
videoWidth = Math.round(this.videoWidth / (this.videoHeight / videoHeight));
|
||||
$This.width(videoWidth);
|
||||
$This.height(videoHeight);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user