/* 2012-05-13 16:40 */
(function(a) {
    a.hotkeys = {
        version: "0.8",
        specialKeys: {
            8 : "backspace",
            9 : "tab",
            13 : "return",
            16 : "shift",
            17 : "ctrl",
            18 : "alt",
            19 : "pause",
            20 : "capslock",
            27 : "esc",
            32 : "space",
            33 : "pageup",
            34 : "pagedown",
            35 : "end",
            36 : "home",
            37 : "left",
            38 : "up",
            39 : "right",
            40 : "down",
            45 : "insert",
            46 : "del",
            96 : "0",
            97 : "1",
            98 : "2",
            99 : "3",
            100 : "4",
            101 : "5",
            102 : "6",
            103 : "7",
            104 : "8",
            105 : "9",
            106 : "*",
            107 : "+",
            109 : "-",
            110 : ".",
            111 : "/",
            112 : "f1",
            113 : "f2",
            114 : "f3",
            115 : "f4",
            116 : "f5",
            117 : "f6",
            118 : "f7",
            119 : "f8",
            120 : "f9",
            121 : "f10",
            122 : "f11",
            123 : "f12",
            144 : "numlock",
            145 : "scroll",
            191 : "/",
            224 : "meta"
        },
        shiftNums: {
            "`": "~",
            "1": "!",
            "2": "@",
            "3": "#",
            "4": "$",
            "5": "%",
            "6": "^",
            "7": "&",
            "8": "*",
            "9": "(",
            "0": ")",
            "-": "_",
            "=": "+",
            ";": ": ",
            "'": '"',
            ",": "<",
            ".": ">",
            "/": "?",
            "\\": "|"
        }
    };
    function b(b) {
        if (typeof b.data !== "string") return;
        var d = b.handler,
        c = b.data.toLowerCase().split(" ");
        b.handler = function(b) {
            if (this !== b.target && (/textarea|select/i.test(b.target.nodeName) || b.target.type === "text")) return;
            var f = b.type !== "keypress" && a.hotkeys.specialKeys[b.which],
            h = String.fromCharCode(b.which).toLowerCase(),
            k,
            e = "",
            g = {};
            if (b.altKey && f !== "alt") e += "alt+";
            if (b.ctrlKey && f !== "ctrl") e += "ctrl+";
            if (b.metaKey && !b.ctrlKey && f !== "meta") e += "meta+";
            if (b.shiftKey && f !== "shift") e += "shift+";
            if (f) g[e + f] = true;
            else {
                g[e + h] = true;
                g[e + a.hotkeys.shiftNums[h]] = true;
                if (e === "shift+") g[a.hotkeys.shiftNums[h]] = true
            }
            for (var i = 0,
            j = c.length; i < j; i++) if (g[c[i]]) return d.apply(this, arguments)
        }
    }
    a.each(["keydown", "keyup", "keypress"],
    function() {
        a.event.special[this] = {
            add: b
        }
    })
})(jQuery);
var getQuery = function(a) {
    hu = window.location.search.substring(1).toLowerCase();
    gy = hu.split("&");
    for (i = 0; i < gy.length; i++) {
        ft = gy[i].split("=");
        if (ft[0] == a) return ft[1]
    }
};
I567dm.player = {};
var nextPage = I567dm.next == "0" ? "": "",
prevPage = I567dm.prev == "0" ? "": "",
isMid = function() {
    return /(iPhone|iPad|iPod|Android)/ig.test(navigator.userAgent)
} ();
I567dm.player.float = function() {
    if (this.setting.float.show === true) {
        $("#I567dm_float").html('<iframe src="' + this.setting.float.url + '" width="' + this.setting.size.w + '" height="' + this.setting.size.h + '" scrolling="no" frameborder="0"></iframe>').show();
        setTimeout(function() {
            $("#I567dm_float").remove()
        },
        this.setting.float.delay)
    }
};
I567dm.player.shade = function() {
    var a = this;
    a.setting.shade.show === true && setTimeout(function() {
        $("#lshade,#rshade").fadeTo(200, a.setting.shade.opacity);
        var b;
        $("#mleft,#mright").hover(function() {
            $("#lshade,#rshade").hide()
        },
        function() {
            b && clearTimeout(b);
            b = setTimeout(function() {
                $("#lshade,#rshade").fadeTo(200, a.setting.shade.opacity)
            },
            200)
        })
    },
    a.setting.shade.delay)
};
I567dm.player.wide = function(b) {
    if (this.setting.wide.show === true) {
        var a = this.setting.wide;
        if (b != "") window.setTimeout(function() {
            $("#wide").removeAttr("disabled").unbind("click").toggle(function() {
                I567dm.player.setWide(true)
            },
            function() {
                I567dm.player.setWide(false)
            })
        },
        a.delay);
        else $("#wide").click(function() {
            alert("此播放器不支持宽屏显示");
            return false
        })
    }
};
var wideStatus = 0;
I567dm.player.setWide = function(a) {
    if (a == true) {
        $("#mleft,#mright").hide();
        $("#player").width("980px");
        $("#wide").text("窄屏");
        wideStatus = 1
    } else {
        $("#mleft,#mright").show();
        $("#player").width("644px");
        $("#wide").text("宽屏");
        wideStatus = 1
    }
};
I567dm.player.nav = {
    local: "http://" + self.location.host + self.location.pathname,
    title: I567dm.vt + "_" + I567dm.pt,
    addFav: function() {
        var b = this.local + "?fav",
        a = navigator.userAgent.toLowerCase().indexOf("mac") != -1 ? "Command/Cmd": "CTRL";
        try {
            if (document.all) window.external.addFavorite(b, this.title + "_动漫456");
            else if (window.sidebar) window.sidebar.addPanel(this.title + "_动漫456", b, "");
            else alert("您可以尝试通过快捷键" + a + " + D 加入到收藏夹!")
        } catch(c) {
            alert("您可以尝试通过快捷键" + a + " + D 加入到收藏夹!")
        }
        return false
    },
    copyUrl: function() {
        var b = "耶！复制成功喽！你可以粘贴在QQ消息里送给你的好朋友呀！再次感谢您对本站的支持哦！",
        a = this.local + "\n这个是我很喜欢的动画片：" + this.title + "，真诚向你推荐，希望你也会喜欢哦!";
        if (document.all) $("#copyUrl").bind("click",
        function() {
            window.clipboardData.setData("Text", a);
            alert(b)
        });
        else jQuery.getScript("/scripts/ZeroClipboard.js",
        function() {
            var c = new ZeroClipboard.Client;
            c.setHandCursor(true);
            c.addEventListener("mouseOver",
            function() {
                c.setText(a)
            });
            c.addEventListener("complete",
            function() {
                alert(b)
            });
            c.glue("copyUrl")
        })
    },
    bind: function() {
        var a = this;
        $("#addFav").click(function() {
            a.addFav()
        });
        a.copyUrl();
        $(document).bind("keydown", "a",
        function() {
            $("#prev").click()
        }).bind("keydown", "d",
        function() {
            $("#next").click()
        })
    }
};
I567dm.history.add(I567dm);
I567dm.player.data = {
    setting: {
        found: false,
        rowMax: 8,
        rowLen: [8, 5, 4],
        cssNames: ["plist pnormal", "plist pmedium", "plist plong"],
        plist: {}
    },
    cache: [],
    format: function(a) {
        var b = [],
        h = this.setting.cssNames[this.setting.plist.data[a].lenType],
        f = false;
        if (this.setting.rowMax * this.setting.rowLen[this.setting.plist.data[a].lenType] < this.setting.plist.data[a].count) {
            f = true;
            h += " list_max"
        }
        b.push('<div class="extend"><div class="eTip">');
        b.push(I567dm.listTip.get(this.setting.plist.data[a].player, 0));
        b.push("</div>");
        b.push('<div class="pa tr order">');
        b.push('排序：<a id="desc_' + a + '" class="desc desc_on" href="javascript:void(0);" onclick="I567dm.player.data.orderBy(1,' + a + ',this)">降序</a><em>|</em><a id="asc_' + a + '" href="javascript:void(0);" class="asc" onclick="I567dm.player.data.orderBy(0,' + a + ',this)">升序</a>');
        f && b.push('<em>|</em><span class="collapse"><a href="javascript:void(0);" onclick="I567dm.player.data.collapse(this,' + a + ')">展开</a></span>');
        b.push("</div></div>");
        b.push('<div id="plist_' + a + '" class="' + h + '"><ul>');
        for (var j = 0,
        e = this.setting.plist.data[a].list.split("$"), d = 0, k = e.length; d < k; d++) {
            var g = "",
            c = "";
            if (j < this.setting.plist.data[a].latest) {
                g = '<img src="/n.gif" />';
                c = ' class="new'
            }
            if (!this.setting.found && this.setting.plist.pid == e[d]) {
                if (c == "") c = ' class="on" ';
                else c += ' on" ';
                c += ' id="current" rel="' + a + '" ';
                this.setting.found = true
            } else if (c != "") c += '" ';
            b.push('<li><a href="' + e[d] + '.html" ' + c + 'title="' + e[++d] + '">' + e[d] + g + "</a></li>\n");
            j++
        }
        var i = this.setting.rowLen[this.setting.plist.data[a].lenType] - this.setting.plist.data[a].count % this.setting.rowLen[this.setting.plist.data[a].lenType];
        if (i < this.setting.rowLen[this.setting.plist.data[a].lenType]) for (var d = 0; d < i; d++) b.push('<li class="fix"></li>\n');
        b.push('<li class="last"></li>\n');
        b.push("</ul></div></div>");
        return b.join("")
    },
    init: function(d) {
        this.setting.plist = d;
        for (var a = this,
        c = [], b = 0; b < this.setting.plist.len; b++) c.push('<div class="episode" id="episode_' + b + '"></div>');
        $("#plist").html(c.join(""));
        this.show(this.setting.plist.index);
        setTimeout(function() {
            a.position()
        },
        200);
        this.tabsBind();
        $("#plist .episode").eq(a.setting.plist.index).bind("dblclick",
        function() {
            setTimeout(function() {
                a.position()
            },
            200)
        });
        $("#return").bind("click",
        function() {
            a.tabsSwitch(a.setting.plist.index);
            setTimeout(function() {
                a.position()
            },
            200)
        })
    },
    show: function(a) {
        $("#sloading").show();
        if (!this.cache[a]) {
            $("#episode_" + a).html(this.format(a));
            this.cache[a] = true
        }
        setTimeout(function() {
            $("#sloading").hide();
            $("#episode_" + a).show()
        },
        50)
    },
    position: function() {
        var a = $("#current").attr("rel");
        a && $("#plist_" + a).scrollTop($("#current").position().top + $("#plist_" + a).scrollTop() - $("#plist_" + a).position().top - 44)
    },
    tabsSwitch: function(a) {
        $("#ptab li").removeClass("on");
        $("#ptab li").eq(a).addClass("on");
        $("#plist .episode").hide();
        this.show(a)
    },
    tabsBind: function() {
        var a = this;
        $("#ptab li")[this.setting.plist.index].className = "on";
        $("#ptab li").click(function() {
            var b = $(this).attr("tab");
            a.tabsSwitch(b)
        })
    },
    orderBy: function(e, a, c) {
        if (c.className.indexOf("_on") == -1) {
            if (e == 0) {
                document.getElementById("desc_" + a).className = "desc";
                c.className = "asc asc_on"
            } else {
                document.getElementById("asc_" + a).className = "asc";
                c.className = "desc desc_on"
            }
            var b = document.getElementById("plist_" + a).getElementsByTagName("ul")[0].innerHTML.toLowerCase().split("</li>"),
            d = b.length - $("#plist_" + a).find("li[class]").length;
            document.getElementById("plist_" + a).innerHTML = "<ul>" + b.slice(0, d - 1).reverse().join("</li> ") + "</li>" + b.slice(d - 1).join("</li> ") + "</ul>"
        }
    },
    collapse: function(a, b) {
        if (a.className == "") {
            a.className = "on";
            $("#plist_" + b).removeClass("list_max");
            a.innerHTML = "折叠"
        } else {
            a.className = "";
            $("#plist_" + b).addClass("list_max");
            a.innerHTML = "展开"
        }
    }
};
I567dm.player.lighter = {
    closed: false,
    speed: 200,
    opacity: "0.95",
    height: 0,
    timer: null,
    show: true,
    Close: function() {
        if (this.height === 0) {
            this.heigth = 1;
            $("#light").height($(document).height())
        }
        var a = this;
        $("#lighter").addClass("close").text("开灯");
        $("#topper").css("z-index", "10");
        $("#light").fadeTo(this.speed, a.opacity,
        function() {
            a.closed = true;
            $(document).bind("keydown", "esc",
            function() {
                a.Open()
            });
            $(this).dblclick(function() {
                a.Open()
            });
            $(this).mousemove(function() {
                if (a.show === false) {
                    $("#lighter").show();
                    a.show = true
                }
                a.timer && clearTimeout(a.timer);
                a.timer = setTimeout(function() {
                    $("#lighter").hide();
                    a.show = false
                },
                3e3)
            })
        })
    },
    Open: function() {
        var a = this;
        $("#light").fadeOut(this.speed,
        function() {
            a.timer && clearTimeout(a.timer);
            a.closed = false;
            $(this).unbind("dblclick mousemove");
            $("#lighter").removeClass("close").text("关灯").show();
            $("#topper").css("z-index", "1000")
        })
    },
    bind: function() {
        var a = this;
        $("#lighter").bind("click",
        function() {
            a.closed == false ? a.Close() : a.Open()
        })
    }
};
I567dm.player.report = {
    setting: {
        width: 460,
        height: 330
    },
    init: false,
    position: function() {
        var a = $("#playerBox").position(),
        b = (980 - this.setting.width) / 2 + a.left,
        c = (520 - this.setting.height) / 2 + a.top;
        $("#reportBox").css({
            left: b + "px",
            top: c + "px"
        });
        playPage == true && $("#reportBoxBG").css({
            left: b + "px",
            top: c + "px"
        })
    },
    boxBG: {
        appended: false,
        append: function() {
            if (playPage == true && this.appended == false) {
                $("#reportBox").before('<iframe class="reportBoxBG" id="reportBoxBG" frameborder="0" scrolling="no"></iframe>');
                this.appended = true
            }
        },
        show: function() {
            playPage == true && $("#reportBoxBG").show()
        },
        hide: function() {
            playPage == true && $("#reportBoxBG").hide()
        }
    },
    Open: function() {
        if (this.init == false) {
            var d = ["视频不能正常播放", "视频内容不健康", "视频要更新了", "剧集顺序或内容有误", "其它原因"],
            a = [];
            a.push('<h4><span class="reportClose" title="关闭窗口">关闭</span>报错/举报</h4>');
            a.push('<div class="reportNotice">非常抱歉！动漫456没能为您提供完善服务，非常感谢能得到您的指点！</div>');
            a.push('<div class="reportContent" id="reportContent">');
            a.push("<strong>报错/举报原因：</strong>");
            for (var c = 0; c < d.length; c++) a.push('<label><input type="checkbox"value="' + d[c] + '"/>' + d[c] + "</label>");
            a.push('<strong>详细描述:</strong><textarea rows="10"id="rep_desc"></textarea>');
            a.push('<div class="reportSubmit"><span class="fr"><button class="reportClose">关闭窗口</button></span><button id="reportSubmit">点我提交</button></div>');
            a.push("</div>");
            var b = this;
            $("#reportBox").html(a.join(""));
            this.boxBG.append();
            b.position();
            this.init = true;
            $("#reportBox .reportClose").bind("click",
            function() {
                b.Close()
            });
            $("#reportSubmit").bind("click",
            function() {
                b.send()
            });
            $(window).bind("resize", I567dm.throttle(function() {
                b.position()
            }))
        }
        $("#reportBox").show();
        this.boxBG.show()
    },
    Close: function() {
        $("#reportBox").hide();
        this.boxBG.hide()
    },
    bind: function() {
        var a = this;
        $("#report").bind("click",
        function() {
            a.Open()
        })
    },
    send: function() {
        for (var e = this,
        d = $("#reportContent :checkbox"), a = "", c = "", b = 0; b < d.length; b++) if (d[b].checked) {
            a += "," + d[b].value;
            c += "," + b
        }
        if (a == "") {
            window.alert("请选择 报错/举报 的原因");
            return false
        }
        a = a.substring(1);
        c = c.substring(1);
        $("#reportSubmit").attr("disabled", "disabled");
        var f = "vid=" + I567dm.vid + "&eid=" + I567dm.eid + "&pid=" + I567dm.pid + "&vt=" + escape(I567dm.vt) + "&pt=" + escape(I567dm.pt) + "&tn=" + escape(a) + "&tid=" + escape(c) + "&desc=" + escape($("#rep_desc").val()) + "&ua=" + escape(window.navigator.userAgent) + "&fl=" + escape(e.flashVer());
        $.ajax({
            type: "POST",
            url: "/aspx/report.ashx",
            data: f,
            success: function(a) {
                if (a == 1) {
                    e.Close();
                    window.alert("您已提交成功，我们将在最快的时间内核查内容。有您的支持，动漫456会做得更好!")
                } else {
                    window.alert("非常抱歉，您的提交失败，请稍候重试!");
                    $("#reportSubmit").removeAttr("disabled")
                }
            },
            error: function() {
                window.alert("非常抱歉，提交失败，请稍候重试!");
                $("#reportSubmit").removeAttr("disabled")
            }
        })
    },
    flashVer: function() {
        var a = null,
        c = 0;
        if (window.ActiveXObject) {
            var d = null;
            try {
                d = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
                c = 1
            } catch(e) {}
            if (d) {
                a = d.GetVariable("$version").substring(4);
                a = a.split(",");
                a = parseFloat(a[0] + "." + a[1])
            }
        } else if (navigator.plugins) for (var b = 0; b < navigator.plugins.length; b++) if (navigator.plugins[b].name.toLowerCase().indexOf("shockwave flash") >= 0) {
            c = 1;
            a = navigator.plugins[b].description.substring(navigator.plugins[b].description.toLowerCase().lastIndexOf("flash ") + 6, navigator.plugins[b].description.length)
        }
        return c == 0 ? "未安装Flash控件": "安装了Flash控件,版本：" + a
    }
};
I567dm.player.tip = {
    setting: {
        delay: 300
    },
    appended: false,
    timer: null,
    append: function() {
        if (this.appended == false) {
            $("#tipBox").html('<i id="tips_arrow" class="tips_arrow"></i><div class="tips_text_wrap shadow"><div id="tips_text" class="tips_text"></div></div>');
            this.appended = true
        }
    },
    show: function(e) {
        this.append();
        var b = $(e),
        a = $("#tipBox");
        $("#tips_text").text(b.attr("tip"));
        var c = b.position(),
        d = c.left - (a.width() - b.width()) / 2;
        a.css({
            left: d,
            top: c.top + 36
        });
        $("#tips_arrow").css("left", (a.width() - 6) / 2);
        a.show()
    },
    hide: function() {
        $("#tipBox").fadeOut(150)
    },
    init: function() {
        var a = this;
        $("#addFav,#copyUrl,#report,#next,#prev,#autoNext a").hover(function() {
            var b = this;
            a.timer && clearTimeout(a.timer);
            a.timer = setTimeout(function() {
                a.show(b)
            },
            a.setting.delay)
        },
        function() {
            a.timer && clearTimeout(a.timer);
            a.hide()
        })
    }
};
I567dm.player.play = function() {
    var d = this.setting.size.w,
    c = this.setting.size.h,
    a = I567dm.ps,
    b = "/Include/" + a + ".html?v=" + (new Date).getHours();
    $("#I567dm_player").html('<iframe src="' + b + '" width="' + d + '" height="' + c + '" scrolling="no" frameborder="0" id="DhpPlayer" name="DhpPlayer"></iframe>');
    this.float();
    this.shade();
    this.wide(a)
};
I567dm.player.supportAutoNext = {
    tudou: {
        support: true,
        fun: function() {
            DhpPlayer.window.playerEx = {
                notify: function() {
                    arguments.length > 1 && arguments[1] == "recommend" && I567dm.player.autoNext.gotoNext()
                }
            }
        }
    },
    优酷: {
        support: true,
        fun: "onPlayerComplete"
    },
    youku_hd: {
        support: true,
        fun: "onPlayerComplete"
    },
    奇艺: {
        support: true,
        fun: "videoPlayEnd"
    },
    乐视高清: {
        support: true,
        fun: "flashNextHandler",
        delay: 20
    },
    qq: {
        support: true,
        fun: "nextplay"
    },
    sohu: {
        support: true,
        fun: "swfGotoNewPage"
    },
    _56: {
        support: true,
        fun: "s2j_onPlayOver"
    },
    cntv: {
        support: true,
        fun: "video_play_over"
    },
    ku6: {
        support: true,
        fun: "playFinish"
    },
    sina: {
        support: true,
        fun: "nextPlay"
    },
    百度影音: {
        support: true,
        fun: function() {
            window.onPlay = function() {
                DhpPlayer.window.onPlay()
            };
            window.onPause = function() {
                DhpPlayer.window.onPause()
            };
            window.onFirstBufferingStart = function() {
                DhpPlayer.window.onFirstBufferingStart()
            };
            window.onFirstBufferingEnd = function() {
                DhpPlayer.window.onFirstBufferingEnd()
            };
            window.onPlayBufferingStart = function() {
                DhpPlayer.window.onPlayBufferingStart()
            };
            window.onPlayBufferingEnd = function() {
                DhpPlayer.window.onPlayBufferingEnd()
            };
            window.onComplete = function() {
                DhpPlayer.window.onComplete()
            }
        }
    },
    cctv: {
        support: false
    },
    qvod: {
        support: false
    },
    _6rrom: {
        supprot: false
    }
};
I567dm.player.autoNext = {
    getStatus: function() {
        var a = $.cookie("autonext");
        return a == null || a == "1" ? "1": "0"
    },
    gotoNext: function() {
        this.getStatus() === "1" && nextPage != "" && window.setTimeout(function() {
            location.href = nextPage + "?n=1&w=" + wideStatus
        },
        1e3)
    },
    bindNext: function(a) {
        var b = this; (b.getStatus() === "0" || a === false) && $("#autoNext").addClass("autoNextUncheck");
        if (a === true) $("#autoNext").click(function() {
            if (b.getStatus() === "0") {
                $.cookie("autonext", "1", {
                    expires: 90,
                    path: "/"
                });
                $("#autoNext").removeClass("autoNextUncheck")
            } else {
                $.cookie("autonext", "0", {
                    expires: 90,
                    path: "/"
                });
                $("#autoNext").addClass("autoNextUncheck")
            }
        });
        else {
            $("#autoNext").attr("disabled", "disabled").click(function() {
                alert("非常抱歉，此播放地址不支持自动连播。")
            });
            $("#autoNext a").attr("tip", "非常抱歉，此播放地址不支持自动连播。")
        }
    },
    bindFunc: function(a) {
        var b = this;
        if (typeof a === "string") DhpPlayer.window[a] = function() {
            b.gotoNext()
        };
        else typeof a === "function" && a()
    },
    bindFuncDelay: function(b, a) {
        a = a || 0;
        var c = this;
        if (a > 0) setTimeout(function() {
            c.bindFunc(b)
        },
        1e3 * a);
        else c.bindFunc(b)
    },
    init: function(a) {
        if (a == "56") a = "_56";
        else if (a == "6room") a = "_6room";
        var d = this,
        b = I567dm.player.supportAutoNext[a],
        c = false;
        if (typeof b !== "undefined" && b.support === true) {
            c = true;
            d.bindFuncDelay(b.fun, b.delay || 0)
        }
        d.bindNext(c)
    }
};
I567dm.player.setting = {
    size: {
        w: "100%",
        h: "520"
    },
    "float": {
        url: "/Include/loading.html",
        delay: 3e3,
        show: true
    },
    shade: {
        delay: 5e3,
        opacity: .5,
        show: true
    },
    wide: {
        delay: 5e3,
        show: true
    }
};
I567dm.player.bind = function(a) {
    I567dm.shortcuts.init({
        id: "topper",
        nav: false
    });
    I567dm.player.nav.bind();
    I567dm.player.lighter.bind();
    I567dm.player.report.bind();
    I567dm.player.data.init(a);
    I567dm.player.tip.init();
    I567dm.player.autoNext.init(I567dm.ps);
    scrollToTop.init();
    if (getQuery("n") == 1) {
        $(window).scrollTop(30);
        getQuery("w") == 1 && setTimeout(function() {
            I567dm.player.setWide(true)
        },
        I567dm.player.setting.float.delay)
    }
};

