Fix bug.
This commit is contained in:
parent
a7a8935946
commit
92f3ffe183
|
@ -58,7 +58,8 @@ class AdBannersController < ApplicationController
|
||||||
"banner-width" => adbanner.width,
|
"banner-width" => adbanner.width,
|
||||||
"base_image" => (base_image - 1),
|
"base_image" => (base_image - 1),
|
||||||
"timeout" => (adbanner.timeout * 1000),
|
"timeout" => (adbanner.timeout * 1000),
|
||||||
"more" => "More"
|
"more" => "More",
|
||||||
|
"desc" => ""
|
||||||
},
|
},
|
||||||
"images" => images
|
"images" => images
|
||||||
}
|
}
|
||||||
|
@ -149,11 +150,13 @@ class AdBannersController < ApplicationController
|
||||||
extra_before_html = ActionController::Base.helpers.stylesheet_link_tag("banner/jplayer.blue.monday.min.css")
|
extra_before_html = ActionController::Base.helpers.stylesheet_link_tag("banner/jplayer.blue.monday.min.css")
|
||||||
extra_after_html = ActionController::Base.helpers.javascript_include_tag("banner/jquery.jplayer.min.js")
|
extra_after_html = ActionController::Base.helpers.javascript_include_tag("banner/jquery.jplayer.min.js")
|
||||||
end
|
end
|
||||||
|
base_image = adbanner.base_image.nil? ? 1 : adbanner.base_image
|
||||||
{
|
{
|
||||||
"extras" => {
|
"extras" => {
|
||||||
"ad_fx" => adbanner.ad_fx,
|
"ad_fx" => adbanner.ad_fx,
|
||||||
"speed" => adbanner.speed,
|
"speed" => adbanner.speed,
|
||||||
"title" => adbanner.title,
|
"title" => adbanner.title,
|
||||||
|
"base_image" => (base_image - 1),
|
||||||
"timeout" => (adbanner.timeout * 1000),
|
"timeout" => (adbanner.timeout * 1000),
|
||||||
"more" => "More",
|
"more" => "More",
|
||||||
"desc" => adbanner.title,
|
"desc" => adbanner.title,
|
||||||
|
|
|
@ -235,7 +235,7 @@ if (typeof onYouTubeIframeAPIReady !== 'function'){
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
function onPlayerStateChange(event){
|
function onPlayerStateChange(event){
|
||||||
var iframe = $(event.target.h),
|
var iframe = $(event.target.getIframe()),
|
||||||
cyclediv = iframe.parents("div.cycle-slideshow");
|
cyclediv = iframe.parents("div.cycle-slideshow");
|
||||||
var widget = cyclediv.parents('.ba-banner-widget-youtube');
|
var widget = cyclediv.parents('.ba-banner-widget-youtube');
|
||||||
if(event.data == YT.PlayerState.PLAYING || event.data == YT.PlayerState.BUFFERING){
|
if(event.data == YT.PlayerState.PLAYING || event.data == YT.PlayerState.BUFFERING){
|
||||||
|
|
Loading…
Reference in New Issue