From 7f6828024ff20a833cc7a284fcdbed46407e21de Mon Sep 17 00:00:00 2001 From: Cliff Date: Thu, 5 Jul 2012 15:15:27 -0400 Subject: [PATCH 1/3] add support for precise 64&32, and will change the filename to liquidsoap_*_amd64/i386 --- dev_tools/fabric/fab_liquidsoap_compile.cfg | 2 +- dev_tools/fabric/fab_liquidsoap_compile.py | 26 ++++++++++++++------- dev_tools/fabric/run2.sh | 8 ++++--- 3 files changed, 23 insertions(+), 13 deletions(-) diff --git a/dev_tools/fabric/fab_liquidsoap_compile.cfg b/dev_tools/fabric/fab_liquidsoap_compile.cfg index bf6d462d8..8b99725c3 100644 --- a/dev_tools/fabric/fab_liquidsoap_compile.cfg +++ b/dev_tools/fabric/fab_liquidsoap_compile.cfg @@ -1,2 +1,2 @@ [main] -liquidsoap_tar_url = http://dl.dropbox.com/u/256410/airtime/liquidsoap.tar.gz +liquidsoap_tar_url = http://dl.dropbox.com/u/256410/airtime/liquidsoap-1.0.1-full.tar.gz diff --git a/dev_tools/fabric/fab_liquidsoap_compile.py b/dev_tools/fabric/fab_liquidsoap_compile.py index 06ca05730..8604cc7b8 100644 --- a/dev_tools/fabric/fab_liquidsoap_compile.py +++ b/dev_tools/fabric/fab_liquidsoap_compile.py @@ -149,6 +149,14 @@ def ubuntu_oneiric_64(fresh_os=True): if (fresh_os): create_fresh_os('Ubuntu_11.10_64') +def ubuntu_precise_64(fresh_os=True): + if (fresh_os): + create_fresh_os('Ubuntu_12.04_64') + +def ubuntu_precise_32(fresh_os=True): + if (fresh_os): + create_fresh_os('Ubuntu_12.04_32') + def debian_squeeze_32(fresh_os=True): if (fresh_os): create_fresh_os('Debian_Squeeze_32', debian=True) @@ -172,7 +180,7 @@ def compile_liquidsoap(filename="liquidsoap"): 'libmad-ocaml-dev libtaglib-ocaml-dev libalsa-ocaml-dev libtaglib-ocaml-dev libvorbis-ocaml-dev ' + \ 'libspeex-dev libspeexdsp-dev speex libladspa-ocaml-dev festival festival-dev ' + \ 'libsamplerate-dev libxmlplaylist-ocaml-dev libxmlrpc-light-ocaml-dev libflac-dev ' + \ - 'libxml-dom-perl libxml-dom-xpath-perl icecast2 patch autoconf libmp3lame-dev ' + \ + 'libxml-dom-perl libxml-dom-xpath-perl patch autoconf libmp3lame-dev ' + \ 'libcamomile-ocaml-dev libcamlimages-ocaml-dev libtool libpulse-dev libjack-dev camlidl') root = '/home/martin/src' @@ -183,11 +191,11 @@ def compile_liquidsoap(filename="liquidsoap"): do_run('mv %s %s/liquidsoap.tar.gz' % (tmpPath, root)) do_run('cd %s && tar xzf liquidsoap.tar.gz' % root) - do_run('cd %s/savonet && cp PACKAGES.minimal PACKAGES' % root) - sed('%s/savonet/PACKAGES' % root, '#ocaml-portaudio', 'ocaml-portaudio') - sed('%s/savonet/PACKAGES' % root, '#ocaml-alsa', 'ocaml-alsa') - sed('%s/savonet/PACKAGES' % root, '#ocaml-pulseaudio', 'ocaml-pulseaudio') - do_run('cd %s/savonet && ./bootstrap' % root) - do_run('cd %s/savonet && ./configure' % root) - do_run('cd %s/savonet && make' % root) - get('%s/savonet/liquidsoap/src/liquidsoap' % root, filename) + do_run('cd %s/liquidsoap-1.0.1-full && cp PACKAGES.minimal PACKAGES' % root) + sed('%s/liquidsoap-1.0.1-full/PACKAGES' % root, '#ocaml-portaudio', 'ocaml-portaudio') + sed('%s/liquidsoap-1.0.1-full/PACKAGES' % root, '#ocaml-alsa', 'ocaml-alsa') + sed('%s/liquidsoap-1.0.1-full/PACKAGES' % root, '#ocaml-pulseaudio', 'ocaml-pulseaudio') + do_run('cd %s/liquidsoap-1.0.1-full && ./bootstrap' % root) + do_run('cd %s/liquidsoap-1.0.1-full && ./configure' % root) + do_run('cd %s/liquidsoap-1.0.1-full && make' % root) + get('%s/liquidsoap-1.0.1-full/liquidsoap-1.0.1/src/liquidsoap' % root, filename) diff --git a/dev_tools/fabric/run2.sh b/dev_tools/fabric/run2.sh index 2aa92de33..051326f9c 100755 --- a/dev_tools/fabric/run2.sh +++ b/dev_tools/fabric/run2.sh @@ -2,7 +2,7 @@ exec 2>&1 -ubuntu_versions=("ubuntu_lucid_32" "ubuntu_lucid_64" "ubuntu_maverick_32" "ubuntu_maverick_64" "ubuntu_natty_32" "ubuntu_natty_64" "ubuntu_oneiric_32" "ubuntu_oneiric_64" "debian_squeeze_32" "debian_squeeze_64") +ubuntu_versions=("ubuntu_lucid_32" "ubuntu_lucid_64" "ubuntu_maverick_32" "ubuntu_maverick_64" "ubuntu_natty_32" "ubuntu_natty_64" "ubuntu_oneiric_32" "ubuntu_oneiric_64" "debian_squeeze_32" "debian_squeeze_64" "ubuntu_precise_32" "ubuntu_precise_64") num1=${#ubuntu_versions[@]} @@ -10,6 +10,8 @@ mkdir -p ./upgrade_logs2 for i in $(seq 0 $(($num1 -1))); do - echo "fab -f fab_liquidsoap_compile.py ${ubuntu_versions[$i]} compile_liquidsoap:filename=${ubuntu_versions[$i]} shutdown" - fab -f fab_liquidsoap_compile.py ${ubuntu_versions[$i]} compile_liquidsoap:filename=${ubuntu_versions[$i]} shutdown 2>&1 #| tee "./upgrade_logs2/${ubuntu_versions[$i]}.log" + + binfilename=`echo ${ubuntu_versions[$i]} | sed -e 's/ubuntu/liquidsoap/g' -e 's/debian/liquidsoap/g' -e 's/32/i386/g' -e 's/64/amd64/g'` + echo "fab -f fab_liquidsoap_compile.py ${ubuntu_versions[$i]} compile_liquidsoap:filename=$binfilename shutdown" + fab -f fab_liquidsoap_compile.py ${ubuntu_versions[$i]} compile_liquidsoap:filename=$binfilename shutdown 2>&1 #| tee "./upgrade_logs2/${ubuntu_versions[$i]}.log" done From 31f1d5879e8897147a16760c235f6b31d4beaf22 Mon Sep 17 00:00:00 2001 From: James Date: Thu, 5 Jul 2012 18:23:34 -0400 Subject: [PATCH 2/3] CC-4076: Library: make doubleclick trigger adding files to playlist/timeline - done --- .../library/events/library_playlistbuilder.js | 12 ++++++++ .../library/events/library_showbuilder.js | 29 +++++++++++++++++++ .../public/js/airtime/library/library.js | 27 +++++++++++++++-- 3 files changed, 65 insertions(+), 3 deletions(-) diff --git a/airtime_mvc/public/js/airtime/library/events/library_playlistbuilder.js b/airtime_mvc/public/js/airtime/library/events/library_playlistbuilder.js index 249af5d55..4f93a02b0 100644 --- a/airtime_mvc/public/js/airtime/library/events/library_playlistbuilder.js +++ b/airtime_mvc/public/js/airtime/library/events/library_playlistbuilder.js @@ -88,6 +88,18 @@ var AIRTIME = (function(AIRTIME){ }); }; + mod.dblClickAdd = function(id, type) { + var i, + aMediaIds = []; + + //process selected files/playlists. + if (type === "audioclip") { + aMediaIds.push(id); + } + + AIRTIME.playlist.fnAddItems(aMediaIds, undefined, 'after'); + }; + mod.setupLibraryToolbar = function() { var $toolbar = $(".lib-content .fg-toolbar:first"); diff --git a/airtime_mvc/public/js/airtime/library/events/library_showbuilder.js b/airtime_mvc/public/js/airtime/library/events/library_showbuilder.js index 7d841c56d..15ec22f66 100644 --- a/airtime_mvc/public/js/airtime/library/events/library_showbuilder.js +++ b/airtime_mvc/public/js/airtime/library/events/library_showbuilder.js @@ -87,6 +87,35 @@ var AIRTIME = (function(AIRTIME){ }); }; + mod.dblClickAdd = function(id, type) { + + var i, + length, + temp, + aMediaIds = [], + aSchedIds = [], + aData = []; + + //process selected files/playlists. + aMediaIds.push({"id": id, "type": type}); + + $("#show_builder_table tr.cursor-selected-row").each(function(i, el){ + aData.push($(el).prev().data("aData")); + }); + + //process selected schedule rows to add media after. + for (i=0, length = aData.length; i < length; i++) { + temp = aData[i]; + aSchedIds.push({"id": temp.id, "instance": temp.instance, "timestamp": temp.timestamp}); + } + + if(aSchedIds.length == 0){ + alert("Please select a cursor position on timeline."); + return false; + } + AIRTIME.showbuilder.fnAdd(aMediaIds, aSchedIds); + }; + mod.setupLibraryToolbar = function() { var $toolbar = $(".lib-content .fg-toolbar:first"); diff --git a/airtime_mvc/public/js/airtime/library/library.js b/airtime_mvc/public/js/airtime/library/library.js index 2f6910978..3f623484b 100644 --- a/airtime_mvc/public/js/airtime/library/library.js +++ b/airtime_mvc/public/js/airtime/library/library.js @@ -428,11 +428,32 @@ var AIRTIME = (function(AIRTIME) { return false; }); + alreadyclicked=false; //call the context menu so we can prevent the event from propagating. $(nRow).find('td:not(.library_checkbox, .library_type)').click(function(e){ - - $(this).contextMenu({x: e.pageX, y: e.pageY}); - + var el=$(this); + if (alreadyclicked) + { + alreadyclicked=false; // reset + clearTimeout(alreadyclickedTimeout); // prevent this from happening + // do what needs to happen on double click. + + $tr = $(el).parent(); + data = $tr.data("aData"); + AIRTIME.library.dblClickAdd(data.id, data.ftype); + //AIRTIME.playlist.fnAddItems([data.id], undefined, 'after'); + } + else + { + alreadyclicked=true; + alreadyclickedTimeout=setTimeout(function(){ + alreadyclicked=false; // reset when it happens + // do what needs to happen on single click. + // use el instead of $(this) because $(this) is + // no longer the element + el.contextMenu({x: e.pageX, y: e.pageY}); + },300); // <-- dblclick tolerance here + } return false; }); From 63856ea91888ca183c7c8e250891abfd65f53ad8 Mon Sep 17 00:00:00 2001 From: James Date: Fri, 6 Jul 2012 15:40:16 -0400 Subject: [PATCH 3/3] CC-4079: Apache error: missing $startDt variable - fixed --- airtime_mvc/application/models/Show.php | 1 + 1 file changed, 1 insertion(+) diff --git a/airtime_mvc/application/models/Show.php b/airtime_mvc/application/models/Show.php index 270d065ad..e7cf6967b 100644 --- a/airtime_mvc/application/models/Show.php +++ b/airtime_mvc/application/models/Show.php @@ -1351,6 +1351,7 @@ class Application_Model_Show { } private static function advanceRepeatingDate($p_interval, $start, $timezone){ + $startDt = new DateTime($start, new DateTimeZone($timezone)); if ($p_interval == 'P1M'){ /* When adding months, there is a problem if we are on January 31st and add one month with PHP. * What ends up happening is that since February 31st doesn't exist, the date returned is