if (window.ActiveXObject && I567dm.ps == '百度影音') {
    var onPlay = function() {
        DhpPlayer.window.onPlay();
    }
    var onPause = function() {
        DhpPlayer.window.onPause();
    }
    var onFirstBufferingStart = function() {
        DhpPlayer.window.onFirstBufferingStart();
    }
    var onFirstBufferingEnd = function() {
        DhpPlayer.window.onFirstBufferingEnd();
    }
    var onPlayBufferingStart = function() {
        DhpPlayer.window.onPlayBufferingStart();
    }
    var onPlayBufferingEnd = function() {
        DhpPlayer.window.onPlayBufferingEnd();
    }
    var onComplete = function() {
        DhpPlayer.window.onComplete();
    }
}
var bdTip = {
    config: {
        cname: "bdtip",
        delay: 2e3,
        txt: "观看动画推荐使用百度影音，革新高清视听体验，P2P技术观看更流畅，自动播放下一集，边看边下载，还可离线观看，点击立即安装！",
        url: "/aspx/player.ashx"
    },
    init: function() {
        var a = this;
        if (I567dm.ps != "百度影音") {
            var b = $.cookie(a.config.cname); (b == null || b != 1) && window.setTimeout(function() {
                $("#bdTip").html('<div class="bdTip"><a href="' + a.config.url + '" target="_blank">' + a.config.txt + '</a><span class="bdTipClose" title="关闭" onclick="bdTip.hide()"></span></div>');
                a.show()
            },
            this.config.delay)
        }
    },
    show: function() {
        $("#bdTip").fadeIn(200)
    },
    hide: function() {
        $("#bdTip").hide();
        $.cookie(this.config.cname, "1", {
            expires: 1,
            path: "/"
        })
    }
}

