Browse Source

#1439 Timeline: video iframe isn't resized properly in Safari

Alex Trofimov 8 years ago
parent
commit
fffa64a0e9
1 changed files with 7 additions and 1 deletions
  1. 7 1
      modules/boonex/timeline/js/view.js

+ 7 - 1
modules/boonex/timeline/js/view.js

@@ -145,6 +145,12 @@ BxTimelineView.prototype.initVideosAutoplay = function(oParent) {
 		if($this._sVideosAutoplay == 'on_mute')
 			oPlayer.mute();
 
+        var fFixHeight = function () {
+            $('#' + sPlayer).height(($('#' + sPlayer).contents().find('video').height()) + 'px');
+        };
+        oPlayer.on('ready', fFixHeight);
+        oPlayer.on('play', fFixHeight);
+        
 		$this._oVapPlayers[sPlayer] = oPlayer;
 	});
 };
@@ -480,7 +486,7 @@ BxTimelineView.prototype.onEditPost = function(oData) {
     this.loadingInItem(oItem, false);
 
 	if(oData && oData.form != undefined && oData.form_id != undefined) {
-		console.log(oItem, oItem.find('.' + this.sClassItemContent));
+		
 		oItem.find('.' + this.sClassItemContent).bx_anim('hide', this._sAnimationEffect, this._iAnimationSpeed, function() {
             $(this).html(oData.form).bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed, function() {
             	$this.initFormEdit(oData.form_id);