', {href: asPost.pic_path, 'data-video': (bVideo?'true':'false'), 'data-lightbox': 'post-pictures', 'data-title': (bVideo?'Vidéo':'Photo')+' ajoutée le '+sAbsTime+sTakenOn, 'data-orientation': asPost.rotate}).append($Image);
break;
case 'post':
$Body = $('')
diff --git a/script/lightbox.js b/script/lightbox.js
index f0c81ee..bce8efc 100644
--- a/script/lightbox.js
+++ b/script/lightbox.js
@@ -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);
}