Merge branch 'saas' of github.com:sourcefabric/Airtime into saas
This commit is contained in:
commit
a48ae75907
34 changed files with 4141 additions and 227 deletions
0
airtime_mvc/public/css/colorpicker/embeddable-player.css
Normal file
0
airtime_mvc/public/css/colorpicker/embeddable-player.css
Normal file
BIN
airtime_mvc/public/css/embed-player-images/airtime_logo.png
Normal file
BIN
airtime_mvc/public/css/embed-player-images/airtime_logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
BIN
airtime_mvc/public/css/embed-player-images/mute.png
Normal file
BIN
airtime_mvc/public/css/embed-player-images/mute.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
BIN
airtime_mvc/public/css/embed-player-images/pause_button.png
Normal file
BIN
airtime_mvc/public/css/embed-player-images/pause_button.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
BIN
airtime_mvc/public/css/embed-player-images/play_button.png
Normal file
BIN
airtime_mvc/public/css/embed-player-images/play_button.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.6 KiB |
BIN
airtime_mvc/public/css/embed-player-images/unmute.png
Normal file
BIN
airtime_mvc/public/css/embed-player-images/unmute.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
62
airtime_mvc/public/css/player-form.css
Normal file
62
airtime_mvc/public/css/player-form.css
Normal file
|
@ -0,0 +1,62 @@
|
|||
.embed-player-text-box {
|
||||
padding-right: 0px !important;
|
||||
width: 100% !important;
|
||||
}
|
||||
.embed-player-form {
|
||||
width: 40%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
.embed-player-form dd {
|
||||
width: 100% !important;
|
||||
float: left;
|
||||
margin: 0;
|
||||
padding: 4px 0px 4px 0px;
|
||||
}
|
||||
.player-preview {
|
||||
width: 100%;
|
||||
}
|
||||
.player-preview iframe {
|
||||
margin: 0 auto;
|
||||
display: block;
|
||||
}
|
||||
#player_form {
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
#player_form dd {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
#player_instructions {
|
||||
border-bottom: 1px solid;
|
||||
padding-bottom: 10px;
|
||||
font-size: 14px;
|
||||
/*font-weight: bold;*/
|
||||
color: #333;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.player-title {
|
||||
clear: left;
|
||||
color: #5b5b5b;
|
||||
float: left;
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
width: 40px;
|
||||
padding: 4px 0;
|
||||
text-align: left;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 17px;
|
||||
}
|
||||
#player_title {
|
||||
clear: left;
|
||||
}
|
||||
#player_stream_url-element {
|
||||
margin-left:30px;
|
||||
}
|
||||
#player_embed_src-element p {
|
||||
margin: 0px;
|
||||
font-size: 13px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
|
||||
|
215
airtime_mvc/public/css/player.css
Normal file
215
airtime_mvc/public/css/player.css
Normal file
|
@ -0,0 +1,215 @@
|
|||
.airtime_player {
|
||||
width: 270px;
|
||||
height: 191px;
|
||||
position: relative;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
color: #fff;
|
||||
background: rgba(53, 53, 53, 0.9);
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
-webkit-box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
-moz-box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
}
|
||||
|
||||
.airtime_header {
|
||||
background: rgba(53, 53, 53, 0.9);
|
||||
-webkit-box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
-moz-box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
box-shadow: 0 3px 5px rgba(0,0,0,0.1) inset,0 1px 0 rgba(255,255,255,0.1),0 0 1px #000 inset;
|
||||
height: 37px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.airtime_box {
|
||||
margin-top: 15px;
|
||||
float: left;
|
||||
width: 100%;
|
||||
height: 52px;
|
||||
}
|
||||
.station_name {
|
||||
font-size: 14px;
|
||||
padding-top: 10px;
|
||||
padding-left: 20px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
padding-right: 30px;
|
||||
}
|
||||
.airtime_pro {
|
||||
margin: 6px 20px;
|
||||
color: #fff;
|
||||
font-size: 11px;
|
||||
text-decoration: none;
|
||||
display:inline-block;
|
||||
float:right;
|
||||
}
|
||||
.airtime_pro_logo {
|
||||
background: url("embed-player-images/airtime_logo.png") center no-repeat;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
display:inline-block;
|
||||
}
|
||||
|
||||
/*.airtime_pro span {
|
||||
display: inline-block;
|
||||
vertical-align: 2px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
.airtime_pro:hover span {
|
||||
display: inline-block;
|
||||
vertical-align: 2px;
|
||||
margin-right: 5px;
|
||||
}*/
|
||||
.airtime_box .airtime_button {
|
||||
text-indent: -9999px;
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
background: rgb(100,100,100);
|
||||
background: -moz-linear-gradient(top, rgba(107, 107, 107, 1) 0%, rgba(88,88,88,1) 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(100,100,100,1)), color-stop(100%,rgba(88,88,88,1)));
|
||||
background: -webkit-linear-gradient(top, rgba(107, 107, 107, 1) 0%,rgba(88,88,88,1) 100%);
|
||||
background: -o-linear-gradient(top, rgba(107, 107, 107, 1) 0%,rgba(88,88,88,1) 100%);
|
||||
background: -ms-linear-gradient(top, rgba(107, 107, 107, 1) 0%,rgba(88,88,88,1) 100%);
|
||||
background: linear-gradient(to bottom, rgba(107, 107, 107, 1) 0%,rgba(88,88,88,1) 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#646464', endColorstr='#585858',GradientType=0 );
|
||||
-webkit-box-shadow: 0px 1px 0px rgba(255, 255, 255, 0.2) inset;
|
||||
-moz-box-shadow: 0px 1px 0px rgba(255, 255, 255, 0.2) inset;
|
||||
box-shadow: 0px 1px 0px rgba(255, 255, 255, 0.2) inset;
|
||||
width: 47px;
|
||||
height: 47px;
|
||||
display: inline-block;
|
||||
float: left;
|
||||
cursor: pointer;
|
||||
margin-left: 20px;
|
||||
margin-right: 15px;
|
||||
}
|
||||
|
||||
.airtime_box .airtime_button:hover {
|
||||
background: rgb(147,147,147);
|
||||
background: -moz-linear-gradient(top, rgba(147,147,147,1) 0%, rgba(117,117,117,1) 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(147,147,147,1)), color-stop(100%,rgba(117,117,117,1)));
|
||||
background: -webkit-linear-gradient(top, rgba(147,147,147,1) 0%,rgba(117,117,117,1) 100%);
|
||||
background: -o-linear-gradient(top, rgba(147,147,147,1) 0%,rgba(117,117,117,1) 100%);
|
||||
background: -ms-linear-gradient(top, rgba(147,147,147,1) 0%,rgba(117,117,117,1) 100%);
|
||||
background: linear-gradient(to bottom, rgba(147,147,147,1) 0%,rgba(117,117,117,1) 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#939393', endColorstr='#757575',GradientType=0 );
|
||||
}
|
||||
|
||||
.airtime_box .airtime_button .play_button {
|
||||
display: block;
|
||||
background: url("embed-player-images/play_button.png") center no-repeat;
|
||||
width: 47px;
|
||||
height: 47px;
|
||||
}
|
||||
|
||||
.airtime_box .airtime_button .stop_button {
|
||||
display: block;
|
||||
background: url("embed-player-images/pause_button.png") center no-repeat;
|
||||
width: 47px;
|
||||
height: 47px;
|
||||
}
|
||||
|
||||
.hide_button {
|
||||
display:none !important;
|
||||
}
|
||||
|
||||
.now_playing {
|
||||
margin-top: 8px;
|
||||
margin-left: 15px;
|
||||
margin-right: 15px;
|
||||
display: block;
|
||||
font-size: 14px;
|
||||
color: #fff;
|
||||
width: 170px;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.now_playing span {
|
||||
display: block;
|
||||
color: #aaaaaa;
|
||||
width: 170px;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.airtime_volume {
|
||||
padding: 10px 0px 15px 0px;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.airtime_volume .volume_control {
|
||||
margin-left: 55px;
|
||||
float: left;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.airtime_volume .mute {
|
||||
background: url("embed-player-images/mute.png") center no-repeat;
|
||||
display: block;
|
||||
margin-top: -4px;
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.airtime_volume_bar {
|
||||
border-color: #262526 #262526 #5E5E5E;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
background-color: #393939;
|
||||
width: auto;
|
||||
height: 5px;
|
||||
cursor: pointer;
|
||||
margin-left: 80px;
|
||||
margin-right: 40px;
|
||||
}
|
||||
|
||||
.airtime_volume_bar_value {
|
||||
background-color: #ff9122;
|
||||
width: 0px;
|
||||
height: 5px;
|
||||
}
|
||||
|
||||
.airtime_schedule {
|
||||
margin: 10px 20px 5px 20px;
|
||||
padding-top: 10px;
|
||||
font-size: 14px;
|
||||
color: #aaaaaa;
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.1);
|
||||
border-bottom: 1px solid rgba(255, 255, 255, 0.1);
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
.airtime_next {
|
||||
float: left;
|
||||
margin: 0px;
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
.schedule_list {
|
||||
list-style: none;
|
||||
padding-left: 0px;
|
||||
padding-bottom: 10px;
|
||||
margin-top: 0px;
|
||||
margin-left: 60px;
|
||||
margin-bottom: 0px;
|
||||
line-height: 130%;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.schedule_list li {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.airtime-pro-orange {
|
||||
color: #ff5d1a;
|
||||
}
|
3014
airtime_mvc/public/js/airtime/player/mrp.js
Normal file
3014
airtime_mvc/public/js/airtime/player/mrp.js
Normal file
File diff suppressed because it is too large
Load diff
BIN
airtime_mvc/public/js/airtime/player/muses.swf
Normal file
BIN
airtime_mvc/public/js/airtime/player/muses.swf
Normal file
Binary file not shown.
94
airtime_mvc/public/js/airtime/player/player.js
Normal file
94
airtime_mvc/public/js/airtime/player/player.js
Normal file
|
@ -0,0 +1,94 @@
|
|||
function updateEmbedSrcParams()
|
||||
{
|
||||
var $embedCodeParams = "?";
|
||||
var $streamMode = getStreamMode();
|
||||
if ($streamMode == "manual") {
|
||||
var $stream = $("input[name=player_stream_url]:radio:checked").val();
|
||||
$embedCodeParams += "stream="+$stream;
|
||||
} else if ($streamMode == "auto") {
|
||||
$embedCodeParams += "stream=auto";
|
||||
}
|
||||
|
||||
$embedCodeParams += "&title="+getPlayerTitle();
|
||||
|
||||
$embedCodeParams += "\"";
|
||||
|
||||
$("textarea[name=player_embed_src]").val(function(index, value) {
|
||||
return value.replace(/\?.*?"/, $embedCodeParams);
|
||||
});
|
||||
|
||||
updatePlayerIframeSrc($("textarea[name=player_embed_src]").val());
|
||||
}
|
||||
|
||||
function updatePlayerIframeSrc(iframe_text) {
|
||||
var $player_iframe = $("#player_form iframe");
|
||||
var player_iframe_src = iframe_text.match(/http.*?"/)[0].slice(0, -1);
|
||||
$player_iframe.attr('src', player_iframe_src);
|
||||
}
|
||||
|
||||
function getStreamMode() {
|
||||
return $("input[name=player_stream_mode]:radio:checked").val();
|
||||
}
|
||||
|
||||
function getPlayerTitle() {
|
||||
return $("input[name=player_title]").val();
|
||||
}
|
||||
|
||||
$(document).ready(function() {
|
||||
|
||||
$("#player_stream_url-element").hide();
|
||||
|
||||
// stream mode change event
|
||||
$("#player_stream_mode-element").change(function() {
|
||||
var $streamMode = getStreamMode();
|
||||
|
||||
if ($streamMode == "auto") {
|
||||
$("#player_stream_url-element").hide();
|
||||
|
||||
} else if ($streamMode == "manual") {
|
||||
$("#player_stream_url-element").show();
|
||||
|
||||
$("input[name=player_stream_url]").each(function(i, obj) {
|
||||
if ($(this).parent().text().toLowerCase().indexOf("opus") >= 0) {
|
||||
$(this).attr("disabled", "disabled");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
updateEmbedSrcParams();
|
||||
});
|
||||
|
||||
// stream url change event
|
||||
$("#player_stream_url-element").change(function() {
|
||||
updateEmbedSrcParams();
|
||||
});
|
||||
|
||||
// display title checkbox change event
|
||||
$("#player_display_title").change(function() {
|
||||
if ($(this).prop("checked")) {
|
||||
$("#player_title-label").show();
|
||||
$("#player_title-element").show();
|
||||
} else {
|
||||
$("#player_title-label").hide();
|
||||
$("#player_title-element").hide();
|
||||
}
|
||||
updateEmbedSrcParams();
|
||||
});
|
||||
|
||||
// title textbox change event
|
||||
// setup before functions
|
||||
var typingTimer;
|
||||
var doneTypingInterval = 3000;
|
||||
|
||||
// on keyup, start the countdown
|
||||
$("input[name=player_title]").keyup(function(){
|
||||
clearTimeout(typingTimer);
|
||||
typingTimer = setTimeout(updateEmbedSrcParams, doneTypingInterval);
|
||||
});
|
||||
|
||||
// on keydown, clear the countdown
|
||||
$("input[name=player_title]").keydown(function(){
|
||||
clearTimeout(typingTimer);
|
||||
});
|
||||
});
|
||||
|
|
@ -443,7 +443,7 @@ function setSliderForReplayGain(){
|
|||
$( "#replayGainModifier" ).val( $( "#slider-range-max" ).slider( "value" ) );
|
||||
}
|
||||
|
||||
function setPseudoAdminPassword(s1, s2, s3) {
|
||||
function setPseudoAdminPassword(s1, s2, s3, s4) {
|
||||
if (s1) {
|
||||
$('#s1_data-admin_pass').val('xxxxxx');
|
||||
}
|
||||
|
@ -453,11 +453,14 @@ function setPseudoAdminPassword(s1, s2, s3) {
|
|||
if (s3) {
|
||||
$('#s3_data-admin_pass').val('xxxxxx');
|
||||
}
|
||||
if (s4) {
|
||||
$('#s4_data-admin_pass').val('xxxxxx');
|
||||
}
|
||||
}
|
||||
|
||||
function getAdminPasswordStatus() {
|
||||
$.ajax({ url: baseUrl+'Preference/get-admin-password-status/format/json', dataType:"json", success:function(data){
|
||||
setPseudoAdminPassword(data.s1, data.s2, data.s3);
|
||||
setPseudoAdminPassword(data.s1, data.s2, data.s3, data.s4);
|
||||
}});
|
||||
}
|
||||
|
||||
|
@ -476,7 +479,7 @@ $(document).ready(function() {
|
|||
$('#content').empty().append(json.html);
|
||||
setupEventListeners();
|
||||
setSliderForReplayGain();
|
||||
setPseudoAdminPassword(json.s1_set_admin_pass, json.s2_set_admin_pass, json.s3_set_admin_pass);
|
||||
setPseudoAdminPassword(json.s1_set_admin_pass, json.s2_set_admin_pass, json.s3_set_admin_pass, json.s4_set_admin_pass);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue