1
0
Fork 0
mirror of https://github.com/Yetangitu/ampache synced 2025-10-03 09:49:30 +02:00

HTML5 player replaced by JPlayer and add an iframed version of the player

This commit is contained in:
Afterster 2013-10-22 14:13:29 +02:00
parent c6680009ce
commit 99ad5f7f82
27 changed files with 1929 additions and 382 deletions

View file

@ -73,6 +73,7 @@ Ampache includes some external modules that carry their own licensing.
* [Snoopy](http://snoopy.sourceforge.net/): LGPL v2.1
* [Whatever:hover](http://www.xs4all.nl/~peterned): LGPL v2.1
* [xbmc-php-rpc](https://github.com/karlrixon/xbmc-php-rpc): GPL v3
* [JPlayer](http://jplayer.org/): MIT
Translations
------------

28
html5_player_embedded.php Normal file
View file

@ -0,0 +1,28 @@
<?php
/* vim:set softtabstop=4 shiftwidth=4 expandtab: */
/**
*
* LICENSE: GNU General Public License, version 2 (GPLv2)
* Copyright 2001 - 2013 Ampache.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License v2
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
require_once 'lib/init.php';
$iframed = true;
require_once Config::get('prefix') . '/templates/show_html5_player.inc.php';
?>

View file

@ -22,6 +22,12 @@
require_once 'lib/init.php';
if (Config::get('iframes')) {
if (!isset($_GET['framed'])) {
UI::show_mainframes();
exit;
}
}
UI::show_header();
$action = isset($_REQUEST['action']) ? scrub_in($_REQUEST['action']) : null;

View file

@ -160,6 +160,7 @@ class Stream_Playlist {
case 'democratic':
case 'localplay':
case 'html5_player':
case 'html5_player_embedded':
// These are valid, but witchy
$redirect = false;
unset($ext);
@ -360,6 +361,15 @@ class Stream_Playlist {
require Config::get('prefix') . '/templates/create_html5_player.inc.php';
}
/**
* create_html5_player_embedded
*
* Creates an html5 player embedded.
*/
public function create_html5_player_embedded() {
require Config::get('prefix') . '/templates/create_html5_player_embedded.inc.php';
}
/**
* create_localplay
* This calls the Localplay API to add the URLs and then start playback

View file

@ -244,6 +244,15 @@ class UI {
require_once Config::get('prefix') . '/templates/header.inc.php';
}
/**
* show_mainframes
*
* For now this just shows the mainframes template
*/
public static function show_mainframes() {
require_once Config::get('prefix') . '/templates/mainframes.inc.php';
}
/**
* show_footer
*

View file

@ -287,6 +287,9 @@ class Update {
$update_string = '- Increase the length of sessionids again.<br />';
$version[] = array('version' => '360014', 'description' => $update_string);
$update_string = '- Add iframes parameter to preferences.<br />';
$version[] = array('version' => '360015', 'description' => $update_string);
return $version;
}
@ -1480,5 +1483,23 @@ class Update {
return $retval;
}
/**
* update_360015
*
* This update inserts the Iframes preference...
*/
public static function update_360015() {
$sql = "INSERT INTO `preference` (`name`,`value`,`description`,`level`,`type`,`catagory`) " .
"VALUES ('iframes','0','Iframes',25,'boolean','interface')";
Dba::write($sql);
$id = Dba::insert_id();
$sql = "INSERT INTO `user_preference` VALUES (-1,?,'0')";
Dba::write($sql, array($id));
return true;
}
}
?>

View file

@ -1,246 +0,0 @@
/* vim:set tabstop=4 softtabstop=4 shiftwidth=4 expandtab: */
/**
*
* LICENSE: GNU General Public License, version 2 (GPLv2)
* Copyright 2013 Ampache.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License v2
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
var current_playlist_item = null;
function play_item(event)
{
stop();
current_playlist_item = event.findElement().getStorage().get('playlist_item');
play();
}
function adjust_buttons()
{
if(!current_playlist_item.player.paused)
{
$('play').addClassName('inactive');
$('pause').removeClassName('inactive');
$('stop').removeClassName('inactive');
}
else
{
$('play').removeClassName('inactive');
$('pause').addClassName('inactive');
$('stop').addClassName('inactive');
}
}
function stop(event)
{
if(current_playlist_item)
{
current_playlist_item.player.pause();
current_playlist_item.player.currentTime = 0;
if(current_playlist_item.player.currentTime)
{
var src=current_playlist_item.player.src;
current_playlist_item.player.src=null;
current_playlist_item.player.src=src;
}
current_playlist_item.element.removeClassName('playing');
adjust_buttons();
}
}
function pause(event)
{
if(current_playlist_item)
{
current_playlist_item.player.pause();
adjust_buttons();
}
}
function play(event)
{
if(current_playlist_item)
{
$('title').update(current_playlist_item.info_url);
$('title').select('a')[0].writeAttribute('target', '_new');
$('album').update(current_playlist_item.f_album_link);
//$('album').select('a')[0].writeAttribute('target', '_new');
$('artist').update(current_playlist_item.author);
//$('artist').select('a')[0].writeAttribute('target', '_new');
$('albumart').update(new Element('img', {src: current_playlist_item.albumart_url + '&thumb=4'}));
dequeue(current_playlist_item.element);
current_playlist_item.player.writeAttribute('preload', 'auto');
current_playlist_item.player.play();
if(current_playlist_item.element.offsetTop - $('playlist').offsetTop - $('playlist').scrollTop > $('playlist').measure('height') || current_playlist_item.element.offsetTop - $('playlist').offsetTop - $('playlist').scrollTop < 0)
{
$('playlist').scrollTop = current_playlist_item.element.offsetTop - $('playlist').offsetTop;
}
current_playlist_item.element.addClassName('playing');
adjust_buttons();
}
}
function next(event)
{
if(current_playlist_item && current_playlist_item.next)
{
stop();
var next = current_playlist_item.next;
$$('[data-queue-id=1]').each(function(e) { next=e.getStorage().get('playlist_item') });
current_playlist_item = next;
play();
}
}
function previous(event)
{
if(current_playlist_item && current_playlist_item.previous)
{
stop();
current_playlist_item = current_playlist_item.previous;
play();
}
}
function seconds_to_string(seconds)
{
return Math.floor(seconds / 60) + ":" + (Math.floor(seconds % 60) < 10 ? '0' : '') + Math.floor(seconds % 60);
}
function timeupdate(event)
{
if(current_playlist_item)
{
$('progress_text').update(seconds_to_string(current_playlist_item.player.currentTime) + "/" + seconds_to_string(current_playlist_item.time));
if(current_playlist_item.player.currentTime > current_playlist_item.time / 2)
{
if(current_playlist_item.next)
{
current_playlist_item.next.player.writeAttribute('preload', 'auto');
}
}
//fix for chrome where ended is not thrown properly
if(current_playlist_item.player.currentTime >= current_playlist_item.time)
{
ended(event);
}
}
}
function ended(event)
{
next(event);
}
function search(event)
{
var search = new RegExp(".*" + event.findElement().value + ".*", "i");
for(var item = $('playlist').firstDescendant(); item; item = item.next())
{
if(!search.test(item.textContent != undefined ? item.textContent : item.innerText))
{
item.hide();
}
else
{
item.show();
}
}
}
function clear_search(event)
{
event.findElement().value = "";
search(event);
}
function queue(event)
{
var queue_id=0;
if(event.findElement().getAttribute('data-queue-id'))
{
return dequeue(event.findElement());
}
$$('[data-queue-id]').each(
function(e)
{
if(parseInt(e.getAttribute('data-queue-id')) > queue_id)
{
queue_id = parseInt(e.getAttribute('data-queue-id'));
}
});
event.findElement().setAttribute('data-queue-id', queue_id+1);
}
function dequeue(element)
{
var queue_id=0;
$$('[data-queue-id]').sort(
function(x, y)
{
return parseInt(x.getAttribute('data-queue-id'))-parseInt(y.getAttribute('data-queue-id'));
})
.each(
function(e)
{
if(queue_id)
{
e.setAttribute('data-queue-id', queue_id++);
}
if(e==element)
{
queue_id=parseInt(e.getAttribute('data-queue-id'));
e.removeAttribute('data-queue-id');
}
});
}
document.observe("dom:loaded", function()
{
var last_item = null, first_item = null;
for(id in playlist_items)
{
var li = new Element('li');
$('playlist').insert(li);
playlist_items[id].play_url += '&transcode_to=' + (Prototype.Browser.IE || Prototype.Browser.WebKit || Prototype.Browser.MobileSafari ? 'mp3' : 'ogg');
li.update(playlist_items[id].title);
playlist_items[id].player = new Element("audio", {preload: Prototype.Browser.IE ? 'auto' : 'none', src : playlist_items[id].play_url});
li.insert(playlist_items[id].player);
li.getStorage().set('playlist_item', playlist_items[id]);
li.observe('click', play_item);
li.observe('mousedown', function(event) {if(event.which==2 || event.which==3) queue(event)});
li.setAttribute('data-tooltip', playlist_items[id].album + ' - ' + playlist_items[id].author);
playlist_items[id].player.observe('ended', ended);
playlist_items[id].player.observe('timeupdate', timeupdate);
playlist_items[id].element = li;
if(last_item)
{
last_item.next = playlist_items[id];
}
if(first_item == null)
{
first_item = playlist_items[id];
}
playlist_items[id].previous = last_item;
last_item = playlist_items[id];
}
if(first_item)
{
// first_item.previous = last_item;
// last_item.next = first_item;
current_playlist_item = first_item;
play();
}
$('stop').observe('click', stop);
$('play').observe('click', play);
$('pause').observe('click', pause);
$('next').observe('click', next);
$('previous').observe('click', previous);
$('input_search').observe('keyup', search);
$('input_search').observe('html5_player:clear_search', clear_search);
$('input_search').observe('focus', clear_search);
$('clear_search').observe('click', function() {
$('input_search').fire('html5_player:clear_search')
});
});

View file

@ -166,6 +166,7 @@ function create_preference_input($name,$value) {
case 'rio_track_stats':
case 'rio_global_stats':
case 'direct_link':
case 'iframes':
if ($value == '1') { $is_true = "selected=\"selected\""; }
else { $is_false = "selected=\"selected\""; }
echo "<select name=\"$name\">\n";
@ -177,6 +178,7 @@ function create_preference_input($name,$value) {
if ($value == 'localplay') { $is_local = 'selected="selected"'; }
elseif ($value == 'democratic') { $is_vote = 'selected="selected"'; }
elseif ($value == 'html5_player') { $is_html5_player = 'selected="selected"'; }
elseif ($value == 'html5_player_embedded') { $is_html5_player_embedded = 'selected="selected"'; }
else { $is_stream = "selected=\"selected\""; }
echo "<select name=\"$name\">\n";
echo "\t<option value=\"\">" . T_('None') . "</option>\n";
@ -190,6 +192,7 @@ function create_preference_input($name,$value) {
echo "\t<option value=\"localplay\" $is_local>" . T_('Localplay') . "</option>\n";
}
echo "\t<option value=\"html5_player\" $is_html5_player>" . _('HTML5 Player') . "</option>\n";
echo "\t<option value=\"html5_player_embedded\" $is_html5_player_embedded>" . _('Framed Player') . "</option>\n";
echo "</select>\n";
break;
case 'playlist_type':

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 783 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

34
modules/jplayer/jplayer.playlist.min.js vendored Normal file
View file

@ -0,0 +1,34 @@
/*
* Playlist Object for the jPlayer Plugin
* http://www.jplayer.org
*
* Copyright (c) 2009 - 2013 Happyworm Ltd
* Dual licensed under the MIT and GPL licenses.
* - http://www.opensource.org/licenses/mit-license.php
* - http://www.gnu.org/copyleft/gpl.html
*
* Author: Mark J Panaghiston
* Version: 2.3.0
* Date: 20th April 2013
*
* Requires:
* - jQuery 1.7.0+
* - jPlayer 2.3.0+
*/
(function(b,f){jPlayerPlaylist=function(a,c,d){var e=this;this.current=0;this.removing=this.shuffled=this.loop=!1;this.cssSelector=b.extend({},this._cssSelector,a);this.options=b.extend(!0,{keyBindings:{next:{key:39,fn:function(){e.next()}},previous:{key:37,fn:function(){e.previous()}}}},this._options,d);this.playlist=[];this.original=[];this._initPlaylist(c);this.cssSelector.title=this.cssSelector.cssSelectorAncestor+" .jp-title";this.cssSelector.playlist=this.cssSelector.cssSelectorAncestor+" .jp-playlist";
this.cssSelector.next=this.cssSelector.cssSelectorAncestor+" .jp-next";this.cssSelector.previous=this.cssSelector.cssSelectorAncestor+" .jp-previous";this.cssSelector.shuffle=this.cssSelector.cssSelectorAncestor+" .jp-shuffle";this.cssSelector.shuffleOff=this.cssSelector.cssSelectorAncestor+" .jp-shuffle-off";this.options.cssSelectorAncestor=this.cssSelector.cssSelectorAncestor;this.options.repeat=function(a){e.loop=a.jPlayer.options.loop};b(this.cssSelector.jPlayer).bind(b.jPlayer.event.ready,function(){e._init()});
b(this.cssSelector.jPlayer).bind(b.jPlayer.event.ended,function(){e.next()});b(this.cssSelector.jPlayer).bind(b.jPlayer.event.play,function(){b(this).jPlayer("pauseOthers")});b(this.cssSelector.jPlayer).bind(b.jPlayer.event.resize,function(a){a.jPlayer.options.fullScreen?b(e.cssSelector.title).show():b(e.cssSelector.title).hide()});b(this.cssSelector.previous).click(function(){e.previous();b(this).blur();return!1});b(this.cssSelector.next).click(function(){e.next();b(this).blur();return!1});b(this.cssSelector.shuffle).click(function(){e.shuffle(!0);
return!1});b(this.cssSelector.shuffleOff).click(function(){e.shuffle(!1);return!1}).hide();this.options.fullScreen||b(this.cssSelector.title).hide();b(this.cssSelector.playlist+" ul").empty();this._createItemHandlers();b(this.cssSelector.jPlayer).jPlayer(this.options)};jPlayerPlaylist.prototype={_cssSelector:{jPlayer:"#jquery_jplayer_1",cssSelectorAncestor:"#jp_container_1"},_options:{playlistOptions:{autoPlay:!1,loopOnPrevious:!1,shuffleOnLoop:!0,enableRemoveControls:!1,displayTime:"slow",addTime:"fast",
removeTime:"fast",shuffleTime:"slow",itemClass:"jp-playlist-item",freeGroupClass:"jp-free-media",freeItemClass:"jp-playlist-item-free",removeItemClass:"jp-playlist-item-remove"}},option:function(a,b){if(b===f)return this.options.playlistOptions[a];this.options.playlistOptions[a]=b;switch(a){case "enableRemoveControls":this._updateControls();break;case "itemClass":case "freeGroupClass":case "freeItemClass":case "removeItemClass":this._refresh(!0),this._createItemHandlers()}return this},_init:function(){var a=
this;this._refresh(function(){a.options.playlistOptions.autoPlay?a.play(a.current):a.select(a.current)})},_initPlaylist:function(a){this.current=0;this.removing=this.shuffled=!1;this.original=b.extend(!0,[],a);this._originalPlaylist()},_originalPlaylist:function(){var a=this;this.playlist=[];b.each(this.original,function(b){a.playlist[b]=a.original[b]})},_refresh:function(a){var c=this;if(a&&!b.isFunction(a))b(this.cssSelector.playlist+" ul").empty(),b.each(this.playlist,function(a){b(c.cssSelector.playlist+
" ul").append(c._createListItem(c.playlist[a]))}),this._updateControls();else{var d=b(this.cssSelector.playlist+" ul").children().length?this.options.playlistOptions.displayTime:0;b(this.cssSelector.playlist+" ul").slideUp(d,function(){var d=b(this);b(this).empty();b.each(c.playlist,function(a){d.append(c._createListItem(c.playlist[a]))});c._updateControls();b.isFunction(a)&&a();c.playlist.length?b(this).slideDown(c.options.playlistOptions.displayTime):b(this).show()})}},_createListItem:function(a){var c=
this,d="<li><div>",d=d+("<a href='javascript:;' class='"+this.options.playlistOptions.removeItemClass+"'>&times;</a>");if(a.free){var e=!0,d=d+("<span class='"+this.options.playlistOptions.freeGroupClass+"'>(");b.each(a,function(a,f){b.jPlayer.prototype.format[a]&&(e?e=!1:d+=" | ",d+="<a class='"+c.options.playlistOptions.freeItemClass+"' href='"+f+"' tabindex='1'>"+a+"</a>")});d+=")</span>"}d+="<a href='javascript:;' class='"+this.options.playlistOptions.itemClass+"' tabindex='1'>"+a.title+(a.artist?
" <span class='jp-artist'>by "+a.artist+"</span>":"")+"</a>";return d+="</div></li>"},_createItemHandlers:function(){var a=this;b(this.cssSelector.playlist).off("click","a."+this.options.playlistOptions.itemClass).on("click","a."+this.options.playlistOptions.itemClass,function(){var c=b(this).parent().parent().index();a.current!==c?a.play(c):b(a.cssSelector.jPlayer).jPlayer("play");b(this).blur();return!1});b(this.cssSelector.playlist).off("click","a."+this.options.playlistOptions.freeItemClass).on("click",
"a."+this.options.playlistOptions.freeItemClass,function(){b(this).parent().parent().find("."+a.options.playlistOptions.itemClass).click();b(this).blur();return!1});b(this.cssSelector.playlist).off("click","a."+this.options.playlistOptions.removeItemClass).on("click","a."+this.options.playlistOptions.removeItemClass,function(){var c=b(this).parent().parent().index();a.remove(c);b(this).blur();return!1})},_updateControls:function(){this.options.playlistOptions.enableRemoveControls?b(this.cssSelector.playlist+
" ."+this.options.playlistOptions.removeItemClass).show():b(this.cssSelector.playlist+" ."+this.options.playlistOptions.removeItemClass).hide();this.shuffled?(b(this.cssSelector.shuffleOff).show(),b(this.cssSelector.shuffle).hide()):(b(this.cssSelector.shuffleOff).hide(),b(this.cssSelector.shuffle).show())},_highlight:function(a){this.playlist.length&&a!==f&&(b(this.cssSelector.playlist+" .jp-playlist-current").removeClass("jp-playlist-current"),b(this.cssSelector.playlist+" li:nth-child("+(a+1)+
")").addClass("jp-playlist-current").find(".jp-playlist-item").addClass("jp-playlist-current"),b(this.cssSelector.title+" li").html(this.playlist[a].title+(this.playlist[a].artist?" <span class='jp-artist'>by "+this.playlist[a].artist+"</span>":"")))},setPlaylist:function(a){this._initPlaylist(a);this._init()},add:function(a,c){b(this.cssSelector.playlist+" ul").append(this._createListItem(a)).find("li:last-child").hide().slideDown(this.options.playlistOptions.addTime);this._updateControls();this.original.push(a);
this.playlist.push(a);c?this.play(this.playlist.length-1):1===this.original.length&&this.select(0)},remove:function(a){var c=this;if(a===f)return this._initPlaylist([]),this._refresh(function(){b(c.cssSelector.jPlayer).jPlayer("clearMedia")}),!0;if(this.removing)return!1;a=0>a?c.original.length+a:a;0<=a&&a<this.playlist.length&&(this.removing=!0,b(this.cssSelector.playlist+" li:nth-child("+(a+1)+")").slideUp(this.options.playlistOptions.removeTime,function(){b(this).remove();if(c.shuffled){var d=
c.playlist[a];b.each(c.original,function(a){if(c.original[a]===d)return c.original.splice(a,1),!1})}else c.original.splice(a,1);c.playlist.splice(a,1);c.original.length?a===c.current?(c.current=a<c.original.length?c.current:c.original.length-1,c.select(c.current)):a<c.current&&c.current--:(b(c.cssSelector.jPlayer).jPlayer("clearMedia"),c.current=0,c.shuffled=!1,c._updateControls());c.removing=!1}));return!0},select:function(a){a=0>a?this.original.length+a:a;0<=a&&a<this.playlist.length?(this.current=
a,this._highlight(a),b(this.cssSelector.jPlayer).jPlayer("setMedia",this.playlist[this.current])):this.current=0},play:function(a){a=0>a?this.original.length+a:a;0<=a&&a<this.playlist.length?this.playlist.length&&(this.select(a),b(this.cssSelector.jPlayer).jPlayer("play")):a===f&&b(this.cssSelector.jPlayer).jPlayer("play")},pause:function(){b(this.cssSelector.jPlayer).jPlayer("pause")},next:function(){var a=this.current+1<this.playlist.length?this.current+1:0;this.loop?0===a&&this.shuffled&&this.options.playlistOptions.shuffleOnLoop&&
1<this.playlist.length?this.shuffle(!0,!0):this.play(a):0<a&&this.play(a)},previous:function(){var a=0<=this.current-1?this.current-1:this.playlist.length-1;(this.loop&&this.options.playlistOptions.loopOnPrevious||a<this.playlist.length-1)&&this.play(a)},shuffle:function(a,c){var d=this;a===f&&(a=!this.shuffled);(a||a!==this.shuffled)&&b(this.cssSelector.playlist+" ul").slideUp(this.options.playlistOptions.shuffleTime,function(){(d.shuffled=a)?d.playlist.sort(function(){return 0.5-Math.random()}):
d._originalPlaylist();d._refresh(!0);c||!b(d.cssSelector.jPlayer).data("jPlayer").status.paused?d.play(0):d.select(0);b(this).slideDown(d.options.playlistOptions.shuffleTime)})}}})(jQuery);

107
modules/jplayer/jquery.jplayer.min.js vendored Normal file
View file

@ -0,0 +1,107 @@
/*
* jPlayer Plugin for jQuery JavaScript Library
* http://www.jplayer.org
*
* Copyright (c) 2009 - 2013 Happyworm Ltd
* Licensed under the MIT license.
* http://opensource.org/licenses/MIT
*
* Author: Mark J Panaghiston
* Version: 2.4.0
* Date: 5th June 2013
*/
(function(b,f){"function"===typeof define&&define.amd?define(["jquery"],f):b.jQuery?f(b.jQuery):f(b.Zepto)})(this,function(b,f){b.fn.jPlayer=function(a){var c="string"===typeof a,d=Array.prototype.slice.call(arguments,1),e=this;a=!c&&d.length?b.extend.apply(null,[!0,a].concat(d)):a;if(c&&"_"===a.charAt(0))return e;c?this.each(function(){var c=b(this).data("jPlayer"),h=c&&b.isFunction(c[a])?c[a].apply(c,d):c;if(h!==c&&h!==f)return e=h,!1}):this.each(function(){var c=b(this).data("jPlayer");c?c.option(a||
{}):b(this).data("jPlayer",new b.jPlayer(a,this))});return e};b.jPlayer=function(a,c){if(arguments.length){this.element=b(c);this.options=b.extend(!0,{},this.options,a);var d=this;this.element.bind("remove.jPlayer",function(){d.destroy()});this._init()}};"function"!==typeof b.fn.stop&&(b.fn.stop=function(){});b.jPlayer.emulateMethods="load play pause";b.jPlayer.emulateStatus="src readyState networkState currentTime duration paused ended playbackRate";b.jPlayer.emulateOptions="muted volume";b.jPlayer.reservedEvent=
"ready flashreset resize repeat error warning";b.jPlayer.event={};b.each("ready flashreset resize repeat click error warning loadstart progress suspend abort emptied stalled play pause loadedmetadata loadeddata waiting playing canplay canplaythrough seeking seeked timeupdate ended ratechange durationchange volumechange".split(" "),function(){b.jPlayer.event[this]="jPlayer_"+this});b.jPlayer.htmlEvent="loadstart abort emptied stalled loadedmetadata loadeddata canplay canplaythrough ratechange".split(" ");
b.jPlayer.pause=function(){b.each(b.jPlayer.prototype.instances,function(a,c){c.data("jPlayer").status.srcSet&&c.jPlayer("pause")})};b.jPlayer.timeFormat={showHour:!1,showMin:!0,showSec:!0,padHour:!1,padMin:!0,padSec:!0,sepHour:":",sepMin:":",sepSec:""};var l=function(){this.init()};l.prototype={init:function(){this.options={timeFormat:b.jPlayer.timeFormat}},time:function(a){var c=new Date(1E3*(a&&"number"===typeof a?a:0)),b=c.getUTCHours();a=this.options.timeFormat.showHour?c.getUTCMinutes():c.getUTCMinutes()+
60*b;c=this.options.timeFormat.showMin?c.getUTCSeconds():c.getUTCSeconds()+60*a;b=this.options.timeFormat.padHour&&10>b?"0"+b:b;a=this.options.timeFormat.padMin&&10>a?"0"+a:a;c=this.options.timeFormat.padSec&&10>c?"0"+c:c;b=""+(this.options.timeFormat.showHour?b+this.options.timeFormat.sepHour:"");b+=this.options.timeFormat.showMin?a+this.options.timeFormat.sepMin:"";return b+=this.options.timeFormat.showSec?c+this.options.timeFormat.sepSec:""}};var m=new l;b.jPlayer.convertTime=function(a){return m.time(a)};
b.jPlayer.uaBrowser=function(a){a=a.toLowerCase();var b=/(opera)(?:.*version)?[ \/]([\w.]+)/,d=/(msie) ([\w.]+)/,e=/(mozilla)(?:.*? rv:([\w.]+))?/;a=/(webkit)[ \/]([\w.]+)/.exec(a)||b.exec(a)||d.exec(a)||0>a.indexOf("compatible")&&e.exec(a)||[];return{browser:a[1]||"",version:a[2]||"0"}};b.jPlayer.uaPlatform=function(a){var b=a.toLowerCase(),d=/(android)/,e=/(mobile)/;a=/(ipad|iphone|ipod|android|blackberry|playbook|windows ce|webos)/.exec(b)||[];b=/(ipad|playbook)/.exec(b)||!e.exec(b)&&d.exec(b)||
[];a[1]&&(a[1]=a[1].replace(/\s/g,"_"));return{platform:a[1]||"",tablet:b[1]||""}};b.jPlayer.browser={};b.jPlayer.platform={};var j=b.jPlayer.uaBrowser(navigator.userAgent);j.browser&&(b.jPlayer.browser[j.browser]=!0,b.jPlayer.browser.version=j.version);j=b.jPlayer.uaPlatform(navigator.userAgent);j.platform&&(b.jPlayer.platform[j.platform]=!0,b.jPlayer.platform.mobile=!j.tablet,b.jPlayer.platform.tablet=!!j.tablet);b.jPlayer.getDocMode=function(){var a;b.jPlayer.browser.msie&&(document.documentMode?
a=document.documentMode:(a=5,document.compatMode&&"CSS1Compat"===document.compatMode&&(a=7)));return a};b.jPlayer.browser.documentMode=b.jPlayer.getDocMode();b.jPlayer.nativeFeatures={init:function(){var a=document,b=a.createElement("video"),d={w3c:"fullscreenEnabled fullscreenElement requestFullscreen exitFullscreen fullscreenchange fullscreenerror".split(" "),moz:"mozFullScreenEnabled mozFullScreenElement mozRequestFullScreen mozCancelFullScreen mozfullscreenchange mozfullscreenerror".split(" "),
webkit:" webkitCurrentFullScreenElement webkitRequestFullScreen webkitCancelFullScreen webkitfullscreenchange ".split(" "),webkitVideo:"webkitSupportsFullscreen webkitDisplayingFullscreen webkitEnterFullscreen webkitExitFullscreen ".split(" ")},e=["w3c","moz","webkit","webkitVideo"],g,h;this.fullscreen=b={support:{w3c:!!a[d.w3c[0]],moz:!!a[d.moz[0]],webkit:"function"===typeof a[d.webkit[3]],webkitVideo:"function"===typeof b[d.webkitVideo[2]]},used:{}};g=0;for(h=e.length;g<h;g++){var f=e[g];if(b.support[f]){b.spec=
f;b.used[f]=!0;break}}if(b.spec){var k=d[b.spec];b.api={fullscreenEnabled:!0,fullscreenElement:function(b){b=b?b:a;return b[k[1]]},requestFullscreen:function(a){return a[k[2]]()},exitFullscreen:function(b){b=b?b:a;return b[k[3]]()}};b.event={fullscreenchange:k[4],fullscreenerror:k[5]}}else b.api={fullscreenEnabled:!1,fullscreenElement:function(){return null},requestFullscreen:function(){},exitFullscreen:function(){}},b.event={}}};b.jPlayer.nativeFeatures.init();b.jPlayer.focus=null;b.jPlayer.keyIgnoreElementNames=
"INPUT TEXTAREA";var n=function(a){var c=b.jPlayer.focus,d;c&&(b.each(b.jPlayer.keyIgnoreElementNames.split(/\s+/g),function(b,c){if(a.target.nodeName.toUpperCase()===c.toUpperCase())return d=!0,!1}),d||b.each(c.options.keyBindings,function(d,g){if(g&&a.which===g.key&&b.isFunction(g.fn))return a.preventDefault(),g.fn(c),!1}))};b.jPlayer.keys=function(a){b(document.documentElement).unbind("keydown.jPlayer");a&&b(document.documentElement).bind("keydown.jPlayer",n)};b.jPlayer.keys(!0);b.jPlayer.prototype=
{count:0,version:{script:"2.4.0",needFlash:"2.4.0",flash:"unknown"},options:{swfPath:"js",solution:"html, flash",supplied:"mp3",preload:"metadata",volume:0.8,muted:!1,wmode:"opaque",backgroundColor:"#000000",cssSelectorAncestor:"#jp_container_1",cssSelector:{videoPlay:".jp-video-play",play:".jp-play",pause:".jp-pause",stop:".jp-stop",seekBar:".jp-seek-bar",playBar:".jp-play-bar",mute:".jp-mute",unmute:".jp-unmute",volumeBar:".jp-volume-bar",volumeBarValue:".jp-volume-bar-value",volumeMax:".jp-volume-max",
currentTime:".jp-current-time",duration:".jp-duration",fullScreen:".jp-full-screen",restoreScreen:".jp-restore-screen",repeat:".jp-repeat",repeatOff:".jp-repeat-off",gui:".jp-gui",noSolution:".jp-no-solution"},smoothPlayBar:!1,fullScreen:!1,fullWindow:!1,autohide:{restored:!1,full:!0,fadeIn:200,fadeOut:600,hold:1E3},loop:!1,repeat:function(a){a.jPlayer.options.loop?b(this).unbind(".jPlayerRepeat").bind(b.jPlayer.event.ended+".jPlayer.jPlayerRepeat",function(){b(this).jPlayer("play")}):b(this).unbind(".jPlayerRepeat")},
nativeVideoControls:{},noFullWindow:{msie:/msie [0-6]\./,ipad:/ipad.*?os [0-4]\./,iphone:/iphone/,ipod:/ipod/,android_pad:/android [0-3]\.(?!.*?mobile)/,android_phone:/android.*?mobile/,blackberry:/blackberry/,windows_ce:/windows ce/,iemobile:/iemobile/,webos:/webos/},noVolume:{ipad:/ipad/,iphone:/iphone/,ipod:/ipod/,android_pad:/android(?!.*?mobile)/,android_phone:/android.*?mobile/,blackberry:/blackberry/,windows_ce:/windows ce/,iemobile:/iemobile/,webos:/webos/,playbook:/playbook/},timeFormat:{},
keyEnabled:!1,audioFullScreen:!1,keyBindings:{play:{key:32,fn:function(a){a.status.paused?a.play():a.pause()}},fullScreen:{key:13,fn:function(a){(a.status.video||a.options.audioFullScreen)&&a._setOption("fullScreen",!a.options.fullScreen)}},muted:{key:8,fn:function(a){a._muted(!a.options.muted)}},volumeUp:{key:38,fn:function(a){a.volume(a.options.volume+0.1)}},volumeDown:{key:40,fn:function(a){a.volume(a.options.volume-0.1)}}},verticalVolume:!1,idPrefix:"jp",noConflict:"jQuery",emulateHtml:!1,errorAlerts:!1,
warningAlerts:!1},optionsAudio:{size:{width:"0px",height:"0px",cssClass:""},sizeFull:{width:"0px",height:"0px",cssClass:""}},optionsVideo:{size:{width:"480px",height:"270px",cssClass:"jp-video-270p"},sizeFull:{width:"100%",height:"100%",cssClass:"jp-video-full"}},instances:{},status:{src:"",media:{},paused:!0,format:{},formatType:"",waitForPlay:!0,waitForLoad:!0,srcSet:!1,video:!1,seekPercent:0,currentPercentRelative:0,currentPercentAbsolute:0,currentTime:0,duration:0,videoWidth:0,videoHeight:0,readyState:0,
networkState:0,playbackRate:1,ended:0},internal:{ready:!1},solution:{html:!0,flash:!0},format:{mp3:{codec:'audio/mpeg; codecs="mp3"',flashCanPlay:!0,media:"audio"},m4a:{codec:'audio/mp4; codecs="mp4a.40.2"',flashCanPlay:!0,media:"audio"},oga:{codec:'audio/ogg; codecs="vorbis"',flashCanPlay:!1,media:"audio"},wav:{codec:'audio/wav; codecs="1"',flashCanPlay:!1,media:"audio"},webma:{codec:'audio/webm; codecs="vorbis"',flashCanPlay:!1,media:"audio"},fla:{codec:"audio/x-flv",flashCanPlay:!0,media:"audio"},
rtmpa:{codec:'audio/rtmp; codecs="rtmp"',flashCanPlay:!0,media:"audio"},m4v:{codec:'video/mp4; codecs="avc1.42E01E, mp4a.40.2"',flashCanPlay:!0,media:"video"},ogv:{codec:'video/ogg; codecs="theora, vorbis"',flashCanPlay:!1,media:"video"},webmv:{codec:'video/webm; codecs="vorbis, vp8"',flashCanPlay:!1,media:"video"},flv:{codec:"video/x-flv",flashCanPlay:!0,media:"video"},rtmpv:{codec:'video/rtmp; codecs="rtmp"',flashCanPlay:!0,media:"video"}},_init:function(){var a=this;this.element.empty();this.status=
b.extend({},this.status);this.internal=b.extend({},this.internal);this.options.timeFormat=b.extend({},b.jPlayer.timeFormat,this.options.timeFormat);this.internal.cmdsIgnored=b.jPlayer.platform.ipad||b.jPlayer.platform.iphone||b.jPlayer.platform.ipod;this.internal.domNode=this.element.get(0);this.options.keyEnabled&&!b.jPlayer.focus&&(b.jPlayer.focus=this);this.formats=[];this.solutions=[];this.require={};this.htmlElement={};this.html={};this.html.audio={};this.html.video={};this.flash={};this.css=
{};this.css.cs={};this.css.jq={};this.ancestorJq=[];this.options.volume=this._limitValue(this.options.volume,0,1);b.each(this.options.supplied.toLowerCase().split(","),function(c,d){var e=d.replace(/^\s+|\s+$/g,"");if(a.format[e]){var f=!1;b.each(a.formats,function(a,b){if(e===b)return f=!0,!1});f||a.formats.push(e)}});b.each(this.options.solution.toLowerCase().split(","),function(c,d){var e=d.replace(/^\s+|\s+$/g,"");if(a.solution[e]){var f=!1;b.each(a.solutions,function(a,b){if(e===b)return f=!0,
!1});f||a.solutions.push(e)}});this.internal.instance="jp_"+this.count;this.instances[this.internal.instance]=this.element;this.element.attr("id")||this.element.attr("id",this.options.idPrefix+"_jplayer_"+this.count);this.internal.self=b.extend({},{id:this.element.attr("id"),jq:this.element});this.internal.audio=b.extend({},{id:this.options.idPrefix+"_audio_"+this.count,jq:f});this.internal.video=b.extend({},{id:this.options.idPrefix+"_video_"+this.count,jq:f});this.internal.flash=b.extend({},{id:this.options.idPrefix+
"_flash_"+this.count,jq:f,swf:this.options.swfPath+(".swf"!==this.options.swfPath.toLowerCase().slice(-4)?(this.options.swfPath&&"/"!==this.options.swfPath.slice(-1)?"/":"")+"Jplayer.swf":"")});this.internal.poster=b.extend({},{id:this.options.idPrefix+"_poster_"+this.count,jq:f});b.each(b.jPlayer.event,function(b,c){a.options[b]!==f&&(a.element.bind(c+".jPlayer",a.options[b]),a.options[b]=f)});this.require.audio=!1;this.require.video=!1;b.each(this.formats,function(b,c){a.require[a.format[c].media]=
!0});this.options=this.require.video?b.extend(!0,{},this.optionsVideo,this.options):b.extend(!0,{},this.optionsAudio,this.options);this._setSize();this.status.nativeVideoControls=this._uaBlocklist(this.options.nativeVideoControls);this.status.noFullWindow=this._uaBlocklist(this.options.noFullWindow);this.status.noVolume=this._uaBlocklist(this.options.noVolume);b.jPlayer.nativeFeatures.fullscreen.api.fullscreenEnabled&&this._fullscreenAddEventListeners();this._restrictNativeVideoControls();this.htmlElement.poster=
document.createElement("img");this.htmlElement.poster.id=this.internal.poster.id;this.htmlElement.poster.onload=function(){(!a.status.video||a.status.waitForPlay)&&a.internal.poster.jq.show()};this.element.append(this.htmlElement.poster);this.internal.poster.jq=b("#"+this.internal.poster.id);this.internal.poster.jq.css({width:this.status.width,height:this.status.height});this.internal.poster.jq.hide();this.internal.poster.jq.bind("click.jPlayer",function(){a._trigger(b.jPlayer.event.click)});this.html.audio.available=
!1;this.require.audio&&(this.htmlElement.audio=document.createElement("audio"),this.htmlElement.audio.id=this.internal.audio.id,this.html.audio.available=!!this.htmlElement.audio.canPlayType&&this._testCanPlayType(this.htmlElement.audio));this.html.video.available=!1;this.require.video&&(this.htmlElement.video=document.createElement("video"),this.htmlElement.video.id=this.internal.video.id,this.html.video.available=!!this.htmlElement.video.canPlayType&&this._testCanPlayType(this.htmlElement.video));
this.flash.available=this._checkForFlash(10.1);this.html.canPlay={};this.flash.canPlay={};b.each(this.formats,function(b,c){a.html.canPlay[c]=a.html[a.format[c].media].available&&""!==a.htmlElement[a.format[c].media].canPlayType(a.format[c].codec);a.flash.canPlay[c]=a.format[c].flashCanPlay&&a.flash.available});this.html.desired=!1;this.flash.desired=!1;b.each(this.solutions,function(c,d){if(0===c)a[d].desired=!0;else{var e=!1,f=!1;b.each(a.formats,function(b,c){a[a.solutions[0]].canPlay[c]&&("video"===
a.format[c].media?f=!0:e=!0)});a[d].desired=a.require.audio&&!e||a.require.video&&!f}});this.html.support={};this.flash.support={};b.each(this.formats,function(b,c){a.html.support[c]=a.html.canPlay[c]&&a.html.desired;a.flash.support[c]=a.flash.canPlay[c]&&a.flash.desired});this.html.used=!1;this.flash.used=!1;b.each(this.solutions,function(c,d){b.each(a.formats,function(b,c){if(a[d].support[c])return a[d].used=!0,!1})});this._resetActive();this._resetGate();this._cssSelectorAncestor(this.options.cssSelectorAncestor);
!this.html.used&&!this.flash.used?(this._error({type:b.jPlayer.error.NO_SOLUTION,context:"{solution:'"+this.options.solution+"', supplied:'"+this.options.supplied+"'}",message:b.jPlayer.errorMsg.NO_SOLUTION,hint:b.jPlayer.errorHint.NO_SOLUTION}),this.css.jq.noSolution.length&&this.css.jq.noSolution.show()):this.css.jq.noSolution.length&&this.css.jq.noSolution.hide();if(this.flash.used){var c,d="jQuery="+encodeURI(this.options.noConflict)+"&id="+encodeURI(this.internal.self.id)+"&vol="+this.options.volume+
"&muted="+this.options.muted;if(b.jPlayer.browser.msie&&(9>Number(b.jPlayer.browser.version)||9>b.jPlayer.browser.documentMode)){d=['<param name="movie" value="'+this.internal.flash.swf+'" />','<param name="FlashVars" value="'+d+'" />','<param name="allowScriptAccess" value="always" />','<param name="bgcolor" value="'+this.options.backgroundColor+'" />','<param name="wmode" value="'+this.options.wmode+'" />'];c=document.createElement('<object id="'+this.internal.flash.id+'" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="0" height="0" tabindex="-1"></object>');
for(var e=0;e<d.length;e++)c.appendChild(document.createElement(d[e]))}else e=function(a,b,c){var d=document.createElement("param");d.setAttribute("name",b);d.setAttribute("value",c);a.appendChild(d)},c=document.createElement("object"),c.setAttribute("id",this.internal.flash.id),c.setAttribute("name",this.internal.flash.id),c.setAttribute("data",this.internal.flash.swf),c.setAttribute("type","application/x-shockwave-flash"),c.setAttribute("width","1"),c.setAttribute("height","1"),c.setAttribute("tabindex",
"-1"),e(c,"flashvars",d),e(c,"allowscriptaccess","always"),e(c,"bgcolor",this.options.backgroundColor),e(c,"wmode",this.options.wmode);this.element.append(c);this.internal.flash.jq=b(c)}this.html.used&&(this.html.audio.available&&(this._addHtmlEventListeners(this.htmlElement.audio,this.html.audio),this.element.append(this.htmlElement.audio),this.internal.audio.jq=b("#"+this.internal.audio.id)),this.html.video.available&&(this._addHtmlEventListeners(this.htmlElement.video,this.html.video),this.element.append(this.htmlElement.video),
this.internal.video.jq=b("#"+this.internal.video.id),this.status.nativeVideoControls?this.internal.video.jq.css({width:this.status.width,height:this.status.height}):this.internal.video.jq.css({width:"0px",height:"0px"}),this.internal.video.jq.bind("click.jPlayer",function(){a._trigger(b.jPlayer.event.click)})));this.options.emulateHtml&&this._emulateHtmlBridge();this.html.used&&!this.flash.used&&setTimeout(function(){a.internal.ready=!0;a.version.flash="n/a";a._trigger(b.jPlayer.event.repeat);a._trigger(b.jPlayer.event.ready)},
100);this._updateNativeVideoControls();this.css.jq.videoPlay.length&&this.css.jq.videoPlay.hide();b.jPlayer.prototype.count++},destroy:function(){this.clearMedia();this._removeUiClass();this.css.jq.currentTime.length&&this.css.jq.currentTime.text("");this.css.jq.duration.length&&this.css.jq.duration.text("");b.each(this.css.jq,function(a,b){b.length&&b.unbind(".jPlayer")});this.internal.poster.jq.unbind(".jPlayer");this.internal.video.jq&&this.internal.video.jq.unbind(".jPlayer");this._fullscreenRemoveEventListeners();
this===b.jPlayer.focus&&(b.jPlayer.focus=null);this.options.emulateHtml&&this._destroyHtmlBridge();this.element.removeData("jPlayer");this.element.unbind(".jPlayer");this.element.empty();delete this.instances[this.internal.instance]},enable:function(){},disable:function(){},_testCanPlayType:function(a){try{return a.canPlayType(this.format.mp3.codec),!0}catch(b){return!1}},_uaBlocklist:function(a){var c=navigator.userAgent.toLowerCase(),d=!1;b.each(a,function(a,b){if(b&&b.test(c))return d=!0,!1});
return d},_restrictNativeVideoControls:function(){this.require.audio&&this.status.nativeVideoControls&&(this.status.nativeVideoControls=!1,this.status.noFullWindow=!0)},_updateNativeVideoControls:function(){this.html.video.available&&this.html.used&&(this.htmlElement.video.controls=this.status.nativeVideoControls,this._updateAutohide(),this.status.nativeVideoControls&&this.require.video?(this.internal.poster.jq.hide(),this.internal.video.jq.css({width:this.status.width,height:this.status.height})):
this.status.waitForPlay&&this.status.video&&(this.internal.poster.jq.show(),this.internal.video.jq.css({width:"0px",height:"0px"})))},_addHtmlEventListeners:function(a,c){var d=this;a.preload=this.options.preload;a.muted=this.options.muted;a.volume=this.options.volume;a.addEventListener("progress",function(){c.gate&&(d.internal.cmdsIgnored&&0<this.readyState&&(d.internal.cmdsIgnored=!1),d._getHtmlStatus(a),d._updateInterface(),d._trigger(b.jPlayer.event.progress))},!1);a.addEventListener("timeupdate",
function(){c.gate&&(d._getHtmlStatus(a),d._updateInterface(),d._trigger(b.jPlayer.event.timeupdate))},!1);a.addEventListener("durationchange",function(){c.gate&&(d._getHtmlStatus(a),d._updateInterface(),d._trigger(b.jPlayer.event.durationchange))},!1);a.addEventListener("play",function(){c.gate&&(d._updateButtons(!0),d._html_checkWaitForPlay(),d._trigger(b.jPlayer.event.play))},!1);a.addEventListener("playing",function(){c.gate&&(d._updateButtons(!0),d._seeked(),d._trigger(b.jPlayer.event.playing))},
!1);a.addEventListener("pause",function(){c.gate&&(d._updateButtons(!1),d._trigger(b.jPlayer.event.pause))},!1);a.addEventListener("waiting",function(){c.gate&&(d._seeking(),d._trigger(b.jPlayer.event.waiting))},!1);a.addEventListener("seeking",function(){c.gate&&(d._seeking(),d._trigger(b.jPlayer.event.seeking))},!1);a.addEventListener("seeked",function(){c.gate&&(d._seeked(),d._trigger(b.jPlayer.event.seeked))},!1);a.addEventListener("volumechange",function(){c.gate&&(d.options.volume=a.volume,
d.options.muted=a.muted,d._updateMute(),d._updateVolume(),d._trigger(b.jPlayer.event.volumechange))},!1);a.addEventListener("suspend",function(){c.gate&&(d._seeked(),d._trigger(b.jPlayer.event.suspend))},!1);a.addEventListener("ended",function(){c.gate&&(b.jPlayer.browser.webkit||(d.htmlElement.media.currentTime=0),d.htmlElement.media.pause(),d._updateButtons(!1),d._getHtmlStatus(a,!0),d._updateInterface(),d._trigger(b.jPlayer.event.ended))},!1);a.addEventListener("error",function(){c.gate&&(d._updateButtons(!1),
d._seeked(),d.status.srcSet&&(clearTimeout(d.internal.htmlDlyCmdId),d.status.waitForLoad=!0,d.status.waitForPlay=!0,d.status.video&&!d.status.nativeVideoControls&&d.internal.video.jq.css({width:"0px",height:"0px"}),d._validString(d.status.media.poster)&&!d.status.nativeVideoControls&&d.internal.poster.jq.show(),d.css.jq.videoPlay.length&&d.css.jq.videoPlay.show(),d._error({type:b.jPlayer.error.URL,context:d.status.src,message:b.jPlayer.errorMsg.URL,hint:b.jPlayer.errorHint.URL})))},!1);b.each(b.jPlayer.htmlEvent,
function(e,g){a.addEventListener(this,function(){c.gate&&d._trigger(b.jPlayer.event[g])},!1)})},_getHtmlStatus:function(a,b){var d=0,e=0,g=0,f=0;isFinite(a.duration)&&(this.status.duration=a.duration);d=a.currentTime;e=0<this.status.duration?100*d/this.status.duration:0;"object"===typeof a.seekable&&0<a.seekable.length?(g=0<this.status.duration?100*a.seekable.end(a.seekable.length-1)/this.status.duration:100,f=0<this.status.duration?100*a.currentTime/a.seekable.end(a.seekable.length-1):0):(g=100,
f=e);b&&(e=f=d=0);this.status.seekPercent=g;this.status.currentPercentRelative=f;this.status.currentPercentAbsolute=e;this.status.currentTime=d;this.status.videoWidth=a.videoWidth;this.status.videoHeight=a.videoHeight;this.status.readyState=a.readyState;this.status.networkState=a.networkState;this.status.playbackRate=a.playbackRate;this.status.ended=a.ended},_resetStatus:function(){this.status=b.extend({},this.status,b.jPlayer.prototype.status)},_trigger:function(a,c,d){a=b.Event(a);a.jPlayer={};
a.jPlayer.version=b.extend({},this.version);a.jPlayer.options=b.extend(!0,{},this.options);a.jPlayer.status=b.extend(!0,{},this.status);a.jPlayer.html=b.extend(!0,{},this.html);a.jPlayer.flash=b.extend(!0,{},this.flash);c&&(a.jPlayer.error=b.extend({},c));d&&(a.jPlayer.warning=b.extend({},d));this.element.trigger(a)},jPlayerFlashEvent:function(a,c){if(a===b.jPlayer.event.ready)if(this.internal.ready){if(this.flash.gate){if(this.status.srcSet){var d=this.status.currentTime,e=this.status.paused;this.setMedia(this.status.media);
0<d&&(e?this.pause(d):this.play(d))}this._trigger(b.jPlayer.event.flashreset)}}else this.internal.ready=!0,this.internal.flash.jq.css({width:"0px",height:"0px"}),this.version.flash=c.version,this.version.needFlash!==this.version.flash&&this._error({type:b.jPlayer.error.VERSION,context:this.version.flash,message:b.jPlayer.errorMsg.VERSION+this.version.flash,hint:b.jPlayer.errorHint.VERSION}),this._trigger(b.jPlayer.event.repeat),this._trigger(a);if(this.flash.gate)switch(a){case b.jPlayer.event.progress:this._getFlashStatus(c);
this._updateInterface();this._trigger(a);break;case b.jPlayer.event.timeupdate:this._getFlashStatus(c);this._updateInterface();this._trigger(a);break;case b.jPlayer.event.play:this._seeked();this._updateButtons(!0);this._trigger(a);break;case b.jPlayer.event.pause:this._updateButtons(!1);this._trigger(a);break;case b.jPlayer.event.ended:this._updateButtons(!1);this._trigger(a);break;case b.jPlayer.event.click:this._trigger(a);break;case b.jPlayer.event.error:this.status.waitForLoad=!0;this.status.waitForPlay=
!0;this.status.video&&this.internal.flash.jq.css({width:"0px",height:"0px"});this._validString(this.status.media.poster)&&this.internal.poster.jq.show();this.css.jq.videoPlay.length&&this.status.video&&this.css.jq.videoPlay.show();this.status.video?this._flash_setVideo(this.status.media):this._flash_setAudio(this.status.media);this._updateButtons(!1);this._error({type:b.jPlayer.error.URL,context:c.src,message:b.jPlayer.errorMsg.URL,hint:b.jPlayer.errorHint.URL});break;case b.jPlayer.event.seeking:this._seeking();
this._trigger(a);break;case b.jPlayer.event.seeked:this._seeked();this._trigger(a);break;case b.jPlayer.event.ready:break;default:this._trigger(a)}return!1},_getFlashStatus:function(a){this.status.seekPercent=a.seekPercent;this.status.currentPercentRelative=a.currentPercentRelative;this.status.currentPercentAbsolute=a.currentPercentAbsolute;this.status.currentTime=a.currentTime;this.status.duration=a.duration;this.status.videoWidth=a.videoWidth;this.status.videoHeight=a.videoHeight;this.status.readyState=
4;this.status.networkState=0;this.status.playbackRate=1;this.status.ended=!1},_updateButtons:function(a){a===f?a=!this.status.paused:this.status.paused=!a;this.css.jq.play.length&&this.css.jq.pause.length&&(a?(this.css.jq.play.hide(),this.css.jq.pause.show()):(this.css.jq.play.show(),this.css.jq.pause.hide()));this.css.jq.restoreScreen.length&&this.css.jq.fullScreen.length&&(this.status.noFullWindow?(this.css.jq.fullScreen.hide(),this.css.jq.restoreScreen.hide()):this.options.fullWindow?(this.css.jq.fullScreen.hide(),
this.css.jq.restoreScreen.show()):(this.css.jq.fullScreen.show(),this.css.jq.restoreScreen.hide()));this.css.jq.repeat.length&&this.css.jq.repeatOff.length&&(this.options.loop?(this.css.jq.repeat.hide(),this.css.jq.repeatOff.show()):(this.css.jq.repeat.show(),this.css.jq.repeatOff.hide()))},_updateInterface:function(){this.css.jq.seekBar.length&&this.css.jq.seekBar.width(this.status.seekPercent+"%");this.css.jq.playBar.length&&(this.options.smoothPlayBar?this.css.jq.playBar.stop().animate({width:this.status.currentPercentAbsolute+
"%"},250,"linear"):this.css.jq.playBar.width(this.status.currentPercentRelative+"%"));this.css.jq.currentTime.length&&this.css.jq.currentTime.text(this._convertTime(this.status.currentTime));this.css.jq.duration.length&&this.css.jq.duration.text(this._convertTime(this.status.duration))},_convertTime:l.prototype.time,_seeking:function(){this.css.jq.seekBar.length&&this.css.jq.seekBar.addClass("jp-seeking-bg")},_seeked:function(){this.css.jq.seekBar.length&&this.css.jq.seekBar.removeClass("jp-seeking-bg")},
_resetGate:function(){this.html.audio.gate=!1;this.html.video.gate=!1;this.flash.gate=!1},_resetActive:function(){this.html.active=!1;this.flash.active=!1},setMedia:function(a){var c=this,d=!1,e=this.status.media.poster!==a.poster;this._resetMedia();this._resetGate();this._resetActive();b.each(this.formats,function(e,f){var j="video"===c.format[f].media;b.each(c.solutions,function(b,e){if(c[e].support[f]&&c._validString(a[f])){var g="html"===e;j?(g?(c.html.video.gate=!0,c._html_setVideo(a),c.html.active=
!0):(c.flash.gate=!0,c._flash_setVideo(a),c.flash.active=!0),c.css.jq.videoPlay.length&&c.css.jq.videoPlay.show(),c.status.video=!0):(g?(c.html.audio.gate=!0,c._html_setAudio(a),c.html.active=!0):(c.flash.gate=!0,c._flash_setAudio(a),c.flash.active=!0),c.css.jq.videoPlay.length&&c.css.jq.videoPlay.hide(),c.status.video=!1);d=!0;return!1}});if(d)return!1});if(d){if((!this.status.nativeVideoControls||!this.html.video.gate)&&this._validString(a.poster))e?this.htmlElement.poster.src=a.poster:this.internal.poster.jq.show();
this.status.srcSet=!0;this.status.media=b.extend({},a);this._updateButtons(!1);this._updateInterface()}else this._error({type:b.jPlayer.error.NO_SUPPORT,context:"{supplied:'"+this.options.supplied+"'}",message:b.jPlayer.errorMsg.NO_SUPPORT,hint:b.jPlayer.errorHint.NO_SUPPORT})},_resetMedia:function(){this._resetStatus();this._updateButtons(!1);this._updateInterface();this._seeked();this.internal.poster.jq.hide();clearTimeout(this.internal.htmlDlyCmdId);this.html.active?this._html_resetMedia():this.flash.active&&
this._flash_resetMedia()},clearMedia:function(){this._resetMedia();this.html.active?this._html_clearMedia():this.flash.active&&this._flash_clearMedia();this._resetGate();this._resetActive()},load:function(){this.status.srcSet?this.html.active?this._html_load():this.flash.active&&this._flash_load():this._urlNotSetError("load")},focus:function(){this.options.keyEnabled&&(b.jPlayer.focus=this)},play:function(a){a="number"===typeof a?a:NaN;this.status.srcSet?(this.focus(),this.html.active?this._html_play(a):
this.flash.active&&this._flash_play(a)):this._urlNotSetError("play")},videoPlay:function(){this.play()},pause:function(a){a="number"===typeof a?a:NaN;this.status.srcSet?this.html.active?this._html_pause(a):this.flash.active&&this._flash_pause(a):this._urlNotSetError("pause")},pauseOthers:function(){var a=this;b.each(this.instances,function(b,d){a.element!==d&&d.data("jPlayer").status.srcSet&&d.jPlayer("pause")})},stop:function(){this.status.srcSet?this.html.active?this._html_pause(0):this.flash.active&&
this._flash_pause(0):this._urlNotSetError("stop")},playHead:function(a){a=this._limitValue(a,0,100);this.status.srcSet?this.html.active?this._html_playHead(a):this.flash.active&&this._flash_playHead(a):this._urlNotSetError("playHead")},_muted:function(a){this.options.muted=a;this.html.used&&this._html_mute(a);this.flash.used&&this._flash_mute(a);!this.html.video.gate&&!this.html.audio.gate&&(this._updateMute(a),this._updateVolume(this.options.volume),this._trigger(b.jPlayer.event.volumechange))},
mute:function(a){a=a===f?!0:!!a;this._muted(a)},unmute:function(a){a=a===f?!0:!!a;this._muted(!a)},_updateMute:function(a){a===f&&(a=this.options.muted);this.css.jq.mute.length&&this.css.jq.unmute.length&&(this.status.noVolume?(this.css.jq.mute.hide(),this.css.jq.unmute.hide()):a?(this.css.jq.mute.hide(),this.css.jq.unmute.show()):(this.css.jq.mute.show(),this.css.jq.unmute.hide()))},volume:function(a){a=this._limitValue(a,0,1);this.options.volume=a;this.html.used&&this._html_volume(a);this.flash.used&&
this._flash_volume(a);!this.html.video.gate&&!this.html.audio.gate&&(this._updateVolume(a),this._trigger(b.jPlayer.event.volumechange))},volumeBar:function(a){if(this.css.jq.volumeBar.length){var c=b(a.currentTarget),d=c.offset(),e=a.pageX-d.left,g=c.width();a=c.height()-a.pageY+d.top;c=c.height();this.options.verticalVolume?this.volume(a/c):this.volume(e/g)}this.options.muted&&this._muted(!1)},volumeBarValue:function(){},_updateVolume:function(a){a===f&&(a=this.options.volume);a=this.options.muted?
0:a;this.status.noVolume?(this.css.jq.volumeBar.length&&this.css.jq.volumeBar.hide(),this.css.jq.volumeBarValue.length&&this.css.jq.volumeBarValue.hide(),this.css.jq.volumeMax.length&&this.css.jq.volumeMax.hide()):(this.css.jq.volumeBar.length&&this.css.jq.volumeBar.show(),this.css.jq.volumeBarValue.length&&(this.css.jq.volumeBarValue.show(),this.css.jq.volumeBarValue[this.options.verticalVolume?"height":"width"](100*a+"%")),this.css.jq.volumeMax.length&&this.css.jq.volumeMax.show())},volumeMax:function(){this.volume(1);
this.options.muted&&this._muted(!1)},_cssSelectorAncestor:function(a){var c=this;this.options.cssSelectorAncestor=a;this._removeUiClass();this.ancestorJq=a?b(a):[];a&&1!==this.ancestorJq.length&&this._warning({type:b.jPlayer.warning.CSS_SELECTOR_COUNT,context:a,message:b.jPlayer.warningMsg.CSS_SELECTOR_COUNT+this.ancestorJq.length+" found for cssSelectorAncestor.",hint:b.jPlayer.warningHint.CSS_SELECTOR_COUNT});this._addUiClass();b.each(this.options.cssSelector,function(a,b){c._cssSelector(a,b)});
this._updateInterface();this._updateButtons();this._updateAutohide();this._updateVolume();this._updateMute()},_cssSelector:function(a,c){var d=this;"string"===typeof c?b.jPlayer.prototype.options.cssSelector[a]?(this.css.jq[a]&&this.css.jq[a].length&&this.css.jq[a].unbind(".jPlayer"),this.options.cssSelector[a]=c,this.css.cs[a]=this.options.cssSelectorAncestor+" "+c,this.css.jq[a]=c?b(this.css.cs[a]):[],this.css.jq[a].length&&this.css.jq[a].bind("click.jPlayer",function(c){c.preventDefault();d[a](c);
b(this).blur()}),c&&1!==this.css.jq[a].length&&this._warning({type:b.jPlayer.warning.CSS_SELECTOR_COUNT,context:this.css.cs[a],message:b.jPlayer.warningMsg.CSS_SELECTOR_COUNT+this.css.jq[a].length+" found for "+a+" method.",hint:b.jPlayer.warningHint.CSS_SELECTOR_COUNT})):this._warning({type:b.jPlayer.warning.CSS_SELECTOR_METHOD,context:a,message:b.jPlayer.warningMsg.CSS_SELECTOR_METHOD,hint:b.jPlayer.warningHint.CSS_SELECTOR_METHOD}):this._warning({type:b.jPlayer.warning.CSS_SELECTOR_STRING,context:c,
message:b.jPlayer.warningMsg.CSS_SELECTOR_STRING,hint:b.jPlayer.warningHint.CSS_SELECTOR_STRING})},seekBar:function(a){if(this.css.jq.seekBar.length){var c=b(a.currentTarget),d=c.offset();a=a.pageX-d.left;c=c.width();this.playHead(100*a/c)}},playBar:function(){},repeat:function(){this._loop(!0)},repeatOff:function(){this._loop(!1)},_loop:function(a){this.options.loop!==a&&(this.options.loop=a,this._updateButtons(),this._trigger(b.jPlayer.event.repeat))},currentTime:function(){},duration:function(){},
gui:function(){},noSolution:function(){},option:function(a,c){var d=a;if(0===arguments.length)return b.extend(!0,{},this.options);if("string"===typeof a){var e=a.split(".");if(c===f){for(var d=b.extend(!0,{},this.options),g=0;g<e.length;g++)if(d[e[g]]!==f)d=d[e[g]];else return this._warning({type:b.jPlayer.warning.OPTION_KEY,context:a,message:b.jPlayer.warningMsg.OPTION_KEY,hint:b.jPlayer.warningHint.OPTION_KEY}),f;return d}for(var g=d={},h=0;h<e.length;h++)h<e.length-1?(g[e[h]]={},g=g[e[h]]):g[e[h]]=
c}this._setOptions(d);return this},_setOptions:function(a){var c=this;b.each(a,function(a,b){c._setOption(a,b)});return this},_setOption:function(a,c){var d=this;switch(a){case "volume":this.volume(c);break;case "muted":this._muted(c);break;case "cssSelectorAncestor":this._cssSelectorAncestor(c);break;case "cssSelector":b.each(c,function(a,b){d._cssSelector(a,b)});break;case "fullScreen":if(this.options[a]!==c){var e=b.jPlayer.nativeFeatures.fullscreen.used.webkitVideo;if(!e||e&&!this.status.waitForPlay)e||
(this.options[a]=c),c?this._requestFullscreen():this._exitFullscreen(),e||this._setOption("fullWindow",c)}break;case "fullWindow":this.options[a]!==c&&(this._removeUiClass(),this.options[a]=c,this._refreshSize());break;case "size":!this.options.fullWindow&&this.options[a].cssClass!==c.cssClass&&this._removeUiClass();this.options[a]=b.extend({},this.options[a],c);this._refreshSize();break;case "sizeFull":this.options.fullWindow&&this.options[a].cssClass!==c.cssClass&&this._removeUiClass();this.options[a]=
b.extend({},this.options[a],c);this._refreshSize();break;case "autohide":this.options[a]=b.extend({},this.options[a],c);this._updateAutohide();break;case "loop":this._loop(c);break;case "nativeVideoControls":this.options[a]=b.extend({},this.options[a],c);this.status.nativeVideoControls=this._uaBlocklist(this.options.nativeVideoControls);this._restrictNativeVideoControls();this._updateNativeVideoControls();break;case "noFullWindow":this.options[a]=b.extend({},this.options[a],c);this.status.nativeVideoControls=
this._uaBlocklist(this.options.nativeVideoControls);this.status.noFullWindow=this._uaBlocklist(this.options.noFullWindow);this._restrictNativeVideoControls();this._updateButtons();break;case "noVolume":this.options[a]=b.extend({},this.options[a],c);this.status.noVolume=this._uaBlocklist(this.options.noVolume);this._updateVolume();this._updateMute();break;case "emulateHtml":this.options[a]!==c&&((this.options[a]=c)?this._emulateHtmlBridge():this._destroyHtmlBridge());break;case "timeFormat":this.options[a]=
b.extend({},this.options[a],c);break;case "keyEnabled":this.options[a]=c;!c&&this===b.jPlayer.focus&&(b.jPlayer.focus=null);break;case "keyBindings":this.options[a]=b.extend(!0,{},this.options[a],c);break;case "audioFullScreen":this.options[a]=c}return this},_refreshSize:function(){this._setSize();this._addUiClass();this._updateSize();this._updateButtons();this._updateAutohide();this._trigger(b.jPlayer.event.resize)},_setSize:function(){this.options.fullWindow?(this.status.width=this.options.sizeFull.width,
this.status.height=this.options.sizeFull.height,this.status.cssClass=this.options.sizeFull.cssClass):(this.status.width=this.options.size.width,this.status.height=this.options.size.height,this.status.cssClass=this.options.size.cssClass);this.element.css({width:this.status.width,height:this.status.height})},_addUiClass:function(){this.ancestorJq.length&&this.ancestorJq.addClass(this.status.cssClass)},_removeUiClass:function(){this.ancestorJq.length&&this.ancestorJq.removeClass(this.status.cssClass)},
_updateSize:function(){this.internal.poster.jq.css({width:this.status.width,height:this.status.height});!this.status.waitForPlay&&this.html.active&&this.status.video||this.html.video.available&&this.html.used&&this.status.nativeVideoControls?this.internal.video.jq.css({width:this.status.width,height:this.status.height}):!this.status.waitForPlay&&(this.flash.active&&this.status.video)&&this.internal.flash.jq.css({width:this.status.width,height:this.status.height})},_updateAutohide:function(){var a=
this,b=function(){a.css.jq.gui.fadeIn(a.options.autohide.fadeIn,function(){clearTimeout(a.internal.autohideId);a.internal.autohideId=setTimeout(function(){a.css.jq.gui.fadeOut(a.options.autohide.fadeOut)},a.options.autohide.hold)})};this.css.jq.gui.length&&(this.css.jq.gui.stop(!0,!0),clearTimeout(this.internal.autohideId),this.element.unbind(".jPlayerAutohide"),this.css.jq.gui.unbind(".jPlayerAutohide"),this.status.nativeVideoControls?this.css.jq.gui.hide():this.options.fullWindow&&this.options.autohide.full||
!this.options.fullWindow&&this.options.autohide.restored?(this.element.bind("mousemove.jPlayer.jPlayerAutohide",b),this.css.jq.gui.bind("mousemove.jPlayer.jPlayerAutohide",b),this.css.jq.gui.hide()):this.css.jq.gui.show())},fullScreen:function(){this._setOption("fullScreen",!0)},restoreScreen:function(){this._setOption("fullScreen",!1)},_fullscreenAddEventListeners:function(){var a=this,c=b.jPlayer.nativeFeatures.fullscreen;c.api.fullscreenEnabled&&c.event.fullscreenchange&&("function"!==typeof this.internal.fullscreenchangeHandler&&
(this.internal.fullscreenchangeHandler=function(){a._fullscreenchange()}),document.addEventListener(c.event.fullscreenchange,this.internal.fullscreenchangeHandler,!1))},_fullscreenRemoveEventListeners:function(){var a=b.jPlayer.nativeFeatures.fullscreen;this.internal.fullscreenchangeHandler&&document.addEventListener(a.event.fullscreenchange,this.internal.fullscreenchangeHandler,!1)},_fullscreenchange:function(){this.options.fullScreen&&!b.jPlayer.nativeFeatures.fullscreen.api.fullscreenElement()&&
this._setOption("fullScreen",!1)},_requestFullscreen:function(){var a=this.ancestorJq.length?this.ancestorJq[0]:this.element[0],c=b.jPlayer.nativeFeatures.fullscreen;c.used.webkitVideo&&(a=this.htmlElement.video);c.api.fullscreenEnabled&&c.api.requestFullscreen(a)},_exitFullscreen:function(){var a=b.jPlayer.nativeFeatures.fullscreen,c;a.used.webkitVideo&&(c=this.htmlElement.video);a.api.fullscreenEnabled&&a.api.exitFullscreen(c)},_html_initMedia:function(a){var c=b(this.htmlElement.media).empty();
b.each(a.track||[],function(a,b){var g=document.createElement("track");g.setAttribute("kind",b.kind?b.kind:"");g.setAttribute("src",b.src?b.src:"");g.setAttribute("srclang",b.srclang?b.srclang:"");g.setAttribute("label",b.label?b.label:"");b.def&&g.setAttribute("default",b.def);c.append(g)});this.htmlElement.media.src=this.status.src;"none"!==this.options.preload&&this._html_load();this._trigger(b.jPlayer.event.timeupdate)},_html_setFormat:function(a){var c=this;b.each(this.formats,function(b,e){if(c.html.support[e]&&
a[e])return c.status.src=a[e],c.status.format[e]=!0,c.status.formatType=e,!1})},_html_setAudio:function(a){this._html_setFormat(a);this.htmlElement.media=this.htmlElement.audio;this._html_initMedia(a)},_html_setVideo:function(a){this._html_setFormat(a);this.status.nativeVideoControls&&(this.htmlElement.video.poster=this._validString(a.poster)?a.poster:"");this.htmlElement.media=this.htmlElement.video;this._html_initMedia(a)},_html_resetMedia:function(){this.htmlElement.media&&(this.htmlElement.media.id===
this.internal.video.id&&!this.status.nativeVideoControls&&this.internal.video.jq.css({width:"0px",height:"0px"}),this.htmlElement.media.pause())},_html_clearMedia:function(){this.htmlElement.media&&(this.htmlElement.media.src="about:blank",this.htmlElement.media.load())},_html_load:function(){this.status.waitForLoad&&(this.status.waitForLoad=!1,this.htmlElement.media.load());clearTimeout(this.internal.htmlDlyCmdId)},_html_play:function(a){var b=this,d=this.htmlElement.media;this._html_load();if(isNaN(a))d.play();
else{this.internal.cmdsIgnored&&d.play();try{if(!d.seekable||"object"===typeof d.seekable&&0<d.seekable.length)d.currentTime=a,d.play();else throw 1;}catch(e){this.internal.htmlDlyCmdId=setTimeout(function(){b.play(a)},250);return}}this._html_checkWaitForPlay()},_html_pause:function(a){var b=this,d=this.htmlElement.media;0<a?this._html_load():clearTimeout(this.internal.htmlDlyCmdId);d.pause();if(!isNaN(a))try{if(!d.seekable||"object"===typeof d.seekable&&0<d.seekable.length)d.currentTime=a;else throw 1;
}catch(e){this.internal.htmlDlyCmdId=setTimeout(function(){b.pause(a)},250);return}0<a&&this._html_checkWaitForPlay()},_html_playHead:function(a){var b=this,d=this.htmlElement.media;this._html_load();try{if("object"===typeof d.seekable&&0<d.seekable.length)d.currentTime=a*d.seekable.end(d.seekable.length-1)/100;else if(0<d.duration&&!isNaN(d.duration))d.currentTime=a*d.duration/100;else throw"e";}catch(e){this.internal.htmlDlyCmdId=setTimeout(function(){b.playHead(a)},250);return}this.status.waitForLoad||
this._html_checkWaitForPlay()},_html_checkWaitForPlay:function(){this.status.waitForPlay&&(this.status.waitForPlay=!1,this.css.jq.videoPlay.length&&this.css.jq.videoPlay.hide(),this.status.video&&(this.internal.poster.jq.hide(),this.internal.video.jq.css({width:this.status.width,height:this.status.height})))},_html_volume:function(a){this.html.audio.available&&(this.htmlElement.audio.volume=a);this.html.video.available&&(this.htmlElement.video.volume=a)},_html_mute:function(a){this.html.audio.available&&
(this.htmlElement.audio.muted=a);this.html.video.available&&(this.htmlElement.video.muted=a)},_flash_setAudio:function(a){var c=this;try{b.each(this.formats,function(b,d){if(c.flash.support[d]&&a[d]){switch(d){case "m4a":case "fla":c._getMovie().fl_setAudio_m4a(a[d]);break;case "mp3":c._getMovie().fl_setAudio_mp3(a[d]);break;case "rtmpa":c._getMovie().fl_setAudio_rtmp(a[d])}c.status.src=a[d];c.status.format[d]=!0;c.status.formatType=d;return!1}}),"auto"===this.options.preload&&(this._flash_load(),
this.status.waitForLoad=!1)}catch(d){this._flashError(d)}},_flash_setVideo:function(a){var c=this;try{b.each(this.formats,function(b,d){if(c.flash.support[d]&&a[d]){switch(d){case "m4v":case "flv":c._getMovie().fl_setVideo_m4v(a[d]);break;case "rtmpv":c._getMovie().fl_setVideo_rtmp(a[d])}c.status.src=a[d];c.status.format[d]=!0;c.status.formatType=d;return!1}}),"auto"===this.options.preload&&(this._flash_load(),this.status.waitForLoad=!1)}catch(d){this._flashError(d)}},_flash_resetMedia:function(){this.internal.flash.jq.css({width:"0px",
height:"0px"});this._flash_pause(NaN)},_flash_clearMedia:function(){try{this._getMovie().fl_clearMedia()}catch(a){this._flashError(a)}},_flash_load:function(){try{this._getMovie().fl_load()}catch(a){this._flashError(a)}this.status.waitForLoad=!1},_flash_play:function(a){try{this._getMovie().fl_play(a)}catch(b){this._flashError(b)}this.status.waitForLoad=!1;this._flash_checkWaitForPlay()},_flash_pause:function(a){try{this._getMovie().fl_pause(a)}catch(b){this._flashError(b)}0<a&&(this.status.waitForLoad=
!1,this._flash_checkWaitForPlay())},_flash_playHead:function(a){try{this._getMovie().fl_play_head(a)}catch(b){this._flashError(b)}this.status.waitForLoad||this._flash_checkWaitForPlay()},_flash_checkWaitForPlay:function(){this.status.waitForPlay&&(this.status.waitForPlay=!1,this.css.jq.videoPlay.length&&this.css.jq.videoPlay.hide(),this.status.video&&(this.internal.poster.jq.hide(),this.internal.flash.jq.css({width:this.status.width,height:this.status.height})))},_flash_volume:function(a){try{this._getMovie().fl_volume(a)}catch(b){this._flashError(b)}},
_flash_mute:function(a){try{this._getMovie().fl_mute(a)}catch(b){this._flashError(b)}},_getMovie:function(){return document[this.internal.flash.id]},_getFlashPluginVersion:function(){var a=0,b;if(window.ActiveXObject)try{if(b=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")){var d=b.GetVariable("$version");d&&(d=d.split(" ")[1].split(","),a=parseInt(d[0],10)+"."+parseInt(d[1],10))}}catch(e){}else navigator.plugins&&0<navigator.mimeTypes.length&&(b=navigator.plugins["Shockwave Flash"])&&(a=navigator.plugins["Shockwave Flash"].description.replace(/.*\s(\d+\.\d+).*/,
"$1"));return 1*a},_checkForFlash:function(a){var b=!1;this._getFlashPluginVersion()>=a&&(b=!0);return b},_validString:function(a){return a&&"string"===typeof a},_limitValue:function(a,b,d){return a<b?b:a>d?d:a},_urlNotSetError:function(a){this._error({type:b.jPlayer.error.URL_NOT_SET,context:a,message:b.jPlayer.errorMsg.URL_NOT_SET,hint:b.jPlayer.errorHint.URL_NOT_SET})},_flashError:function(a){var c;c=this.internal.ready?"FLASH_DISABLED":"FLASH";this._error({type:b.jPlayer.error[c],context:this.internal.flash.swf,
message:b.jPlayer.errorMsg[c]+a.message,hint:b.jPlayer.errorHint[c]});this.internal.flash.jq.css({width:"1px",height:"1px"})},_error:function(a){this._trigger(b.jPlayer.event.error,a);this.options.errorAlerts&&this._alert("Error!"+(a.message?"\n\n"+a.message:"")+(a.hint?"\n\n"+a.hint:"")+"\n\nContext: "+a.context)},_warning:function(a){this._trigger(b.jPlayer.event.warning,f,a);this.options.warningAlerts&&this._alert("Warning!"+(a.message?"\n\n"+a.message:"")+(a.hint?"\n\n"+a.hint:"")+"\n\nContext: "+
a.context)},_alert:function(a){alert("jPlayer "+this.version.script+" : id='"+this.internal.self.id+"' : "+a)},_emulateHtmlBridge:function(){var a=this;b.each(b.jPlayer.emulateMethods.split(/\s+/g),function(b,d){a.internal.domNode[d]=function(b){a[d](b)}});b.each(b.jPlayer.event,function(c,d){var e=!0;b.each(b.jPlayer.reservedEvent.split(/\s+/g),function(a,b){if(b===c)return e=!1});e&&a.element.bind(d+".jPlayer.jPlayerHtml",function(){a._emulateHtmlUpdate();var b=document.createEvent("Event");b.initEvent(c,
!1,!0);a.internal.domNode.dispatchEvent(b)})})},_emulateHtmlUpdate:function(){var a=this;b.each(b.jPlayer.emulateStatus.split(/\s+/g),function(b,d){a.internal.domNode[d]=a.status[d]});b.each(b.jPlayer.emulateOptions.split(/\s+/g),function(b,d){a.internal.domNode[d]=a.options[d]})},_destroyHtmlBridge:function(){var a=this;this.element.unbind(".jPlayerHtml");b.each((b.jPlayer.emulateMethods+" "+b.jPlayer.emulateStatus+" "+b.jPlayer.emulateOptions).split(/\s+/g),function(b,d){delete a.internal.domNode[d]})}};
b.jPlayer.error={FLASH:"e_flash",FLASH_DISABLED:"e_flash_disabled",NO_SOLUTION:"e_no_solution",NO_SUPPORT:"e_no_support",URL:"e_url",URL_NOT_SET:"e_url_not_set",VERSION:"e_version"};b.jPlayer.errorMsg={FLASH:"jPlayer's Flash fallback is not configured correctly, or a command was issued before the jPlayer Ready event. Details: ",FLASH_DISABLED:"jPlayer's Flash fallback has been disabled by the browser due to the CSS rules you have used. Details: ",NO_SOLUTION:"No solution can be found by jPlayer in this browser. Neither HTML nor Flash can be used.",
NO_SUPPORT:"It is not possible to play any media format provided in setMedia() on this browser using your current options.",URL:"Media URL could not be loaded.",URL_NOT_SET:"Attempt to issue media playback commands, while no media url is set.",VERSION:"jPlayer "+b.jPlayer.prototype.version.script+" needs Jplayer.swf version "+b.jPlayer.prototype.version.needFlash+" but found "};b.jPlayer.errorHint={FLASH:"Check your swfPath option and that Jplayer.swf is there.",FLASH_DISABLED:"Check that you have not display:none; the jPlayer entity or any ancestor.",
NO_SOLUTION:"Review the jPlayer options: support and supplied.",NO_SUPPORT:"Video or audio formats defined in the supplied option are missing.",URL:"Check media URL is valid.",URL_NOT_SET:"Use setMedia() to set the media URL.",VERSION:"Update jPlayer files."};b.jPlayer.warning={CSS_SELECTOR_COUNT:"e_css_selector_count",CSS_SELECTOR_METHOD:"e_css_selector_method",CSS_SELECTOR_STRING:"e_css_selector_string",OPTION_KEY:"e_option_key"};b.jPlayer.warningMsg={CSS_SELECTOR_COUNT:"The number of css selectors found did not equal one: ",
CSS_SELECTOR_METHOD:"The methodName given in jPlayer('cssSelector') is not a valid jPlayer method.",CSS_SELECTOR_STRING:"The methodCssSelector given in jPlayer('cssSelector') is not a String or is empty.",OPTION_KEY:"The option requested in jPlayer('option') is undefined."};b.jPlayer.warningHint={CSS_SELECTOR_COUNT:"Check your css selector and the ancestor.",CSS_SELECTOR_METHOD:"Check your method name.",CSS_SELECTOR_STRING:"Check your css selector is a string.",OPTION_KEY:"Check your option name."}});

6
modules/jplayer/jquery.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View file

@ -45,6 +45,7 @@ switch ($_REQUEST['action']) {
$new = $_POST['type'];
break;
case 'html5_player':
case 'html5_player_embedded':
$new = $_POST['type'];
// Rien a faire
break;

View file

@ -27,7 +27,7 @@
<script language="javascript" type="text/javascript">
<!-- begin
function PlayerPopUp(URL) {
window.open(URL, 'HTML5_player', 'width=700,height=210,scrollbars=0,toolbar=0,location=0,directories=0,status=0,resizable=0');
window.open(URL, 'HTML5_player', 'width=730,height=285,scrollbars=0,toolbar=0,location=0,directories=0,status=0,resizable=0');
window.location = '<?php echo return_referer() ?>';
return false;
}

View file

@ -0,0 +1,44 @@
<?php
/* vim:set tabstop=8 softtabstop=8 shiftwidth=8 noexpandtab: */
/**
*
* LICENSE: GNU General Public License, version 2 (GPLv2)
* Copyright 2001 - 2013 Ampache.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License v2
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
?>
<html>
<head>
<title><?php echo Config::get('site_title'); ?></title>
<script language="javascript" type="text/javascript">
function PlayerFrame(URL) {
var ff = parent.parent.document.getElementById('frame_footer');
var maindiv = parent.parent.document.getElementById('maindiv');
if (ff.getAttribute('className') != 'frame_footer_visible') {
ff.setAttribute('className', 'frame_footer_visible');
ff.setAttribute('class', 'frame_footer_visible');
maindiv.style.height = (parent.parent.innerHeight - 105) + "px";
}
ff.setAttribute('src', URL);
return false;
}
</script>
</head>
<body onLoad="javascript:PlayerFrame('<?php echo Config::get('web_path')?>/html5_player_embedded.php<?php echo '?playlist_id=' . $this->id ?>');">
</body>
</html>

View file

@ -51,7 +51,7 @@ if (Config::get('use_rss')) { ?>
<div id="maincontainer">
<div id="header"><!-- This is the header -->
<h1 id="headerlogo">
<a href="<?php echo Config::get('web_path'); ?>">
<a href="<?php echo Config::get('web_path') . ((Config::get('iframes')) ? '/?framed=1' : ''); ?>">
<img src="<?php echo $web_path; ?><?php echo Config::get('theme_path'); ?>/images/ampache.png" title="<?php echo Config::get('site_title'); ?>" alt="<?php echo Config::get('site_title'); ?>" />
</a>
</h1>

View file

@ -1,102 +0,0 @@
/* vim:set softtabstop=4 shiftwidth=4 expandtab: */
/**
*
* LICENSE: GNU General Public License, version 2 (GPLv2)
* Copyright 2001 - 2013 Ampache.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License v2
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#html5_player #albumart img
{
width: 200px;
float: left;
margin: 5px;
}
#html5_player #title
{
padding-top: 5px;
}
#html5_player #artist, #html5_player #album
{
display: inline;
}
#html5_player #artist:before
{
content: ' by ';
}
#html5_player #progress_text
{
margin: 10px 0px 10px 0px;
}
#html5_player #stop, #html5_player #play,#html5_player #pause,#html5_player #next,#html5_player #previous,#html5_player #clear_search
{
display: inline;
border: thin solid black;
cursor: pointer;
padding: 2px;
margin-right: 5px;
}
#html5_player #playlist
{
overflow-x: hidden;
overflow-y: scroll;
position: absolute;
top: 105px;
left: 210px;
right: 5px;
bottom: 5px;
padding: 5px 0px;
}
#html5_player #playlist li
{
position: relative;
cursor: pointer;
}
#html5_player #playlist li[data-tooltip]::before {
content: attr(data-tooltip);
font-size: 10px;
position: absolute;
z-index: 999;
right: 0px;
top: 0px;
padding: 0px 5px;
opacity: 0;
transition: opacity 1.4s ease-out;
}
#html5_player #playlist li[data-tooltip]:hover::before {
opacity: 1;
}
#html5_player #playlist li[data-queue-id]::after {
content: " [" attr(data-queue-id) "]";
}
#html5_player #playlist li.playing
{
font-weight: bold;
}
#html5_player #stop.inactive, #html5_player #pause.inactive, #html5_player #play.inactive
{
display: none;
}
#html5_player #search
{
top: 61px;
right: 1px;
position: absolute;
}
#html5_player #search input
{
background: transparent;
}

View file

@ -0,0 +1,738 @@
/*
* Skin for jPlayer Plugin (jQuery JavaScript Library)
* http://www.jplayer.org
*
* Skin Name: Midnight Black
*
* Copyright (c) 2010-2012 Happyworm Ltd
* Dual licensed under the MIT and GPL licenses.
* - http://www.opensource.org/licenses/mit-license.php
* - http://www.gnu.org/copyleft/gpl.html
*
* Author: Per Sandström (https://github.com/persand)
* Maintainer: Kasim Ahmic (https://github.com/TheInfection)
* Skin Version: 2.6.3 (jPlayer 2.1.x, 2.2.x, 2.3.x, 2.4.x)
* Date: October 2nd, 2013
*/
body {
background-color: rgb(25, 25, 25);
}
div.jp-area {
margin-left: auto;
margin-right: auto;
width: 500px;
min-width: 500px;
}
a:active, a:focus {
outline: none; /* To keep Google Chrome from adding that ugly yellow border/outlune on buttons when clicked */
}
div.jp-audio,
div.jp-audio-stream,
div.jp-video {
/* Edit the font-size to counteract inherited font sizing.
* Eg. 1.25em = 1 / 0.8em
*/
font-size: 1.25em; /* 1.25em for testing in site pages */ /* No parent CSS that can effect the size in the demos ZIP */
font-family: 'Verdana', Arial, sans-serif;
line-height: 1.6;
color: #999;
border:1px solid #191919;
background-color: #eee;
}
div.jp-audio {
width: 480px;
}
div.jp-audio-stream {
width: 150px;
}
div.jp-video-270p {
width: 480px;
}
div.jp-video-360p {
width: 640px;
}
div.jp-video-full {
/* Rules for IE6 (full-screen) */
width: 480px;
height: 270px;
/* Rules for IE7 (full-screen) - Otherwise the relative container causes other page items that are not position:static (default) to appear over the video/gui. */
position: static !important;
position: relative;
}
/* The z-index rule is defined in this manner to enable Popcorn plugins that add overlays to video area. EG. Subtitles. */
div.jp-video-full div div {
z-index: 1000;
}
div.jp-video-full div.jp-jplayer {
top: 0;
left: 0;
position: fixed !important; position: relative; /* Rules for IE6 (full-screen) */
overflow: hidden;
}
div.jp-video-full div.jp-gui {
position: fixed !important; position: static; /* Rules for IE6 (full-screen) */
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 1001; /* 1 layer above the others. */
}
div.jp-video-full div.jp-interface {
position: absolute !important; position: relative; /* Rules for IE6 (full-screen) */
bottom: 0;
left: 0;
}
div.jp-interface {
position: relative;
background: #191919 url("../modules/jplayer/jplayer.midnight.black.interface.png") repeat-x;
width: 100%;
z-index: 9999;
}
div.jp-audio div.jp-type-single div.jp-interface {
height: 75px;
}
div.jp-audio div.jp-type-playlist div.jp-interface {
height: 70px;
}
div.jp-audio-stream div.jp-type-single div.jp-interface {
height: 50px;
}
div.jp-video div.jp-interface {
border-top: 1px solid #191919;
}
/* @group CONTROLS */
div.jp-controls-holder {
clear: both;
width: 440px;
margin: 0 auto;
position: relative;
overflow: hidden;
top: -8px; /* This negative value depends on the size of the text in jp-currentTime and jp-duration */
}
div.jp-interface ul.jp-controls {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
}
div.jp-audio ul.jp-controls {
position: absolute;
top: 15px;
left: 15px;
right: 15px;
padding: 0;
}
div.jp-audio-stream ul.jp-controls {
position: absolute;
top: 5px;
left: 5px;
right: 5px;
}
div.jp-video div.jp-type-single ul.jp-controls {
width: 78px;
margin-left: 200px;
}
div.jp-video div.jp-type-playlist ul.jp-controls {
width: 134px;
margin-left: 172px;
}
div.jp-video ul.jp-controls,
div.jp-interface ul.jp-controls li {
display: inline;
float: left;
}
div.jp-interface ul.jp-controls a {
display: block;
overflow: hidden;
text-indent: -9999px;
}
a.jp-play,
a.jp-pause {
width: 40px;
height: 40px;
}
a.jp-play, a.jp-play:hover, a.jp-pause, a.jp-pause:hover, a.jp-stop, a.jp-stop:hover, a.jp-previous, a.jp-previous:hover, a.jp-next, a.jp-next:hover, div.jp-seek-bar, div.jp-play-bar, a.jp-mute, a.jp-mute:hover, a.jp-unmute, a.jp-unmute:hover, a.jp-volume-max, a.jp-volume-max:hover, div.jp-volume-bar, div.jp-audio, div.jp-volume-bar, div.jp-volume-bar-value, a.jp-full-screen, a.jp-full-screen:hover, a.jp-restore-screen, a.jp-restore-screen:hover, a.jp-repeat, a.jp-repeat:hover, a.jp-repeat-off, a.jp-repeat-off:hover, a.jp-shuffle, a.jp-shuffle:hover, a.jp-shuffle-off, a.jp-shuffle-off:hover {
background: url("../modules/jplayer/jplayer.midnight.black.png") no-repeat;
}
a.jp-play {
background-position: 0 0;
}
a.jp-play:hover {
background-position: -41px 0;
}
a.jp-pause {
background-position: 0 -42px;
display: none;
}
a.jp-pause:hover {
background-position: -41px -42px;
}
a.jp-stop, a.jp-previous, a.jp-next {
width: 28px;
height: 28px;
margin-top: 6px;
}
a.jp-stop {
background-position: 0 -83px;
margin-left: 10px;
}
a.jp-stop:hover {
background-position: -29px -83px;
}
a.jp-previous {
background-position: 0 -112px;
}
a.jp-previous:hover {
background-position: -29px -112px;
}
a.jp-next {
background-position: 0 -141px;
}
a.jp-next:hover {
background-position: -29px -141px;
}
/* @end */
/* @group progress bar */
div.jp-progress {
overflow: hidden;
position: absolute;
background: transparent;
}
div.jp-audio div.jp-progress {
top: 27px;
height: 15px;
}
div.jp-audio div.jp-type-single div.jp-progress {
top: 27px;
left: 110px;
right: 112px;
}
div.jp-audio div.jp-type-playlist div.jp-progress {
left: 166px;
right: 179px;
}
div.jp-video div.jp-progress {
top: 0;
left: 0;
width: 100%;
height: 10px;
}
div.jp-seek-bar {
background-repeat: repeat-x;
background-position: 0 -202px;
width: 0;
height: 100%;
cursor: pointer;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25);
overflow: hidden;
}
div.jp-play-bar {
background-repeat: repeat-x;
background-position: 0 -218px;
width:0;
height:100%;
border-radius: 4px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25), 2px 0 5px -2px rgba(0,0,0,0.3);
}
div.jp-video div.jp-seek-bar,
div.jp-video div.jp-play-bar {
border-radius: 0;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
}
/* The seeking class is added/removed inside jPlayer */
div.jp-seeking-bg {
background: url("jplayer.midnight.black.seeking.gif");
}
/* @end */
/* @group volume controls */
a.jp-mute,
a.jp-unmute,
a.jp-volume-max {
position: absolute;
width:18px;
height:15px;
}
div.jp-audio div.jp-type-single a.jp-mute,
div.jp-audio div.jp-type-single a.jp-unmute {
top: 12px;
right: 66px;
}
div.jp-audio div.jp-type-playlist a.jp-mute,
div.jp-audio div.jp-type-playlist a.jp-unmute {
top: 12px;
right: 133px;
}
div.jp-audio-stream div.jp-type-single a.jp-mute,
div.jp-audio-stream div.jp-type-single a.jp-unmute {
top: 12px;
right: 67px;
}
div.jp-audio-stream div.jp-type-single a.jp-volume-max,
div.jp-audio div.jp-type-single a.jp-volume-max {
top: 12px;
right: 0;
}
div.jp-audio div.jp-type-playlist a.jp-volume-max {
top: 12px;
right: 66px;
}
div.jp-video a.jp-mute,
div.jp-video a.jp-unmute,
div.jp-video a.jp-volume-max {
position: absolute;
top:12px;
}
div.jp-video a.jp-mute,
div.jp-video a.jp-unmute {
left: 50px;
}
div.jp-video a.jp-volume-max {
left: 130px;
}
a.jp-mute {
background-position: 0 -170px;
}
a.jp-mute:hover {
background-position: -19px -170px;
}
a.jp-unmute {
background-position: -39px -170px;
display: none;
}
a.jp-unmute:hover {
background-position: -60px -170px;
}
a.jp-volume-max {
background-position: 0 -186px;
}
a.jp-volume-max:hover {
background-position: -19px -186px;
}
div.jp-volume-bar {
position: absolute;
overflow: hidden;
background-repeat: repeat-x;
background-position: 0 -250px;
width: 45px;
height: 5px;
cursor: pointer;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
}
div.jp-audio div.jp-type-single div.jp-volume-bar {
top: 32px;
right: 38px;
}
div.jp-audio div.jp-type-playlist div.jp-volume-bar {
top: 32px;
right: 104px;
}
div.jp-audio-stream div.jp-volume-bar {
top: 22px;
right: 28px;
}
div.jp-video div.jp-volume-bar {
top: 17px;
left: 72px;
}
div.jp-volume-bar-value {
background-repeat: repeat-x;
background-position: 0 -256px;
width: 0;
height: 5px;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25);
}
/* @end */
/* @group current time and duration */
div.jp-audio div.jp-time-holder {
position: absolute;
top: 45px;
}
div.jp-audio div.jp-type-single div.jp-time-holder {
left: 110px;
right: 112px;
}
div.jp-audio div.jp-type-playlist div.jp-time-holder {
left: 166px;
right: 179px;
}
div.jp-current-time,
div.jp-duration {
width: auto;
font-size: 10px;
font-style: italic;
padding-right: 2px;
}
div.jp-current-time {
float: left;
display: inline;
text-align: left;
padding-left: 2px;
}
div.jp-duration {
float: right;
display: inline;
text-align: right;
}
div.jp-video div.jp-current-time {
margin-top: 10px;
margin-left: 10px;
}
div.jp-video div.jp-duration {
margin-top: 10px;
margin-right: 10px;
}
/* @end */
/* @group playlist */
div.jp-title {
font-weight: bold;
text-align: center;
color: #FFF;
background: #343433 url("../modules/jplayer/jplayer.midnight.black.playlist.png") repeat-x
}
div.playing_info {
position: absolute;
left: 100px;
top: 10px;
font-size: 1.5em;
font-family: 'Verdana',Arial,sans-serif;
color: rgb(153, 153, 153);
width: 300px;
}
div.playing_artist {
font-size:0.5em;
}
div.playing_title {
font-size:0.7em;
}
div.jp-title,
div.jp-playlist {
position: absolute;
top: 0px;
right: 0px;
width: 25%;
height: 95%;
overflow: auto;
/*background-color: #343433;*/
background-color: #202020;
border-top: 1px solid #191919;
text-shadow: 0 1px 0 rgba(0,0,0,0.3);
z-index: 0;
}
div.jp-type-single div.jp-title,
div.jp-type-playlist div.jp-title,
div.jp-type-single div.jp-playlist {
border-top: none;
}
div.jp-title ul,
div.jp-playlist ul {
list-style-type: none;
margin: 0;
padding: 0;
font-size: .62em;
}
div.jp-title li {
padding: 5px 0;
font-weight: bold;
}
div.jp-playlist li {
padding: 6px 15px;
border-bottom: 1px solid #121212;
/*background: #343433 url("../modules/jplayer/jplayer.midnight.black.playlist.png") repeat-x;*/
text-shadow: 0 1px 0 rgba(0,0,0,0.3);
}
div.jp-playlist li div {
display: inline;
}
/* Note that the first-child (IE6) and last-child (IE6/7/8) selectors do not work on IE */
div.jp-type-playlist div.jp-playlist li:last-child {
border-bottom: none;
}
div.jp-type-playlist div.jp-playlist li.jp-playlist-current {
padding-left: 20px;
}
div.jp-type-playlist div.jp-playlist a {
color: #BBB;
text-decoration: none;
}
div.jp-type-playlist div.jp-playlist a:hover {
color: #FFF;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-current {
color: #FFF;
font-weight: bold;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-item-remove {
float: right;
display: inline;
text-align: right;
margin-right: 10px;
font-weight: bold;
color: #666;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-item-remove:hover {
color: #FFF;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media {
float: right;
display: inline;
text-align: right;
margin-right: 10px;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media a{
color: #666;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media a:hover{
color: #FFF;
}
span.jp-artist {
font-size: .8em;
color: #666;
}
/* @end */
div.jp-video-play {
width: 100%;
overflow: hidden; /* Important for nested negative margins to work in modern browsers */
cursor: pointer;
background-color: rgba(0,0,0,0); /* Makes IE9 work with the active area over the whole video area. IE6/7/8 only have the button as active area. */
}
div.jp-video-270p div.jp-video-play {
margin-top: -270px;
height: 270px;
}
div.jp-video-360p div.jp-video-play {
margin-top: -360px;
height: 360px;
}
div.jp-video-full div.jp-video-play {
height: 100%;
}
a.jp-video-play-icon {
position:relative;
display:block;
width: 112px;
height: 100px;
margin-left: -56px;
margin-top: -50px;
left: 50%;
top: 50%;
background: url("../modules/jplayer/jplayer.midnight.black.video.play.png") 0 0 no-repeat;
text-indent: -9999px;
}
div.jp-video-play:hover a.jp-video-play-icon {
background: url("../modules/jplayer/jplayer.midnight.black.video.play.png") 0 -100px no-repeat;
}
div.jp-jplayer audio,
div.jp-jplayer {
width: 0;
height: 0;
}
div.jp-jplayer {
background-color: #000000;
position: absolute;
top: 10px;
left: 10px;
}
/* @group TOGGLES */
/* The audio toggles are nested inside jp-time-holder */
ul.jp-toggles {
list-style-type: none;
padding: 0;
margin: 0 auto;
overflow: hidden;
}
div.jp-audio .jp-type-single ul.jp-toggles {
width: auto;
position: absolute;
left: 50%;
margin: 0 0 0 -14px;
}
div.jp-audio .jp-type-playlist ul.jp-toggles {
width: auto;
margin: 0;
position: absolute;
right: 15px;
top: 22px;
}
div.jp-video ul.jp-toggles {
width: auto;
position: absolute;
right: 15px;
top: 6px;
}
ul.jp-toggles li {
display: block;
float: right;
}
ul.jp-toggles li a {
display: block;
width: 28px;
height: 28px;
text-indent: -9999px;
line-height: 100%; /* need this for IE6 */
}
a.jp-full-screen {
background-position: 0 -317px;
margin-left: 20px;
}
a.jp-full-screen:hover {
background-position: -30px -317px;
}
a.jp-restore-screen {
background-position: -60px -317px;
margin-left: 20px;
}
a.jp-restore-screen:hover {
background-position: -90px -317px;
}
a.jp-repeat {
background-position: 0 -289px;
}
a.jp-repeat:hover {
background-position: -30px -289px;
}
a.jp-repeat-off {
background-position: -60px -289px;
}
a.jp-repeat-off:hover {
background-position: -90px -289px;
}
a.jp-shuffle {
background-position: 0 -261px;
margin-left: 5px;
}
a.jp-shuffle:hover {
background-position: -30px -261px;
}
a.jp-shuffle-off {
background-position: -60px -261px;
margin-left: 5px;
}
a.jp-shuffle-off:hover {
background-position: -90px -261px;
}
/* @end */
/* @group NO SOLUTION error feedback */
.jp-no-solution {
padding: 5px;
font-size: .67em;
background: #121112 url("../modules/jplayer/jplayer.midnight.black.interface.png") repeat-x;
border-top: 1px solid #191919;
color: #CCC;
display: none;
text-align: center;
}
.jp-no-solution a {
color: #CCC;
}
.jp-no-solution span {
font-size: 1em;
display: block;
text-align: center;
font-weight: bold;
}
/* @end */

View file

@ -0,0 +1,726 @@
/*
* Skin for jPlayer Plugin (jQuery JavaScript Library)
* http://www.jplayer.org
*
* Skin Name: Midnight Black
*
* Copyright (c) 2010-2012 Happyworm Ltd
* Dual licensed under the MIT and GPL licenses.
* - http://www.opensource.org/licenses/mit-license.php
* - http://www.gnu.org/copyleft/gpl.html
*
* Author: Per Sandström (https://github.com/persand)
* Maintainer: Kasim Ahmic (https://github.com/TheInfection)
* Skin Version: 2.6.3 (jPlayer 2.1.x, 2.2.x, 2.3.x, 2.4.x)
* Date: October 2nd, 2013
*/
div.jp-area {
margin-left: 230px;
margin-right: auto;
margin-top: 10px;
width: 500px;
min-width: 500px;
}
a:active, a:focus {
outline: none; /* To keep Google Chrome from adding that ugly yellow border/outlune on buttons when clicked */
}
div.jp-audio,
div.jp-audio-stream,
div.jp-video {
/* Edit the font-size to counteract inherited font sizing.
* Eg. 1.25em = 1 / 0.8em
*/
font-size: 1.25em; /* 1.25em for testing in site pages */ /* No parent CSS that can effect the size in the demos ZIP */
font-family: 'Verdana', Arial, sans-serif;
line-height: 1.6;
color: #999;
border:1px solid #191919;
background-color: #eee;
}
div.jp-audio {
width: 480px;
}
div.jp-audio-stream {
width: 150px;
}
div.jp-video-270p {
width: 480px;
}
div.jp-video-360p {
width: 640px;
}
div.jp-video-full {
/* Rules for IE6 (full-screen) */
width: 480px;
height: 270px;
/* Rules for IE7 (full-screen) - Otherwise the relative container causes other page items that are not position:static (default) to appear over the video/gui. */
position: static !important;
position: relative;
}
/* The z-index rule is defined in this manner to enable Popcorn plugins that add overlays to video area. EG. Subtitles. */
div.jp-video-full div div {
z-index: 1000;
}
div.jp-video-full div.jp-jplayer {
top: 0;
left: 0;
position: fixed !important; position: relative; /* Rules for IE6 (full-screen) */
overflow: hidden;
}
div.jp-video-full div.jp-gui {
position: fixed !important; position: static; /* Rules for IE6 (full-screen) */
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 1001; /* 1 layer above the others. */
}
div.jp-video-full div.jp-interface {
position: absolute !important; position: relative; /* Rules for IE6 (full-screen) */
bottom: 0;
left: 0;
}
div.jp-interface {
position: relative;
background: #191919 url("../modules/jplayer/jplayer.midnight.black.interface.png") repeat-x;
width: 100%;
}
div.jp-audio div.jp-type-single div.jp-interface {
height: 75px;
}
div.jp-audio div.jp-type-playlist div.jp-interface {
height: 70px;
}
div.jp-audio-stream div.jp-type-single div.jp-interface {
height: 50px;
}
div.jp-video div.jp-interface {
border-top: 1px solid #191919;
}
/* @group CONTROLS */
div.jp-controls-holder {
clear: both;
width: 440px;
margin: 0 auto;
position: relative;
overflow: hidden;
top: -8px; /* This negative value depends on the size of the text in jp-currentTime and jp-duration */
}
div.jp-interface ul.jp-controls {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
}
div.jp-audio ul.jp-controls {
position: absolute;
top: 15px;
left: 15px;
right: 15px;
padding: 0;
}
div.jp-audio-stream ul.jp-controls {
position: absolute;
top: 5px;
left: 5px;
right: 5px;
}
div.jp-video div.jp-type-single ul.jp-controls {
width: 78px;
margin-left: 200px;
}
div.jp-video div.jp-type-playlist ul.jp-controls {
width: 134px;
margin-left: 172px;
}
div.jp-video ul.jp-controls,
div.jp-interface ul.jp-controls li {
display: inline;
float: left;
}
div.jp-interface ul.jp-controls a {
display: block;
overflow: hidden;
text-indent: -9999px;
}
a.jp-play,
a.jp-pause {
width: 40px;
height: 40px;
}
a.jp-play, a.jp-play:hover, a.jp-pause, a.jp-pause:hover, a.jp-stop, a.jp-stop:hover, a.jp-previous, a.jp-previous:hover, a.jp-next, a.jp-next:hover, div.jp-seek-bar, div.jp-play-bar, a.jp-mute, a.jp-mute:hover, a.jp-unmute, a.jp-unmute:hover, a.jp-volume-max, a.jp-volume-max:hover, div.jp-volume-bar, div.jp-audio, div.jp-volume-bar, div.jp-volume-bar-value, a.jp-full-screen, a.jp-full-screen:hover, a.jp-restore-screen, a.jp-restore-screen:hover, a.jp-repeat, a.jp-repeat:hover, a.jp-repeat-off, a.jp-repeat-off:hover, a.jp-shuffle, a.jp-shuffle:hover, a.jp-shuffle-off, a.jp-shuffle-off:hover {
background: url("../modules/jplayer/jplayer.midnight.black.png") no-repeat;
}
a.jp-play {
background-position: 0 0;
}
a.jp-play:hover {
background-position: -41px 0;
}
a.jp-pause {
background-position: 0 -42px;
display: none;
}
a.jp-pause:hover {
background-position: -41px -42px;
}
a.jp-stop, a.jp-previous, a.jp-next {
width: 28px;
height: 28px;
margin-top: 6px;
}
a.jp-stop {
background-position: 0 -83px;
margin-left: 10px;
}
a.jp-stop:hover {
background-position: -29px -83px;
}
a.jp-previous {
background-position: 0 -112px;
}
a.jp-previous:hover {
background-position: -29px -112px;
}
a.jp-next {
background-position: 0 -141px;
}
a.jp-next:hover {
background-position: -29px -141px;
}
/* @end */
/* @group progress bar */
div.jp-progress {
overflow: hidden;
position: absolute;
background: transparent;
}
div.jp-audio div.jp-progress {
top: 27px;
height: 15px;
}
div.jp-audio div.jp-type-single div.jp-progress {
top: 27px;
left: 110px;
right: 112px;
}
div.jp-audio div.jp-type-playlist div.jp-progress {
left: 166px;
right: 179px;
}
div.jp-video div.jp-progress {
top: 0;
left: 0;
width: 100%;
height: 10px;
}
div.jp-seek-bar {
background-repeat: repeat-x;
background-position: 0 -202px;
width: 0;
height: 100%;
cursor: pointer;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25);
overflow: hidden;
}
div.jp-play-bar {
background-repeat: repeat-x;
background-position: 0 -218px;
width:0;
height:100%;
border-radius: 4px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25), 2px 0 5px -2px rgba(0,0,0,0.3);
}
div.jp-video div.jp-seek-bar,
div.jp-video div.jp-play-bar {
border-radius: 0;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
}
/* The seeking class is added/removed inside jPlayer */
div.jp-seeking-bg {
background: url("jplayer.midnight.black.seeking.gif");
}
/* @end */
/* @group volume controls */
a.jp-mute,
a.jp-unmute,
a.jp-volume-max {
position: absolute;
width:18px;
height:15px;
}
div.jp-audio div.jp-type-single a.jp-mute,
div.jp-audio div.jp-type-single a.jp-unmute {
top: 12px;
right: 66px;
}
div.jp-audio div.jp-type-playlist a.jp-mute,
div.jp-audio div.jp-type-playlist a.jp-unmute {
top: 12px;
right: 133px;
}
div.jp-audio-stream div.jp-type-single a.jp-mute,
div.jp-audio-stream div.jp-type-single a.jp-unmute {
top: 12px;
right: 67px;
}
div.jp-audio-stream div.jp-type-single a.jp-volume-max,
div.jp-audio div.jp-type-single a.jp-volume-max {
top: 12px;
right: 0;
}
div.jp-audio div.jp-type-playlist a.jp-volume-max {
top: 12px;
right: 66px;
}
div.jp-video a.jp-mute,
div.jp-video a.jp-unmute,
div.jp-video a.jp-volume-max {
position: absolute;
top:12px;
}
div.jp-video a.jp-mute,
div.jp-video a.jp-unmute {
left: 50px;
}
div.jp-video a.jp-volume-max {
left: 130px;
}
a.jp-mute {
background-position: 0 -170px;
}
a.jp-mute:hover {
background-position: -19px -170px;
}
a.jp-unmute {
background-position: -39px -170px;
display: none;
}
a.jp-unmute:hover {
background-position: -60px -170px;
}
a.jp-volume-max {
background-position: 0 -186px;
}
a.jp-volume-max:hover {
background-position: -19px -186px;
}
div.jp-volume-bar {
position: absolute;
overflow: hidden;
background-repeat: repeat-x;
background-position: 0 -250px;
width: 45px;
height: 5px;
cursor: pointer;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
}
div.jp-audio div.jp-type-single div.jp-volume-bar {
top: 32px;
right: 38px;
}
div.jp-audio div.jp-type-playlist div.jp-volume-bar {
top: 32px;
right: 104px;
}
div.jp-audio-stream div.jp-volume-bar {
top: 22px;
right: 28px;
}
div.jp-video div.jp-volume-bar {
top: 17px;
left: 72px;
}
div.jp-volume-bar-value {
background-repeat: repeat-x;
background-position: 0 -256px;
width: 0;
height: 5px;
border-radius: 5px;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), inset 0 -1px 0 rgba(0,0,0,0.25);
}
/* @end */
/* @group current time and duration */
div.jp-audio div.jp-time-holder {
position: absolute;
top: 45px;
}
div.jp-audio div.jp-type-single div.jp-time-holder {
left: 110px;
right: 112px;
}
div.jp-audio div.jp-type-playlist div.jp-time-holder {
left: 166px;
right: 179px;
}
div.jp-current-time,
div.jp-duration {
width: auto;
font-size: 10px;
font-style: italic;
}
div.jp-current-time {
float: left;
display: inline;
text-align: left;
}
div.jp-duration {
float: right;
display: inline;
text-align: right;
}
div.jp-video div.jp-current-time {
margin-top: 10px;
margin-left: 10px;
}
div.jp-video div.jp-duration {
margin-top: 10px;
margin-right: 10px;
}
/* @end */
/* @group playlist */
div.jp-title {
font-weight: bold;
text-align: center;
color: #FFF;
background: #343433 url("../modules/jplayer/jplayer.midnight.black.playlist.png") repeat-x
}
div.playing_info {
position: absolute;
left: 10px;
top: 220px;
font-size: 1.5em;
font-family: 'Verdana',Arial,sans-serif;
width: 220px;
}
div.playing_artist {
font-size:0.8em;
}
div.playing_title {
font-size:1.1em;
}
div.jp-title,
div.jp-playlist {
width: 100%;
height: 200px;
background-color: #343433;
border-top: 1px solid #191919;
overflow: auto;
text-shadow: 0 1px 0 rgba(0,0,0,0.3);
z-index: 0;
}
div.jp-type-single div.jp-title,
div.jp-type-playlist div.jp-title,
div.jp-type-single div.jp-playlist {
border-top: none;
}
div.jp-title ul,
div.jp-playlist ul {
list-style-type: none;
margin: 0;
padding: 0;
font-size: .62em;
}
div.jp-title li {
padding: 5px 0;
font-weight: bold;
}
div.jp-playlist li {
padding: 6px 15px;
border-bottom: 1px solid #121212;
background: #343433 url("../modules/jplayer/jplayer.midnight.black.playlist.png") repeat-x;
text-shadow: 0 1px 0 rgba(0,0,0,0.3);
}
div.jp-playlist li div {
display: inline;
}
/* Note that the first-child (IE6) and last-child (IE6/7/8) selectors do not work on IE */
div.jp-type-playlist div.jp-playlist li:last-child {
border-bottom: none;
}
div.jp-type-playlist div.jp-playlist li.jp-playlist-current {
padding-left: 20px;
}
div.jp-type-playlist div.jp-playlist a {
color: #BBB;
text-decoration: none;
}
div.jp-type-playlist div.jp-playlist a:hover {
color: #FFF;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-current {
color: #FFF;
font-weight: bold;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-item-remove {
float: right;
display: inline;
text-align: right;
margin-right: 10px;
font-weight: bold;
color: #666;
}
div.jp-type-playlist div.jp-playlist a.jp-playlist-item-remove:hover {
color: #FFF;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media {
float: right;
display: inline;
text-align: right;
margin-right: 10px;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media a{
color: #666;
}
div.jp-type-playlist div.jp-playlist span.jp-free-media a:hover{
color: #FFF;
}
span.jp-artist {
font-size: .8em;
color: #666;
}
/* @end */
div.jp-video-play {
width: 100%;
overflow: hidden; /* Important for nested negative margins to work in modern browsers */
cursor: pointer;
background-color: rgba(0,0,0,0); /* Makes IE9 work with the active area over the whole video area. IE6/7/8 only have the button as active area. */
}
div.jp-video-270p div.jp-video-play {
margin-top: -270px;
height: 270px;
}
div.jp-video-360p div.jp-video-play {
margin-top: -360px;
height: 360px;
}
div.jp-video-full div.jp-video-play {
height: 100%;
}
a.jp-video-play-icon {
position:relative;
display:block;
width: 112px;
height: 100px;
margin-left: -56px;
margin-top: -50px;
left: 50%;
top: 50%;
background: url("../modules/jplayer/jplayer.midnight.black.video.play.png") 0 0 no-repeat;
text-indent: -9999px;
}
div.jp-video-play:hover a.jp-video-play-icon {
background: url("../modules/jplayer/jplayer.midnight.black.video.play.png") 0 -100px no-repeat;
}
div.jp-jplayer audio,
div.jp-jplayer {
width: 0;
height: 0;
}
div.jp-jplayer {
background-color: #000000;
position: absolute;
top: 10px;
left: 10px;
}
/* @group TOGGLES */
/* The audio toggles are nested inside jp-time-holder */
ul.jp-toggles {
list-style-type: none;
padding: 0;
margin: 0 auto;
overflow: hidden;
}
div.jp-audio .jp-type-single ul.jp-toggles {
width: auto;
position: absolute;
left: 50%;
margin: 0 0 0 -14px;
}
div.jp-audio .jp-type-playlist ul.jp-toggles {
width: auto;
margin: 0;
position: absolute;
right: 15px;
top: 22px;
}
div.jp-video ul.jp-toggles {
width: auto;
position: absolute;
right: 15px;
top: 6px;
}
ul.jp-toggles li {
display: block;
float: right;
}
ul.jp-toggles li a {
display: block;
width: 28px;
height: 28px;
text-indent: -9999px;
line-height: 100%; /* need this for IE6 */
}
a.jp-full-screen {
background-position: 0 -317px;
margin-left: 20px;
}
a.jp-full-screen:hover {
background-position: -30px -317px;
}
a.jp-restore-screen {
background-position: -60px -317px;
margin-left: 20px;
}
a.jp-restore-screen:hover {
background-position: -90px -317px;
}
a.jp-repeat {
background-position: 0 -289px;
}
a.jp-repeat:hover {
background-position: -30px -289px;
}
a.jp-repeat-off {
background-position: -60px -289px;
}
a.jp-repeat-off:hover {
background-position: -90px -289px;
}
a.jp-shuffle {
background-position: 0 -261px;
margin-left: 5px;
}
a.jp-shuffle:hover {
background-position: -30px -261px;
}
a.jp-shuffle-off {
background-position: -60px -261px;
margin-left: 5px;
}
a.jp-shuffle-off:hover {
background-position: -90px -261px;
}
/* @end */
/* @group NO SOLUTION error feedback */
.jp-no-solution {
padding: 5px;
font-size: .67em;
background: #121112 url("../modules/jplayer/jplayer.midnight.black.interface.png") repeat-x;
border-top: 1px solid #191919;
color: #CCC;
display: none;
text-align: center;
}
.jp-no-solution a {
color: #CCC;
}
.jp-no-solution span {
font-size: 1em;
display: block;
text-align: center;
font-weight: bold;
}
/* @end */

View file

@ -0,0 +1,57 @@
<?php
/* vim:set softtabstop=4 shiftwidth=4 expandtab: */
/**
*
* LICENSE: GNU General Public License, version 2 (GPLv2)
* Copyright 2001 - 2013 Ampache.org
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License v2
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
if (INIT_LOADED != '1') { exit; }
$web_path = Config::get('web_path');
$htmllang = str_replace("_","-",Config::get('lang'));
$location = get_location();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $htmllang; ?>" lang="<?php echo $htmllang; ?>" dir="<?php echo is_rtl(Config::get('lang')) ? 'rtl' : 'ltr';?>">
<head>
<link rel="shortcut icon" href="<?php echo $web_path; ?>/favicon.ico" />
<link rel="search" type="application/opensearchdescription+xml" title="<?php echo scrub_out(Config::get('site_title')); ?>" href="<?php echo $web_path; ?>/search.php?action=descriptor" />
<?php
if (Config::get('use_rss')) { ?>
<link rel="alternate" type="application/rss+xml" title="<?php echo T_('Now Playing'); ?>" href="<?php echo $web_path; ?>/rss.php" />
<link rel="alternate" type="application/rss+xml" title="<?php echo T_('Recently Played'); ?>" href="<?php echo $web_path; ?>/rss.php?type=recently_played" />
<?php } ?>
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=<?php echo Config::get('site_charset'); ?>" />
<title><?php echo scrub_out(Config::get('site_title')); ?> - <?php echo $location['title']; ?></title>
<style type="text/css">
#wrap { position:fixed; left:0; width:100%; top:0; height:100%; }
.frame_main_full { display: block; width:100%; height: 100%; }
.frame_footer_hide { width:100%; height:0%; border:1px solid black; display:none; }
.frame_footer_visible { width:100%; height:100px; border:1px solid black; display:inline; position:fixed; bottom:0; z-index:999999;}
</style>
</head>
<body style="height: 100%;">
<div id="wrap">
<div id="maindiv" style="width:100%; height: 100%;">
<iframe id="frame_main" class="frame_main_full" src="<?php echo $web_path; ?>/index.php?framed=1"></iframe>
</div>
<iframe id="frame_footer" class="frame_footer_hide" src="" sandbox="allow-top-navigation allow-scripts allow-same-origin"></iframe>
</div>
</body>
</html>

View file

@ -28,50 +28,147 @@ header('Expires: ' . gmdate(DATE_RFC1123, time()-1));
<html>
<head>
<title><?php echo Config::get('site_title'); ?></title>
<link rel="stylesheet" href="<?php echo Config::get('web_path'); ?>/templates/html5_player.css" type="text/css" media="screen" />
<?php
if ($iframed) {
?>
<link rel="stylesheet" href="<?php echo Config::get('web_path'); ?>/templates/jplayer.midnight.black-iframed.css" type="text/css" />
<?php
} else {
?>
<link rel="stylesheet" href="<?php echo Config::get('web_path'); ?>/templates/jplayer.midnight.black.css" type="text/css" />
<?php require_once Config::get('prefix') . '/templates/stylesheets.inc.php'; ?>
<script src="<?php echo Config::get('web_path'); ?>/modules/prototype/prototype.js" language="javascript" type="text/javascript"></script>
<?php
}
?>
<script src="<?php echo Config::get('web_path'); ?>/modules/jplayer/jquery.min.js" language="javascript" type="text/javascript"></script>
<script src="<?php echo Config::get('web_path'); ?>/modules/jplayer/jquery.jplayer.min.js" language="javascript" type="text/javascript"></script>
<script src="<?php echo Config::get('web_path'); ?>/modules/jplayer/jplayer.playlist.min.js" language="javascript" type="text/javascript"></script>
<script type="text/javascript">
var playlist_items={
$(document).ready(function(){
var myPlaylist = new jPlayerPlaylist({
jPlayer: "#jquery_jplayer_1",
cssSelectorAncestor: "#jp_container_1"
}, [
<?php
$i = 0;
$playlist = new Stream_Playlist(scrub_in($_REQUEST['playlist_id']));
$types = array();
foreach($playlist->urls as $item)
{
echo ($i++ > 0 ? ',' : '') . $i . ': {';
foreach(array('id', 'title', 'type', 'album', 'time', 'author', 'info_url') as $member)
echo ($i++ > 0 ? ',' : '') . '{' . "\n";
foreach(array('title', 'author') as $member)
{
echo $member . ': "' . addslashes($item->$member) . '",';
if ($member == "author")
$kmember = "artist";
else
$kmember = $member;
echo $kmember . ': "' . addslashes($item->$member) . '",' . "\n";
}
echo 'play_url: "' . $item->url . '",';
echo 'albumart_url: "' . $item->image_url . '",';
echo 'media_type: "' . $type . '"}';
$type = strtolower(pathinfo($item->url, PATHINFO_EXTENSION));
if ($type == "ogg")
$type = "oga";
if (!in_array($type, $types)) {
$types[] = $type;
}
echo $type.': "' . $item->url . '",' . "\n";
echo 'poster: "' . $item->image_url . (!$iframed ? '&thumb=4' : '') . '" }' . "\n";
}
?>
};
</script>
<script src="<?php echo Config::get('web_path'); ?>/lib/javascript/html5_player.js" language="javascript" type="text/javascript"></script>
], {
playlistOptions: {
autoPlay: true,
loopOnPrevious: false,
shuffleOnLoop: true,
enableRemoveControls: false,
displayTime: 'slow',
addTime: 'fast',
removeTime: 'fast',
shuffleTime: 'slow'
},
swfPath: "<?php echo Config::get('web_path'); ?>/modules/jplayer/",
supplied: "<?php echo join(",", $types); ?>",
audioFullScreen: true,
size: {
<?php
if ($iframed) {
?>
width: "80px",
height: "80px",
<?php
} else {
?>
width: "200px",
height: "auto",
<?php
}
?>
}
});
$("#jquery_jplayer_1").bind($.jPlayer.event.play, function (event) {
var current = myPlaylist.current,
playlist = myPlaylist.playlist;
$.each(playlist, function (index, obj) {
if (index == current) {
$('.playing_title').text(obj.title);
$('.playing_artist').text(obj.artist);
}
});
});
});
</script>
</head>
<body id="html5_player">
<div id="player">
<div id="albumart"></div>
<div id="search">
<input id="input_search" type="text" value="<?php echo T_('search') ?>" accesskey="<?php echo T_dgettext('html5_player_accesskey', 's') ?>"/>
<button id="clear_search"><?php echo T_('clear') ?></button>
</div>
<div id="title"><?php echo T_('Loading...') ?></div>
<div id="album"><?php echo T_('Loading...') ?></div>
<div id="artist"><?php echo T_('Loading...') ?></div>
<div id="progress_text"><?php echo T_('Loading...') ?></div>
<button id="stop" accesskey="<?php echo T_dgettext('html5_player_accesskey', 'o') ?>"><?php echo T_('Stop') ?></button>
<button id="play" accesskey="<?php echo T_dgettext('html5_player_accesskey', 'p') ?>"><?php echo T_('Play') ?></button>
<button id="pause" accesskey="<?php echo T_dgettext('html5_player_accesskey', 'p') ?>"><?php echo T_('Pause') ?></button>
<button id="previous" accesskey="<?php echo T_dgettext('html5_player_accesskey', ',') ?>"><?php echo T_('Previous') ?></button>
<button id="next" accesskey="<?php echo T_dgettext('html5_player_accesskey', '.') ?>"><?php echo T_('Next') ?></button>
</div>
<div>
<ul id="playlist">
<body>
<div class="playing_info">
<div class="playing_artist"></div>
<div class="playing_title"></div>
</div>
<div class="jp-area">
<div id="jquery_jplayer_1" class="jp-jplayer"></div>
<div id="jp_container_1" class="jp-audio">
<div class="jp-type-playlist">
<div class="jp-gui jp-interface">
<ul class="jp-controls">
<li><a href="javascript:;" class="jp-previous" tabindex="1">previous</a></li>
<li><a href="javascript:;" class="jp-play" tabindex="1">play</a></li>
<li><a href="javascript:;" class="jp-pause" tabindex="1">pause</a></li>
<li><a href="javascript:;" class="jp-next" tabindex="1">next</a></li>
<li><a href="javascript:;" class="jp-stop" tabindex="1">stop</a></li>
<li><a href="javascript:;" class="jp-mute" tabindex="1" title="mute">mute</a></li>
<li><a href="javascript:;" class="jp-unmute" tabindex="1" title="unmute">unmute</a></li>
<li><a href="javascript:;" class="jp-volume-max" tabindex="1" title="max volume">max volume</a></li>
</ul>
<div class="jp-progress">
<div class="jp-seek-bar">
<div class="jp-play-bar"></div>
</div>
</div>
<div class="jp-volume-bar">
<div class="jp-volume-bar-value"></div>
</div>
<div class="jp-current-time"></div>
<div class="jp-duration"></div>
<ul class="jp-toggles">
<li><a href="javascript:;" class="jp-shuffle" tabindex="1" title="shuffle">shuffle</a></li>
<li><a href="javascript:;" class="jp-shuffle-off" tabindex="1" title="shuffle off">shuffle off</a></li>
<li><a href="javascript:;" class="jp-repeat" tabindex="1" title="repeat">repeat</a></li>
<li><a href="javascript:;" class="jp-repeat-off" tabindex="1" title="repeat off">repeat off</a></li>
</ul>
</div>
<div class="jp-playlist">
<ul>
<li></li>
</ul>
</div>
<div class="jp-no-solution">
<span>Unsupported</span>
This media is not supported by the player. Is your browser up to date?
</div>
</div>
</div>
</div>
</body>
</html>

View file

@ -37,6 +37,13 @@ if (Preference::has_access('play_type')) {
<option value="democratic" <?php echo $is_democratic; ?>><?php echo T_('Democratic'); ?></option>
<?php } ?>
<option value="html5_player" <?php echo $is_html5_player; ?>><?php echo T_('HTML5 Player'); ?></option>
<?php
if (Config::get("iframes")) {
?>
<option value="html5_player_embedded" <?php echo $is_html5_player_embedded; ?>><?php echo T_('Framed Player'); ?></option>
<?php
}
?>
</select>
<?php echo Ajax::observe('play_type_select','change',Ajax::action('?page=stream&action=set_play_type','play_type_select','play_type_form'),'1'); ?>
</form>

View file

@ -44,7 +44,7 @@
<?php Ajax::end_container(); ?>
<li><h4><?php echo T_('Playlist'); ?></h4>
<ul class="sb3" id="sb_home_info">
<li id="sb_home_info_CurrentlyPlaying"><a href="<?php echo $web_path; ?>/index.php"><?php echo T_('Currently Playing'); ?></a></li>
<li id="sb_home_info_CurrentlyPlaying"><a href="<?php echo Config::get('web_path') . ((Config::get('iframes')) ? '/?framed=1' : ''); ?>"><?php echo T_('Currently Playing'); ?></a></li>
<?php if (Config::get('allow_democratic_playback')) { ?>
<li id="sb_home_democratic_playlist"><a href="<?php echo $web_path; ?>/democratic.php?action=show_playlist"><?php echo T_('Democratic'); ?></a></li>
<?php } ?>