Authored by whb

修改视频高度

... ... @@ -204,6 +204,20 @@ define('mobile', function(require, exports) {
tweetText: '【YOHOOD 2015】' + detailTitle.text(),
qqText: '【YOHOOD 2015】' + detailTitle.text() + '#YOHOOD 2015'
});
var videoSize = $("video").size();
var videoPos = 0;
if(videoSize > 0) {
var videoInterval = setInterval(
function() {
$("video").each(function() { //设置视频高度
if($(this)[0].videoHeight > 0) {
$(this).css({"height": Math.floor($(this)[0].videoHeight * (300 / $(this)[0].videoWidth)) });
videoPos++;
}
});
if(videoPos >= videoSize) clearInterval(videoInterval);
}, 20);
}
};
exports.show = function() {
... ...