-fixed UI freeze on some very special occasions

-fixed some php errors related to php shipped with debian
-playlist.js no longer active on login page
This commit is contained in:
martin 2011-02-13 13:29:16 -05:00
parent b9e1078e10
commit a5fd68c252
6 changed files with 32 additions and 31 deletions

View File

@ -11,7 +11,7 @@
<div id="Panel">
<div class="logo"></div>
<?= $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?>
<?php echo $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?>
<?php $partial = array('menu.phtml', 'default');
$this->navigation()->menu()->setPartial($partial); ?>

View File

@ -11,7 +11,7 @@
<div id="Panel">
<div class="logo"></div>
<?= $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?>
<?php echo $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?>
<?php $partial = array('menu.phtml', 'default');
$this->navigation()->menu()->setPartial($partial); ?>

View File

@ -8,7 +8,7 @@
<?php echo $this->headLink() ?>
</head>
<body>
<div id="nowplayingbar"><?= $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?></div>
<div id="nowplayingbar"><?php echo $this->partial('partialviews/header.phtml', array("user" => $this->loggedInAs())) ?></div>
<div id="nav"><?php echo $this->navigation()->menu()->setRenderInvisible(true) ?></div>
<div class="wrapper">

View File

@ -482,10 +482,10 @@ class Schedule {
." ORDER BY st.starts DESC"
." LIMIT $count";
} else if ($timePeriod == 0){
$sql .= " AND st.starts < TIMESTAMP '$timeNow'"
$sql .= " AND st.starts <= TIMESTAMP '$timeNow'"
." AND st.ends > TIMESTAMP '$timeNow'";
} else if ($timePeriod > 0){
$sql .= " AND st.starts > TIMESTAMP '$timeNow'"
$sql .= " AND st.starts >= TIMESTAMP '$timeNow'"
." AND st.starts < (TIMESTAMP '$timeNow' + INTERVAL '$interval')"
." ORDER BY st.starts"
." LIMIT $count";

View File

@ -749,7 +749,7 @@ class Show_DAL{
$sql = "SELECT *, si.starts as start_timestamp, si.ends as end_timestamp FROM "
." $CC_CONFIG[showInstances] si, $CC_CONFIG[showTable] s"
." WHERE si.show_id = s.id"
." AND si.starts > TIMESTAMP '$timeNow'"
." AND si.starts >= TIMESTAMP '$timeNow'"
." AND si.starts < TIMESTAMP '$timeNow' + INTERVAL '48 hours'"
." ORDER BY si.starts"
." LIMIT 1";

View File

@ -33,7 +33,7 @@ function registerSongEndListener(func){
function notifySongEndListener(){
if (typeof songEndFunc == "function"){
//create a slight pause in execution to allow the browser
//create a slight delay in execution to allow the browser
//to update the display.
setTimeout(songEndFunc, 50);
}
@ -57,6 +57,7 @@ function secondsTimer(){
var date = new Date();
estimatedSchedulePosixTime = date.getTime() - localRemoteTimeOffset;
updateProgressBarValue();
updatePlaybar();
}
setTimeout(secondsTimer, uiUpdateInterval);
}
@ -64,7 +65,6 @@ function secondsTimer(){
function newSongStart(){
nextSongPrepare = true;
currentSong[0] = nextSongs.shift();
updatePlaybar();
notifySongEndListener();
}
@ -72,7 +72,6 @@ function newSongStart(){
function nextShowStart(){
nextShowPrepare = true;
currentShow[0] = nextShow.shift();
updatePlaybar();
}
/* Called every "uiUpdateInterval" mseconds. */
@ -129,8 +128,6 @@ function updateProgressBarValue(){
setTimeout(nextShowStart, diff);
}
}
updatePlaybar();
}
function updatePlaybar(){
@ -230,7 +227,7 @@ function parseItems(obj){
function getScheduleFromServer(){
$.ajax({ url: "/Schedule/get-current-playlist/format/json", dataType:"json", success:function(data){
parseItems(data.entries);
}});
}, error:function(jqXHR, textStatus, errorThrown){}});
setTimeout(getScheduleFromServer, serverUpdateInterval);
}
@ -241,27 +238,31 @@ function init() {
//begin consumer "thread"
secondsTimer();
$('#about-link').qtip({
content: $('#about-txt').html(),
show: 'mouseover',
hide: { when: 'mouseout', fixed: true },
position: {
corner: {
target: 'center',
tooltip: 'topRight'
}
},
style: {
border: {
width: 0,
radius: 4
var qtipElem = $('#about-link');
if (qtipElem.length > 0)
qtipElem.qtip({
content: $('#about-txt').html(),
show: 'mouseover',
hide: { when: 'mouseout', fixed: true },
position: {
corner: {
target: 'center',
tooltip: 'topRight'
}
},
name: 'light', // Use the default light style
}
});
style: {
border: {
width: 0,
radius: 4
},
name: 'light', // Use the default light style
}
});
}
$(document).ready(function() {
init();
if ($('#master-panel').length > 0)
init();
});