diff --git a/mpd/RADIO/KUVO HD2 - Jazz with Bob Parlocha.pls b/mpd/RADIO/KUVO HD2.pls similarity index 71% rename from mpd/RADIO/KUVO HD2 - Jazz with Bob Parlocha.pls rename to mpd/RADIO/KUVO HD2.pls index 688a31998..ef4d8b25a 100755 --- a/mpd/RADIO/KUVO HD2 - Jazz with Bob Parlocha.pls +++ b/mpd/RADIO/KUVO HD2.pls @@ -1,6 +1,6 @@ [playlist] numberofentries=1 File1=http://kuvo-ice.streamguys.org/kuvohd2-aac-128 -Title1=KUVO HD2 - Jazz with Bob Parlocha +Title1=KUVO HD2 Length1=-1 version=2 diff --git a/other/build/build_recipe_v2.8.txt b/other/build/build_recipe_v2.8.txt index cf2bb23b0..ff8b046cd 100644 --- a/other/build/build_recipe_v2.8.txt +++ b/other/build/build_recipe_v2.8.txt @@ -1,8 +1,8 @@ ################################################################ # -# Build Recipe v2.8, 2019-04-12 +# Build Recipe v2.8, 2019-05-07 # -# moOde 5.0 2019-04-12 +# moOde 5.2 2019-05-07 # # These instructions are written for Linux Enthusiasts # and System Integrators and provide a recipe for making @@ -148,8 +148,8 @@ sudo timedatectl set-timezone "America/Detroit" // cd ~ -wget http://moodeaudio.org/downloads/prod/rel-stretch-r50.zip -sudo unzip ./rel-stretch-r50.zip +wget http://moodeaudio.org/downloads/prod/rel-stretch-r52.zip +sudo unzip ./rel-stretch-r52.zip 5. Expand the root partition to 3GB. @@ -198,13 +198,12 @@ samba smbclient udisks-glue ntfs-3g exfat-fuse git inotify-tools libav-tools ava python3-setuptools libmediainfo0v5 libmms0 libtinyxml2-4 libzen0v5 libmediainfo-dev libzen-dev # meson -sudo cp ./rel-stretch/other/mpd/build-tools/meson-0.48.1.tar.gz ./ -sudo tar xfz meson-0.48.1.tar.gz -cd meson-0.48.1 +sudo cp ./rel-stretch/other/mpd/build-tools/meson-0.50.1.tar.gz ./ +sudo tar xfz meson-0.50.1.tar.gz +cd meson-0.50.1 sudo python3 setup.py install cd ~ -sudo rm -rf meson-0.48.1 -sudo rm -f meson-0.48.1.tar.gz +sudo rm -rf meson-0.50.1* # mediainfo sudo cp ./rel-stretch/other/mediainfo/mediainfo-18.12 /usr/local/bin/mediainfo @@ -240,7 +239,7 @@ sudo autoreconf --install sudo ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --enable-library sudo make sudo make install -cd ~ +cd .. sudo rm -rf ./bluez-5.50* # Delete symlink and bin for old bluetoothd @@ -261,7 +260,7 @@ cd build sudo ../configure --disable-hcitop --with-alsaplugindir=/usr/lib/arm-linux-gnueabihf/alsa-lib sudo make sudo make install -cd ~ +cd ../.. sudo rm -rf bluez-alsa-master* 3. Services are started by moOde Worker so lets disable them here. @@ -345,15 +344,15 @@ libboost-dev \ libicu-dev \ libglib2.0-dev -3. Download MPD 0.20.20 sources and prep for compile. +3. Download MPD 0.20.23 sources and prep for compile. # Optionally install pre-compiled binary and skip to STEP 7 -sudo cp ./rel-stretch/other/mpd/mpd-0.20.20 /usr/local/bin/mpd +sudo cp ./rel-stretch/other/mpd/mpd-0.20.23 /usr/local/bin/mpd sudo reboot -sudo wget http://www.musicpd.org/download/mpd/0.20/mpd-0.20.20.tar.xz -sudo tar xf mpd-0.20.20.tar.xz -cd mpd-0.20.20 +sudo wget http://www.musicpd.org/download/mpd/0.20/mpd-0.20.23.tar.xz +sudo tar xf mpd-0.20.23.tar.xz +cd mpd-0.20.23 sudo sh autogen.sh 4. Configure compile options. @@ -376,7 +375,7 @@ sudo make sudo make install sudo strip --strip-unneeded /usr/local/bin/mpd cd ~ -sudo rm -rf ./mpd-0.20.20* +sudo rm -rf ./mpd-0.20.23* sudo apt-get clean sudo apt-get -y autoremove @@ -426,15 +425,15 @@ libboost-dev \ libicu-dev \ libglib2.0-dev -3. Download MPD 0.21.6 sources and prep for compile. +3. Download MPD 0.21.8 sources and prep for compile. # Optionally install pre-compiled binary and skip to STEP 7 -sudo cp ./rel-stretch/other/mpd/mpd-0.21.6 /usr/local/bin/mpd +sudo cp ./rel-stretch/other/mpd/mpd-0.21.8 /usr/local/bin/mpd sudo reboot -sudo wget http://www.musicpd.org/download/mpd/0.21/mpd-0.21.6.tar.xz -sudo tar xf mpd-0.21.6.tar.xz -cd mpd-0.21.6 +sudo wget http://www.musicpd.org/download/mpd/0.21/mpd-0.21.8.tar.xz +sudo tar xf mpd-0.21.8.tar.xz +cd mpd-0.21.8 sudo meson . output/release --buildtype=release -Db_ndebug=true 4. Configure compile options. @@ -490,7 +489,7 @@ output/release sudo ninja -C output/release sudo ninja -C output/release install cd ~ -sudo rm -rf ./mpd-0.21.6* +sudo rm -rf ./mpd-0.21.8* sudo apt-get clean sudo apt-get -y autoremove @@ -582,6 +581,7 @@ sudo chmod 0755 /home/pi/*.sh sudo chmod 0755 /home/pi/*.php sudo chmod 0755 /var/www/command/* +sudo sqlite3 /var/local/www/db/moode-sqlite3.db "CREATE TRIGGER ro_columns BEFORE UPDATE OF param, value, [action] ON cfg_hash FOR EACH ROW BEGIN SELECT RAISE(ABORT, 'read only'); END;" sudo sqlite3 /var/local/www/db/moode-sqlite3.db "update cfg_system set value='Emerald' where param='accent_color'" 3. Permissions for service files @@ -619,10 +619,11 @@ sudo systemctl disable squeezelite sudo chmod 0644 /lib/systemd/system/upmpdcli.service sudo systemctl disable upmpdcli.service -5. Reset dir permissions for var local +5. Reset permissions for var and usr local sudo chmod -R 0755 /var/local/www sudo chmod -R 0777 /var/local/www/db sudo chmod -R ug-s /var/local/www +sudo chmod -R 0755 /usr/local/bin 6. Initial permissions for certain files. These also get set during moOde Worker startup. @@ -678,12 +679,16 @@ sudo reboot // //////////////////////////////////////////////////////////////// - +# kernel ver 4.19.40 +echo "y" | sudo PRUNE_MODULES=1 rpi-update 6cb1da772a8c56f44591bec904046b15f1126949 # kernel ver 4.19.34 echo "y" | sudo PRUNE_MODULES=1 rpi-update 99c274691c07480762dcda91a0ebfe3c4f519307 # Fix for missing 4.19.y regulatory.db files sudo cp ./rel-stretch/other/firmware/regulatory.db* /lib/firmware +# kernel ver 4.14.98 +echo "y" | sudo PRUNE_MODULES=1 rpi-update a08ece3d48c3c40bf1b501772af9933249c11c5b + # cleanup sudo rm -rf /lib/modules.bak sudo rm -rf /boot.bak @@ -818,9 +823,10 @@ sudo chmod 0755 /usr/local/etc/mpdasrc sudo apt-get -y install autoconf libtool libdaemon-dev libasound2-dev libpopt-dev libconfig-dev \ avahi-daemon libavahi-client-dev libssl-dev libsoxr-dev -sudo cp ./rel-stretch/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613.zip ./ -sudo unzip ./shairport-sync-3.3.0-rc2-ff9c613.zip -cd ./shairport-sync-3.3RC2 +sudo cp ./rel-stretch/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236.zip ./ +sudo unzip ./shairport-sync-3.3.0-rc6-0c65236.zip +cd ./shairport-sync-0c6523636cd8cef950a33381621f2cbe9b7dd4de + sudo autoreconf -i -f sudo ./configure --with-alsa --with-avahi --with-ssl=openssl --with-soxr --with-metadata --with-stdout --with-systemd --with-dbus-interface --sysconfdir=/etc @@ -1003,7 +1009,7 @@ d. Optionally, enter url chrome://extensions and install the xontab virtual keyb cd ~ wget https://github.com/allocom/piano-firmware/archive/master.zip -sudo unzip master.zip +sudo unzip -q master.zip sudo rm ./master.zip sudo cp -r ./piano-firmware-master/lib/firmware/allo /lib/firmware sudo rm -rf ./piano-firmware-master diff --git a/other/librespot/librespot-daeeeaa-armv61 b/other/librespot/librespot-daeeeaa-armv6l similarity index 100% rename from other/librespot/librespot-daeeeaa-armv61 rename to other/librespot/librespot-daeeeaa-armv6l diff --git a/other/mpd/build-tools/meson-0.48.1.tar.gz b/other/mpd/build-tools/meson-0.48.1.tar.gz deleted file mode 100644 index 1be7cd57f..000000000 Binary files a/other/mpd/build-tools/meson-0.48.1.tar.gz and /dev/null differ diff --git a/other/mpd/build-tools/meson-0.50.1.tar.gz b/other/mpd/build-tools/meson-0.50.1.tar.gz new file mode 100644 index 000000000..f6ee8bd23 Binary files /dev/null and b/other/mpd/build-tools/meson-0.50.1.tar.gz differ diff --git a/other/mpd/mpd-0.20.20 b/other/mpd/mpd-0.20.20 deleted file mode 100755 index bf2c5bb56..000000000 Binary files a/other/mpd/mpd-0.20.20 and /dev/null differ diff --git a/other/mpd/mpd-0.20.20.tar.xz b/other/mpd/mpd-0.20.20.tar.xz deleted file mode 100644 index 1a841ce92..000000000 Binary files a/other/mpd/mpd-0.20.20.tar.xz and /dev/null differ diff --git a/other/mpd/mpd-0.20.23 b/other/mpd/mpd-0.20.23 new file mode 100755 index 000000000..d54feba00 Binary files /dev/null and b/other/mpd/mpd-0.20.23 differ diff --git a/other/mpd/mpd-0.20.23.tar.xz b/other/mpd/mpd-0.20.23.tar.xz new file mode 100644 index 000000000..2189bf6da Binary files /dev/null and b/other/mpd/mpd-0.20.23.tar.xz differ diff --git a/other/mpd/mpd-0.21.6 b/other/mpd/mpd-0.21.6 deleted file mode 100755 index 199d33b86..000000000 Binary files a/other/mpd/mpd-0.21.6 and /dev/null differ diff --git a/other/mpd/mpd-0.21.6.tar.xz b/other/mpd/mpd-0.21.6.tar.xz deleted file mode 100644 index 1eb7ef0e2..000000000 Binary files a/other/mpd/mpd-0.21.6.tar.xz and /dev/null differ diff --git a/other/mpd/mpd-0.21.8 b/other/mpd/mpd-0.21.8 new file mode 100755 index 000000000..c76f9d927 Binary files /dev/null and b/other/mpd/mpd-0.21.8 differ diff --git a/other/mpd/mpd-0.21.8.tar.xz b/other/mpd/mpd-0.21.8.tar.xz new file mode 100644 index 000000000..565ad84c3 Binary files /dev/null and b/other/mpd/mpd-0.21.8.tar.xz differ diff --git a/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613 b/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613 deleted file mode 100755 index b97832427..000000000 Binary files a/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613 and /dev/null differ diff --git a/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613.zip b/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613.zip deleted file mode 100644 index 5cfd46ec6..000000000 Binary files a/other/shairport-sync/shairport-sync-3.3.0-rc2-ff9c613.zip and /dev/null differ diff --git a/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236 b/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236 new file mode 100755 index 000000000..30237b8ce Binary files /dev/null and b/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236 differ diff --git a/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236.zip b/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236.zip new file mode 100644 index 000000000..60ac0ef87 Binary files /dev/null and b/other/shairport-sync/shairport-sync-3.3.0-rc6-0c65236.zip differ diff --git a/usr/local/bin/moodeutl.php b/usr/local/bin/moodeutl similarity index 98% rename from usr/local/bin/moodeutl.php rename to usr/local/bin/moodeutl index 989950f94..bb8b0e2b5 100644 --- a/usr/local/bin/moodeutl.php +++ b/usr/local/bin/moodeutl @@ -17,11 +17,11 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ -define('VERSION', '1.0'); +define('VERSION', '1.1'); $option = isset($argv[1]) ? $argv[1] : ''; diff --git a/var/local/www/db/moode-sqlite3.db.default b/var/local/www/db/moode-sqlite3.db.default index 4d195075d..e5a5c5799 100755 Binary files a/var/local/www/db/moode-sqlite3.db.default and b/var/local/www/db/moode-sqlite3.db.default differ diff --git a/var/local/www/db/moode-sqlite3.db.schema b/var/local/www/db/moode-sqlite3.db.schema index 63ee868e5..69d6285db 100755 --- a/var/local/www/db/moode-sqlite3.db.schema +++ b/var/local/www/db/moode-sqlite3.db.schema @@ -12,5 +12,6 @@ CREATE TABLE cfg_hash (id INTEGER PRIMARY KEY, param CHAR (64), value CHAR (64), CREATE TABLE cfg_mpd (id INTEGER PRIMARY KEY, param CHAR (32), value CHAR (32)); CREATE TABLE cfg_radio (id INTEGER PRIMARY KEY, station CHAR (128), name CHAR (128), type CHAR (8), logo CHAR (128)); CREATE TABLE cfg_gpio (id INTEGER PRIMARY KEY, pin CHAR (2), enabled CHAR (1), command CHAR (64), param CHAR (32), value CHAR (32)); -CREATE UNIQUE INDEX IndexName ON cfg_source (name); CREATE TABLE cfg_audiodev (id INTEGER PRIMARY KEY, name CHAR (64), dacchip CHAR (64), chipoptions CHAR (64), iface CHAR (32), list CHAR (10), driver CHAR (64), drvoptions CHAR (64)); +CREATE UNIQUE INDEX IndexName ON cfg_source (name); +CREATE TRIGGER ro_columns BEFORE UPDATE OF param, value, [action] ON cfg_hash FOR EACH ROW BEGIN SELECT RAISE(ABORT, 'read only'); END; diff --git a/var/local/www/header.php b/var/local/www/header.php index 70a5d1680..cf8902ffa 100644 --- a/var/local/www/header.php +++ b/var/local/www/header.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/apl-config.php b/www/apl-config.php index 51ff0990f..1aa957666 100755 --- a/www/apl-config.php +++ b/www/apl-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/blu-config.php b/www/blu-config.php index b0c15ac3e..2d5b4a6f9 100755 --- a/www/blu-config.php +++ b/www/blu-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/chp-config.php b/www/chp-config.php index 7a41d209b..54508e573 100755 --- a/www/chp-config.php +++ b/www/chp-config.php @@ -16,7 +16,7 @@ * Refer to the link below for a copy of the GNU General Public License. * http://www.gnu.org/licenses/ * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/command/moode.php b/www/command/moode.php index 645a8c120..fc5c865b5 100755 --- a/www/command/moode.php +++ b/www/command/moode.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -403,19 +403,19 @@ if ($_GET['cmd'] == 'newstation') { // cant have same name as existing station - $result = sdbquery("SELECT id FROM cfg_radio WHERE name='" . $station_name . "'", $dbh); + $result = sdbquery("SELECT id FROM cfg_radio WHERE name='" . SQLite3::escapeString($station_name) . "'", $dbh); // true = query successful but no results, array = results, false = query bombed (not likely) if ($result === true) { // add new row to sql table - $values = "'" . $_POST['url'] . "'," . "'" . $station_name . "','u','local'"; + $values = "'" . $_POST['url'] . "'," . "'" . SQLite3::escapeString($station_name) . "','u','local'"; $result = sdbquery('INSERT INTO cfg_radio VALUES (NULL,' . $values . ')', $dbh); // NULL causes the Id column to be set to the next number } } else { // if name changed then its same as an add and we have to check the name doesnt already exist // if only the url changed then we update - $result = cfgdb_update('cfg_radio', $dbh, $station_name, $_POST['url']); + $result = cfgdb_update('cfg_radio', $dbh, SQLite3::escapeString($station_name), $_POST['url']); } // add session var @@ -454,7 +454,7 @@ workerLog($_GET['cmd'] . ', ' . $station_name); // remove row and delete file - $result = sdbquery("DELETE FROM cfg_radio WHERE name='" . $station_name . "'", $dbh); + $result = sdbquery("DELETE FROM cfg_radio WHERE name='" . SQLite3::escapeString($station_name) . "'", $dbh); sysCmd('rm "' . MPD_MUSICROOT . $_POST['path'] . '"'); sysCmd('rm "' . '/var/www/images/radio-logos/' . $station_name . '.jpg' . '"'); sysCmd('rm "' . '/var/www/images/radio-logos/thumbs/' . $station_name . '.jpg' . '"'); diff --git a/www/command/worker.php b/www/command/worker.php index 983db9264..bce57b299 100755 --- a/www/command/worker.php +++ b/www/command/worker.php @@ -20,7 +20,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -134,13 +134,6 @@ $_SESSION['raspbianver'] = $result[0]; $_SESSION['moode_release'] = getMoodeRel(); -// exit if running an unsupported hdwrrev -if (substr($_SESSION['hdwrrev'], 0, 6) == 'Pi-CM3') { - workerLog('worker: Unsupported hardware platform (' . $_SESSION['hdwrrev'] . ')'); - workerLog('worker: Exited'); - exit; -} - // log platform data workerLog('worker: Rel (Moode ' . getMoodeRel('verbose') . ')'); // X.Y yyyy-mm-dd ex: 2.6 2016-06-07 workerLog('worker: Upd (' . $_SESSION['pkgdate'] . ')'); diff --git a/www/css/fontawesome-moode.css b/www/css/fontawesome-moode.css index 433fdb6d6..ea2201864 100644 --- a/www/css/fontawesome-moode.css +++ b/www/css/fontawesome-moode.css @@ -2,7 +2,7 @@ * Font Awesome Pro 5.0.10 by @fontawesome - https://fontawesome.com * License - https://fontawesome.com/license (Commercial License) * - * 2019-04-12 TC moOde 5.0 + * 2019-04-12 TC moOde 5.1 * */ .fa, diff --git a/www/css/moode.css b/www/css/moode.css index f56b67abf..e8bedf257 100644 --- a/www/css/moode.css +++ b/www/css/moode.css @@ -15,7 +15,7 @@ * Refer to the link below for a copy of the GNU General Public License. * http://www.gnu.org/licenses/ * - * 2019-04-12 TC moOde 4.5 + * 2019-05-07 TC moOde 5.2 * */ @@ -190,7 +190,7 @@ li.modal-dropdown-text:focus {color:#eee;} #timeline {display:block;} #mobile-time {display:block;} .btn btn-cmd btn-toggle {font-size:.75em;} - img.coverart {width:50vh;height:auto;max-width:83vw;border:none;} + img.coverart {width:50vh;height:auto;max-width:90vw;max-height:90vw;border:none;} img.libart {width:90%;} .modal-sm2 {min-width:80%;} .form-horizontal .controls {margin-left:0;} @@ -208,7 +208,7 @@ li.modal-dropdown-text:focus {color:#eee;} #menu-settings {font-size:1.65rem;padding:0 .5em;} #menu-settings i {font-size:1rem;} .playlist span {margin-left:calc(3.5rem + 1vmin);} - .playlist {padding:0 0 8rem 0;} + .playlist {padding:0 0 8rem 0;min-height:33vh;} .playlist li, .playlist .active {padding-left:.5em;} .playlist li:before {font-size:unset;} #lib-albumcover {left:0;} @@ -376,13 +376,16 @@ li.modal-dropdown-text:focus {color:#eee;} #index-radio ul li:nth-child(4n+0), #index-browse ul li:nth-child(4n+0), #index-albumcovers ul li:nth-child(4n+0) {display:block !important;} } -/* app stuff for Max */ +/* iPhone X */ +@media (width: 375px) and (height:812px) { + .playlist {padding:0 0 8rem 0;min-height:35vh;} +} + +/* iPhone X Max */ @media (width: 414px) and (height:818px) { #menu-top {padding-top:calc(env(safe-area-inset-top) - .5em);} .viewswitch {top:calc(env(safe-area-inset-top) - .5em);} .btnlist.btnlist-top.btnlist-top-pl, .btnlist.btnlist-top.btnlist-top-lib {top:calc(env(safe-area-inset-top) - .25em);} - img.coverart {max-width:90vw;max-height:90vw;} - .playlist {padding:0 0 11rem 0;} #songsList {padding-bottom:calc(5.5em + env(safe-area-inset-bottom));} .ui-pnotify {top: calc(env(safe-area-inset-top));right: calc(env(safe-area-inset-right) + 1em);} #playbar-cover {margin-left:.5em;border-radius:.1em .1em .1em 50%;} @@ -400,7 +403,6 @@ li.modal-dropdown-text:focus {color:#eee;} .database-radiolist .db-entry, .database-radiolist .cover-menu {font-size:1.2em;} } - @media (width: 896px) and (height:414px) { .span5 {margin-left:calc(env(safe-area-inset-left) - 2rem);} .span4 {margin-right:calc(env(safe-area-inset-right) - 2rem);} diff --git a/www/css/panels.css b/www/css/panels.css index 43344e00e..4630cfd78 100644 --- a/www/css/panels.css +++ b/www/css/panels.css @@ -18,7 +18,7 @@ * Refer to the link below for a copy of the GNU General Public License. * http://www.gnu.org/licenses/ * - * 2019-04-12 TC moOde 4.5 + * 2019-05-07 TC moOde 5.2 * */ @@ -86,7 +86,7 @@ html {background-color:inherit;} #extratags {font-size:1rem;color:var(--textvariant);padding-top:0;text-align:center;display:block;} #currentsong {padding-top:1.3rem;font-size:1.35em;font-weight:bold;color:var(--accentxts);word-wrap:break-word;cursor:pointer;} .tab-content.visacc #currentsong, .tab-content.visacc #currentsong a {color:var(--adapttext);} -#currentalbum {font-size:1.15em;padding-top:1.3rem;/*color:var(--textvariant);*/} +#currentalbum {font-size:1.15em;padding-top:1.3rem;cursor:pointer;} .tab-content.visacc #currentalbum {color:var(--textvariant);} #playlist-position, #format-bitrate {color:inherit;opacity:.55;} .container-playback {padding:0px;color:inherit;margin-top:env(safe-area-inset-top);} @@ -206,7 +206,7 @@ img.coverart {border-style:none;border-radius:.1em;box-shadow:0 .1em .2em rgba(3 .icon-root {color:inherit;} .playlist .pl-action {float:right;padding:0px;text-align:center;} .database .db-action {float:left;width:1.875em;padding:0;position:relative;} -.playlist .pl-action a, .playlist .db-action a {position:relative;font-weight:normal;text-decoration:none;z-index:3;font-size:inherit;line-height:.625em;padding:.318em 1em;width:2.2em;} +.playlist .pl-action, .playlist .db-action a {position:relative;font-weight:normal;text-decoration:none;z-index:3;font-size:inherit;line-height:.625em;padding:.318em 1em;width:2.2em;} #db-search-results {font-style:italic;float:left;padding:1em .5em 0em .5em;font-size:1em;display:none;} #pl-filter-results, #lib-album-filter-results, #ra-filter-results {font-style:italic;float:left;font-size:1em;position:relative;top:50%;transform:translate(0, -50%);} #pl-filter-results i {color:#34495E;} @@ -425,7 +425,6 @@ input[type='range'].vslide2::-webkit-slider-thumb {background:#fff;background-im .alphabits ul {display:table;height:100%;margin:0 !important;border-spacing:.2em;} .alphabits ul li {display:table-row !important;font-size:.7em;text-align:center !important;text-transform:uppercase;opacity:.75;line-height:normal;} /* playback ellipsis context menu */ -#context-menu-playback .dropdown-menu > li > a {/*float:left;*/} #context-menu-playback .dropdown-menu {min-width:12rem;} #menu-check-consume, #menu-check-repeat, #menu-check-single {display:none;float:right;color:var(--adapttext);line-height:2.75em;position:absolute;right:.5em;} /* playbar */ diff --git a/www/eqg-config.php b/www/eqg-config.php index f83c7c304..2b9c6b36e 100755 --- a/www/eqg-config.php +++ b/www/eqg-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -76,7 +76,7 @@ $_search_curve = 'Flat'; } elseif (isset($_POST['rmcurve'])) { - $result = sdbquery("DELETE FROM cfg_eqalsa WHERE curve_name='" . $_POST['rm-curve'] . "'", $dbh); + $result = sdbquery("DELETE FROM cfg_eqalsa WHERE curve_name='" . $_GET['curve'] . "'", $dbh); $_search_curve = 'Flat'; $_SESSION['notify']['title'] = 'Curve removed'; } diff --git a/www/eqp-config.php b/www/eqp-config.php index f9c7d1084..4a1e1f2d5 100755 --- a/www/eqp-config.php +++ b/www/eqp-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -75,12 +75,13 @@ $_SESSION['notify']['title'] = 'Playing curve'; } +//workerLog('newcurvename=(' . $_POST['newcurvename'] . '), rmcurve=(' . $_POST['rmcurve'] . '), curve=(' . $_GET['curve'] . ')'); // add, remove, change, refresh if (isset($_POST['newcurvename'])) { $_search_curve = 'Default'; } elseif (isset($_POST['rmcurve'])) { - $result = sdbquery("DELETE FROM cfg_eqfa4p WHERE curve_name='" . $_POST['rm-curve'] . "'", $dbh); + $result = sdbquery("DELETE FROM cfg_eqfa4p WHERE curve_name='" . $_GET['curve'] . "'", $dbh); $_search_curve = 'Default'; $_SESSION['notify']['title'] = 'Curve removed'; } diff --git a/www/footer.php b/www/footer.php index f83a1ba87..c45457af2 100644 --- a/www/footer.php +++ b/www/footer.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -31,7 +31,7 @@

Moode Audio Player is a derivative of the wonderful WebUI audio player client for MPD originally designed and coded by Andrea Coiutti and Simone De Gregori, and subsequently enhanced by early efforts from the RaspyFi/Volumio projects.

Release Information

    -
  • Release: 5.1 2019-04-22 View relnotes
  • +
  • Release: 5.2 2019-05-07 View relnotes
  • Update: ()
  • Setup guide: View guide
  • Coding: Tim Curtis © 2014 Moode Audio, Twitter
  • diff --git a/www/gpio-config.php b/www/gpio-config.php index e0d4a3e66..cca57353b 100755 --- a/www/gpio-config.php +++ b/www/gpio-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/images/radio-logos/KUVO HD2 - Jazz with Bob Parlocha.jpg b/www/images/radio-logos/KUVO HD2.jpg similarity index 100% rename from www/images/radio-logos/KUVO HD2 - Jazz with Bob Parlocha.jpg rename to www/images/radio-logos/KUVO HD2.jpg diff --git a/www/images/radio-logos/thumbs/KUVO HD2 - Jazz with Bob Parlocha.jpg b/www/images/radio-logos/thumbs/KUVO HD2.jpg similarity index 100% rename from www/images/radio-logos/thumbs/KUVO HD2 - Jazz with Bob Parlocha.jpg rename to www/images/radio-logos/thumbs/KUVO HD2.jpg diff --git a/www/inc/Zend/Media/Flac/MetadataBlock/Application.php b/www/inc/Zend/Media/Flac/MetadataBlock/Application.php index bf06bbb86..9cf97a7bf 100755 --- a/www/inc/Zend/Media/Flac/MetadataBlock/Application.php +++ b/www/inc/Zend/Media/Flac/MetadataBlock/Application.php @@ -40,8 +40,20 @@ * @license http://framework.zend.com/license/new-bsd New BSD License * @version $Id: Application.php 241 2011-06-11 16:46:52Z svollbehr $ */ + +/** + * 2019-05-07 TC moOde 5.2 + * add private var declarations + */ + final class Zend_Media_Flac_MetadataBlock_Application extends Zend_Media_Flac_MetadataBlock { + /** @var integer */ + private $_identifier; + + /** @var string */ + private $_data; + /** * Constructs the class with given parameters and parses object related data. * diff --git a/www/inc/mpd-0.20.20 b/www/inc/mpd-0.20.20 deleted file mode 100755 index bf2c5bb56..000000000 Binary files a/www/inc/mpd-0.20.20 and /dev/null differ diff --git a/www/inc/mpd-0.20.23 b/www/inc/mpd-0.20.23 new file mode 100755 index 000000000..d54feba00 Binary files /dev/null and b/www/inc/mpd-0.20.23 differ diff --git a/www/inc/mpd-0.21.6 b/www/inc/mpd-0.21.6 deleted file mode 100755 index 199d33b86..000000000 Binary files a/www/inc/mpd-0.21.6 and /dev/null differ diff --git a/www/inc/mpd-0.21.8 b/www/inc/mpd-0.21.8 new file mode 100755 index 000000000..c76f9d927 Binary files /dev/null and b/www/inc/mpd-0.21.8 differ diff --git a/www/inc/playerlib.php b/www/inc/playerlib.php index 3f3c6a353..42cf01ad5 100755 --- a/www/inc/playerlib.php +++ b/www/inc/playerlib.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -1150,7 +1150,7 @@ function sdbquery($querystr, $dbh) { } function updMpdConf($i2sdevice) { - $mpdcfg = sdbquery("SELECT param,value FROM cfg_mpd WHERE value!=''", cfgdb_connect()); + $mpdcfg = sdbquery("SELECT param, value FROM cfg_mpd WHERE value!=''", cfgdb_connect()); $mpdver = substr($_SESSION['mpdver'], 0, 4); $data .= "#########################################\n"; @@ -1185,8 +1185,9 @@ function updMpdConf($i2sdevice) { case 'sox_multithreading': $sox_multithreading = $cfg['value']; break; - case 'replaygain_handler': - $replaygain_handler = $mpdver == '0.21' ? '' : $cfg['param'] . " \"" . $cfg['value'] . "\"\n"; + case 'replay_gain_handler': + //$replay_gain_handler = $mpdver == '0.21' ? '' : $cfg['param'] . " \"" . $cfg['value'] . "\"\n"; + $replay_gain_handler = $cfg['value']; break; case 'buffer_before_play': $data .= $mpdver == '0.21' ? '' : $cfg['param'] . " \"" . $cfg['value'] . "\"\n"; @@ -1205,10 +1206,11 @@ function updMpdConf($i2sdevice) { break; case 'period_time': $period_time = $cfg['value']; - break; + break; // default param handling default: $data .= $cfg['param'] . " \"" . $cfg['value'] . "\"\n"; + if ($cfg['param'] == 'replaygain') {$replaygain = $cfg['value'];} break; } } @@ -1232,12 +1234,13 @@ function updMpdConf($i2sdevice) { $data .= "}\n\n"; // alsa local outputs - $names = array( + $names = array ( "name \"ALSA default\"\n" . "device \"hw:" . $device . ",0\"\n", "name \"ALSA crossfeed\"\n" . "device \"crossfeed\"\n", "name \"ALSA parametric eq\"\n" . "device \"eqfa4p\"\n", "name \"ALSA graphic eq\"\n" . "device \"alsaequal\"\n", - "name \"ALSA polarity inversion\"\n" . "device \"invpolarity\"\n"); + "name \"ALSA polarity inversion\"\n" . "device \"invpolarity\"\n" + ); foreach ($names as $name) { $data .= "audio_output {\n"; $data .= "type \"alsa\"\n"; @@ -1245,12 +1248,14 @@ function updMpdConf($i2sdevice) { $data .= "mixer_type \"" . $mixertype . "\"\n"; $data .= $mixertype == 'hardware' ? "mixer_control \"" . $hwmixer . "\"\n" . "mixer_device \"hw:" . $device . "\"\n" . "mixer_index \"0\"\n" : ''; $data .= "dop \"" . $dop . "\"\n"; - $data .= $replaygain_handler; + /* DEPRECATE because when hardware volume is present and replay_gain_handler = 'mixer', 0dB ALSA volume is output when track starts playing. Instead use MPD internal default (software). + $data .= $replaygain != 'off' ? "replay_gain_handler \"" . $replay_gain_handler . "\"\n" : '';*/ + /* DEPRECATE because the explicit settings cause distortion on HDMI and On-board audio outputs. Instead use MPD internal defaults. $data .= "auto_resample \"" . $auto_resample . "\"\n"; $data .= "auto_channels \"" . $auto_channels . "\"\n"; $data .= "auto_format \"" . $auto_format . "\"\n"; $data .= "buffer_time \"" . $buffer_time . "\"\n"; - $data .= "period_time \"" . $period_time . "\"\n"; + $data .= "period_time \"" . $period_time . "\"\n";*/ $data .= "}\n\n"; } @@ -1260,12 +1265,14 @@ function updMpdConf($i2sdevice) { $data .= "name \"ALSA bluetooth\"\n"; $data .= "device \"btstream\"\n"; $data .= "mixer_type \"software\"\n"; - $data .= $replaygain_handler; + /* DEPRECATE + $data .= $replaygain != 'off' ? "replay_gain_handler \"software\"\n" : '';*/ + /* DEPRECATE $data .= "auto_resample \"" . $auto_resample . "\"\n"; $data .= "auto_channels \"" . $auto_channels . "\"\n"; $data .= "auto_format \"" . $auto_format . "\"\n"; $data .= "buffer_time \"" . $buffer_time . "\"\n"; - $data .= "period_time \"" . $period_time . "\"\n"; + $data .= "period_time \"" . $period_time . "\"\n";*/ $data .= "}\n\n"; // mpd httpd @@ -2032,17 +2039,18 @@ function getHdwrRev() { '0015' => 'Pi-1A+ 256/512MB', '0021' => 'Pi-1A+ 512MB v1.1', '0032' => 'Pi-1B+ 512MB v1.2', + '0092' => 'Pi-Zero 512MB v1.2', + '0093' => 'Pi-Zero 512MB v1.3', + '00c1' => 'Pi-Zero W 512MB v1.1', '1040' => 'Pi-2B 1GB v1.0', '1041' => 'Pi-2B 1GB v1.1', '1041' => 'Pi-2B 1GB v1.1', '2042' => 'Pi-2B 1GB v1.2', '2082' => 'Pi-3B 1GB v1.2', - '20d3' => 'Pi-3B+ 1GB v1.3', '20a0' => 'Pi-CM3 1GB v1.0', + '20d3' => 'Pi-3B+ 1GB v1.3', '20e0' => 'Pi-3A+ 512 MB v1.0', - '00c1' => 'Pi-Zero W 512MB v1.1', - '0092' => 'Pi-Zero 512MB v1.2', - '0093' => 'Pi-Zero 512MB v1.3' + '2100' => 'Pi-CM3+ 1GB' ); //$revnum = sysCmd('awk ' . "'" . '{if ($1=="Revision") print substr($3,length($3)-3)}' . "'" . ' /proc/cpuinfo'); @@ -2086,22 +2094,23 @@ function getHdwrRev() { new style revision codes 90 0021 A+ 1.1 512 MB Sony UK 90 0032 B+ 1.2 512 MB Sony UK -90 0092 Zero 1.2 512 MB Sony UK -90 0093 Zero 1.3 512 MB Sony UK +90 0092 Zero 1.2 512 MB Sony UK +90 0093 Zero 1.3 512 MB Sony UK 90 00c1 Zero W 1.1 512 MB Sony UK -92 0093 Zero 1.3 512 MB Embest -a0 1040 2B 1.0 1 GB Sony UK -a0 1041 2B 1.1 1 GB Sony UK -a0 2082 3B 1.2 1 GB Sony UK -a0 20d3 3B+ 1.3 1 GB Sony UK -a0 20a0 CM3 1.0 1 GB Sony UK -a2 1041 2B 1.1 1 GB Embest -a2 2042 2B 1.2 1 GB Embest (with BCM2837) -a2 2082 3B 1.2 1 GB Embest -a3 2082 3B 1.2 1 GB Sony Japan -a5 2082 3B 1.2 1 GB Stadium -a0 20d3 3B+ 1.3 1 GB Sony UK 90 20e0 3A+ 1.0 512 MB Sony UK +92 0093 Zero 1.3 512 MB Embest +a0 1040 2B 1.0 1 GB Sony UK +a0 1041 2B 1.1 1 GB Sony UK +a0 2082 3B 1.2 1 GB Sony UK +a0 20a0 CM3 1.0 1 GB Sony UK +a0 20d3 3B+ 1.3 1 GB Sony UK +a0 2100 CM3+ 1.0 1 GB Sony UK +a2 1041 2B 1.1 1 GB Embest +a2 2042 2B 1.2 1 GB Embest (with BCM2837) +a2 2082 3B 1.2 1 GB Embest +a2 20a0 CM3 1.0 1 GB Embest +a3 2082 3B 1.2 1 GB Sony Japan +a5 2082 3B 1.2 1 GB Stadium */ // config audio scrobbler diff --git a/www/js/notify.js b/www/js/notify.js index 17321a805..fd19e3c27 100755 --- a/www/js/notify.js +++ b/www/js/notify.js @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/js/playerlib.js b/www/js/playerlib.js index 545ad9584..6a360ab7d 100644 --- a/www/js/playerlib.js +++ b/www/js/playerlib.js @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -68,6 +68,7 @@ var UI = { radioPos: -1, libAlbum: '', mobile: false, + plModified: -1, tagViewCovers: true }; @@ -400,7 +401,7 @@ function engineCmd() { async: true, cache: false, success: function(data) { - console.log('engineCmd: success branch: data=(' + data + ')'); + //console.log('engineCmd: success branch: data=(' + data + ')'); cmd = JSON.parse(data).split(','); if (cmd[0] == 'btactive1' || cmd[0] == 'btactive0') { @@ -798,8 +799,14 @@ function renderUI() { refreshTimeKnob(); } - // update playlist - renderPlaylist(); + // for radio stations always update playlist + if (MPD.json['artist'] == 'Radio station') { + renderPlaylist(); + } + // for song files only update if MPD playlilst seq + else if (MPD.json['playlist'] != UI.plModified) { + renderPlaylist(); + } // ensure renderer overlays get applied in case mpd ui updates get there first after browser refresh // bluetooth renderer @@ -850,47 +857,49 @@ function genSearchUrl (artist, title, album) { function renderPlaylist() { debugLog('renderPlaylist'); + $.getJSON('command/moode.php?cmd=playlist', function(data) { var output = ''; + + //console.log(MPD.json['playlist'], UI.plModified) + UI.plModified = MPD.json['playlist']; // save for use in delete/move modals UI.dbEntry[4] = typeof(data.length) === 'undefined' ? 0 : data.length; // format playlist items - if (data) { - for (i = 0; i < data.length; i++) { - //console.log(data[i].file); + if (data) { + for (i = 0; i < data.length; i++) { + //console.log(data[i].file); - // item active state - if (i == parseInt(MPD.json['song'])) { - output += '
  • '; - } + // item active state + if (i == parseInt(MPD.json['song'])) { + output += '
  • '; + } else { - output += '
  • '; - } + output += '
  • '; + } // action menu - output += ''; + output += '
    ' + (typeof(data[i].Time) == 'undefined' ? '' : ' ' + formatSongTime(data[i].Time) + '') + '
    '; // itunes aac file if (typeof(data[i].Name) !== 'undefined' && data[i].file.substr(data[i].file.lastIndexOf('.') + 1).toLowerCase() == 'm4a') { - // line 1 title - output += '
    '; - output += data[i].Name + ''; + // line 1 title + output += '
    '; + output += data[i].Name + ''; // line 2 artist, album output += ' '; // for clock radio output += (typeof(data[i].Artist) === 'undefined') ? 'Unknown artist' : data[i].Artist; output += ' - '; - output += (typeof(data[i].Album) === 'undefined') ? 'Unknown album' : data[i].Album; - + output += (typeof(data[i].Album) === 'undefined') ? 'Unknown album' : data[i].Album; } // radio station else if (typeof(data[i].Name) !== 'undefined' || (data[i].file.substr(0, 4) == 'http' && typeof(data[i].Artist) === 'undefined')) { - // line 1 title - output += '
    '; - + // line 1 title + output += '
    '; + // use custom name for particular station - if (typeof(data[i].Title) === 'undefined' || data[i].Title.trim() == '' || data[i].file == 'http://stream.radioactive.fm:8000/ractive') { + if (typeof(data[i].Title) === 'undefined' || data[i].Title.trim() == '' || data[i].file == 'http://stream.radioactive.fm:8000/ractive') { output += 'Streaming source'; } else { @@ -928,8 +937,8 @@ function renderPlaylist() { } // song file or upnp url else { - // line 1 title - output += '
    '; + // line 1 title + output += '
    '; if (typeof(data[i].Title) === 'undefined') { // use file name var pos = data[i].file.lastIndexOf('.'); @@ -945,7 +954,7 @@ function renderPlaylist() { } // use title else { - output += data[i].Title + ''; + output += data[i].Title + ''; } // line 2 artist, album output += ' '; @@ -954,21 +963,13 @@ function renderPlaylist() { output += (typeof(data[i].Album) === 'undefined') ? 'Unknown album' : data[i].Album; } - output += '
  • '; + output += ''; } // end loop } - // adjustments for mobile - if (data.length < 3) { - $('#playlist').css('padding-bottom', '6em'); - } - else { - $('#playlist').css('padding-bottom', ''); - } - // render playlist - $('ul.playlist, ul.ss-playlist').html(output); - }); + $('ul.playlist, ul.ss-playlist').html(output); + }); } // MPD commands for database, playlist, radio stations, saved playlists @@ -1209,7 +1210,7 @@ function formatBrowseData(data, path, i, panel) { // song files if (typeof data[i].Title != 'undefined') { - output = '
  • ' + output = '
  • ' // click on item line for menu output += '
  • '; + output = '
  • '; output += ''; @@ -1284,7 +1285,7 @@ function formatBrowseData(data, path, i, panel) { // directories else { if (data[i].directory !== 'RADIO') { // exclude in Folder view - output = '
  • = 0 ? ' active' : '') + '">' + allGenres[i] + '
  • '; } @@ -1945,7 +1946,7 @@ var renderArtists = function() { for (var i = 0; i < allArtists.length; i++) { // add || allArtists.length = 1 to automatically highlight if only 1 artist in list - output += '
  • = 0 || allArtists.length == 1) ? ' active' : '') + '">' + allArtists[i] + '
  • '; } @@ -1981,18 +1982,18 @@ var renderAlbums = function() { } if (UI.tagViewCovers) { - output += '
  • ' + '' + '
    ' + allAlbums[i].album + '
    ' + '' + allAlbums[i].artist + '
  • '; - output2 += '
  • ' + '
    ' + allAlbumCovers[i].album + '
    ' + allAlbumCovers[i].artist + '
  • '; } else { - output += '
  • ' + allAlbums[i].album + '' + allAlbums[i].artist + '
  • '; - output2 += '
  • ' + '
    ' + allAlbumCovers[i].album + '
    ' + allAlbumCovers[i].artist + '
  • '; } @@ -2018,7 +2019,7 @@ var renderAlbums = function() { container: $('#lib-albumcover') }); } - else if ($('.tag-view-btn').hasClass('active')) { + else if ($('.tag-view-btn').hasClass('active') && UI.tagViewCovers) { $('img.lazy').lazyload({ container: $('#lib-album') }); @@ -2710,11 +2711,13 @@ $('#context-menu-lib-all a').click(function(e) { else if ($(this).data('cmd') == 'tracklist') { if ($('#bottom-row').css('display') == 'none') { $('#bottom-row').css('display', 'flex') + $('#tracklist-toggle').html(' Hide tracks'); $('#lib-albumcover').css('height', 'calc(50% - 2em)'); // was 1.75em $('#index-albumcovers').hide(); } else { $('#bottom-row').css('display', 'none') + $('#tracklist-toggle').html(' Show tracks'); $('#lib-albumcover').css('height', '100%'); $('#index-albumcovers').show(); } @@ -3725,7 +3728,7 @@ $(window).on('scroll', function(e) { if (UI.mobile) { $('#mobile-toolbar').css('display', 'none'); $('#container-playlist').css('visibility','visible'); - $('#menu-bottom').slideDown(100, 'easeOutQuad'); + $('#menu-bottom').show(); } $('#menu-top').css('height', $('#menu-top').css('line-height')); $('#menu-top').css('backdrop-filter', 'blur(20px)'); @@ -3746,51 +3749,21 @@ $(window).on('scroll', function(e) { } }); -/* for > IOS 9 only -function getCSSRule(ruleName) { - ruleName = ruleName.toLowerCase(); - var result = null; - var find = Array.prototype.find; - - find.call(document.styleSheets, styleSheet => { - result = find.call(styleSheet.cssRules, cssRule => { - return cssRule instanceof CSSStyleRule - && cssRule.selectorText.toLowerCase() == ruleName; - }); - return result != null; - }); - return result; -} -*/ - -// for all IOS +// get css rule object function getCSSRule(ruleName) { - ruleName = ruleName.toLowerCase(); - var styleSheet; - var i, ii; - var cssRule = false; - var cssRules; - - if (document.styleSheets) { - for (i = 0; i < document.styleSheets.length; i++) { - styleSheet = document.styleSheets[i]; - cssRules = styleSheet.cssRules; // Yes --Mozilla Style - if (cssRules) { - for (ii = 0; ii < cssRules.length; ii++) { - cssRule = cssRules[ii]; - if (cssRule) { - if (cssRule.selectorText) { - if (cssRule.selectorText.toLowerCase() == ruleName) { - return cssRule; - } - } - } + for (var i = 0; i < document.styleSheets.length; i++) { + var styleSheet = document.styleSheets[i]; + + if (styleSheet.href.indexOf('flat-ui.css') != -1 ) { + var cssRules = styleSheet.cssRules; + for (var j = 0; j < cssRules.length; j++) { + var cssRule = cssRules[j]; + if (cssRule.selectorText == ruleName) { + return cssRule; } } } } - - return false; // nothing found } // set theme colors @@ -3904,11 +3877,12 @@ function storeLibPos(pos) { // switch to library / playbar panel $("#coverart-url, #playback-switch").click(function(e){ currentView = currentView.split(',')[1]; - $('#menu-bottom, .viewswitch').css('display', 'flex'); + $('#menu-bottom').show(); + $('.viewswitch').css('display', 'flex'); $('#library-panel').addClass('active'); $('#playback-panel').removeClass('active'); $('#playback-switch').hide(); -$('html, body').animate({ scrollTop: 0 }, 100); + $('html, body').animate({ scrollTop: 0 }, 100); if (currentView == 'tag') { @@ -3918,15 +3892,19 @@ $('html, body').animate({ scrollTop: 0 }, 100); setColors(); $('#top-columns, #bottom-row').show(); var result = sendMoodeCmd('POST', 'updcfgsystem', {'current_view': currentView}, true); // async - setTimeout(function() { - $('img.lazy').lazyload({ - container: $('#lib-album') - }); - if (UI.libPos[0] >= 0) { - customScroll('albums', UI.libPos[0], 200); - $('#albumsList .lib-entry').eq(UI.libPos[0]).click(); - } - }, 250); + if (UI.tagViewCovers) { + setTimeout(function() { + if (UI.tagViewCovers) { + $('img.lazy').lazyload({ + container: $('#lib-album') + }); + } + if (UI.libPos[0] >= 0) { + customScroll('albums', UI.libPos[0], 200); + $('#albumsList .lib-entry').eq(UI.libPos[0]).click(); + } + }, 250); + } } else if (currentView == 'album') { $('.folder-view-btn, .tag-view-btn, .radio-view-btn').removeClass('active'); diff --git a/www/js/scripts-configs.js b/www/js/scripts-configs.js index 834da9da5..686ba6529 100644 --- a/www/js/scripts-configs.js +++ b/www/js/scripts-configs.js @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ jQuery(document).ready(function($){ 'use strict'; diff --git a/www/js/scripts-panels.js b/www/js/scripts-panels.js index 4ca63bcf9..a52c65349 100644 --- a/www/js/scripts-panels.js +++ b/www/js/scripts-panels.js @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -671,6 +671,31 @@ jQuery(document).ready(function($) { 'use strict'; customScroll('artists', UI.libPos[2], 200); }); + // click on artist or station name in playback + $('#currentalbum').click(function(e) { + // radio station + if (MPD.json['artist'] == 'Radio station') { + $('.database-radio li').each(function(index){ + if ($(this).text().search(RADIO.json[MPD.json['file']]['name']) != -1) { + UI.radioPos = index + 1; + } + }); + $('#playback-switch').click(); + if (!$('.radio-view-btn').hasClass('active')) { + $('.radio-view-btn').click(); + } + } + // song file + else { + $('#playback-switch').click(); + $('.tag-view-btn').click(); + setTimeout(function() { + $("#artistsList li .lib-entry:contains('" + MPD.json['artist'] + "')").click(); + customScroll('artists', UI.libPos[2], 200); + }, 300); + } + }); + // browse panel $('.database').on('click', '.db-browse', function(e) { if ($(this).hasClass('db-folder') || $(this).hasClass('db-savedplaylist')) { diff --git a/www/lib-config.php b/www/lib-config.php index e9d008a53..c433bcc1b 100755 --- a/www/lib-config.php +++ b/www/lib-config.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/lop-config.php b/www/lop-config.php index d1bdddb0d..39ace3d4c 100755 --- a/www/lop-config.php +++ b/www/lop-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/mpd-config.php b/www/mpd-config.php index c102ebbbf..5d2b2a761 100755 --- a/www/mpd-config.php +++ b/www/mpd-config.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -150,11 +150,11 @@ // replaygain preamp, r45b $_mpd_select['replaygain_preamp'] = $mpdconf['replaygain_preamp']; -// replaygain handler, r45d for 0.20 only -if ($_hide_020_params == '') { - $_mpd_select['replaygain_handler'] .= "\n"; - $_mpd_select['replaygain_handler'] .= "\n"; -} +/* DEPRECATE +// replaygain handler +$_mpd_select['replay_gain_handler'] .= "\n"; +$_mpd_select['replay_gain_handler'] .= "\n"; +*/ // volume normalization $_mpd_select['volume_normalization'] .= "\n"; @@ -171,6 +171,7 @@ $_mpd_select['buffer_before_play'] .= "\n"; } +/* DEPRECATE // hardware buffer time, r45b $_mpd_select['buffer_time'] .= "\n"; $_mpd_select['buffer_time'] .= "\n"; @@ -181,7 +182,7 @@ $_mpd_select['period_time'] .= "\n"; $_mpd_select['period_time'] .= "\n"; $_mpd_select['period_time'] .= "\n"; -$_mpd_select['period_time'] .= "\n"; +$_mpd_select['period_time'] .= "\n"; $_mpd_select['period_time'] .= "\n"; // ALSA auto-resample, r45b @@ -193,6 +194,7 @@ /// ALSA auto-format, r45b $_mpd_select['auto_format'] .= "\n"; $_mpd_select['auto_format'] .= "\n"; +*/ waitWorker(1, 'mpd-config'); diff --git a/www/net-config.php b/www/net-config.php index 6ace2789b..890b6f3ef 100755 --- a/www/net-config.php +++ b/www/net-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/quickhelp.html b/www/quickhelp.html index a9048aa92..fbdc399e9 100644 --- a/www/quickhelp.html +++ b/www/quickhelp.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -87,7 +87,10 @@

    Active Elements

    Tapping on the numeric volume level toggles the mute state. Tapping ahead on the volume ring advances the volume by 10. Tapping the (- +) buttons adjusts volume by 1 step.
  • Song title - Tapping the song title in full screen Playback launches a Google search in a separate Browser tab. On Smartphones it scrolls the Playlist to that item. + Tapping the song title underneath the cover art in Playback launches a Google search in a separate Browser tab. On Smartphones it scrolls the Playlist to that item. +
  • +
  • Artist - Album or Radio Station + Tapping Artist - Album or Radio station name underneath the cover art in Playback switches to Playbar in Tag or Radio view. In tag view the artist filter is applied. In radio view the list is scrolled to the station.
  • Swipe gestures On Smartphones swiping up scrolls the Playlist into view and tapping on the Playbar cover returns to Playback. In the Library tag view swiping sideways shows/hides the Genres column. diff --git a/www/relnotes.txt b/www/relnotes.txt index 94d17e96c..9c873943e 100755 --- a/www/relnotes.txt +++ b/www/relnotes.txt @@ -9,6 +9,40 @@ # ######################################################## +######################################################## +// +// 5.2 2019-05-07 +// +######################################################## + +New features + +- NEW: Artist/Station filter (see Quick help) + +Radio stations + +- UPD: KUVO HD2 + +Updates + +- UPD: Further performance improvements for page loading +- UPD: Performance improvement for Playlilst +- UPD: Bump to MPD 0.20.23 (Default) and 0.21.8 (Testing) +- UPD: Bump to shairport-sync-3.3.0-rc6-0c65236 +- UPD: Bump to Linux kernel 4.19.40 +- UPD: Revert MPD buffer time/period, ALSA auto-conv to internal defaults +- UPD: Deprecate MPD replay gain handler setting, issue with 'mixer' option +- UPD: Add hardware revision codes for CM3/3+ + +Bug fixes + +- FIX: Remove curve not working in Graphic and Parameteric EQ +- FIX: Input pattern missing from eq-p "Enter new curve name" +- FIX: Playlist on certain mobile devices not scrolling when < 5 items +- FIX: Firefox CORS error caused by getCSSRule() in playerlib +- FIX: Missing member var declarations in Zend application.php +- FIX: Radio station names with single quotes not being escaped + ######################################################## // // 5.1 2019-04-22 diff --git a/www/sel-config.php b/www/sel-config.php index 45203e3f1..852908661 100755 --- a/www/sel-config.php +++ b/www/sel-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/setup.txt b/www/setup.txt index f5628a11a..514bbb25d 100755 --- a/www/setup.txt +++ b/www/setup.txt @@ -6,7 +6,7 @@ # moOde audio player. Additional help is provided within # the player via the (i) information buttons. # -# Updated: 2019-MM-DD +# Updated: 2019-05-07 # # (C) Tim Curtis 2017 http://moodeaudio.org # diff --git a/www/snd-config.php b/www/snd-config.php index 49e7d6796..991c0a563 100755 --- a/www/snd-config.php +++ b/www/snd-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ @@ -409,8 +409,8 @@ // MPD // mpd version -$_select['mpdver'] .= "\n"; -$_select['mpdver'] .= "\n"; +$_select['mpdver'] .= "\n"; +$_select['mpdver'] .= "\n"; // auto-shuffle $_select['ashufflesvc1'] .= "\n"; diff --git a/www/spo-config.php b/www/spo-config.php index 29de1535e..329445129 100755 --- a/www/spo-config.php +++ b/www/spo-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/sqe-config.php b/www/sqe-config.php index 52c5dda20..8e28e389a 100755 --- a/www/sqe-config.php +++ b/www/sqe-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/sys-config.php b/www/sys-config.php index 42c35ee92..5934596da 100755 --- a/www/sys-config.php +++ b/www/sys-config.php @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ diff --git a/www/templates/apl-config.html b/www/templates/apl-config.html index 99973d733..db196d515 100644 --- a/www/templates/apl-config.html +++ b/www/templates/apl-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/blu-config.html b/www/templates/blu-config.html index 1d04f26aa..8cad0d5ca 100755 --- a/www/templates/blu-config.html +++ b/www/templates/blu-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/chp-config.html b/www/templates/chp-config.html index a77f58621..3a7361889 100644 --- a/www/templates/chp-config.html +++ b/www/templates/chp-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/eqg-config.html b/www/templates/eqg-config.html index ad52bde71..d0d684b04 100644 --- a/www/templates/eqg-config.html +++ b/www/templates/eqg-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -108,7 +108,7 @@

    Enter new curve name

    - +
    diff --git a/www/templates/eqp-config.html b/www/templates/eqp-config.html index aad4ffbef..46d9ea20b 100644 --- a/www/templates/eqp-config.html +++ b/www/templates/eqp-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -139,7 +139,7 @@

    Enter new curve name

    - +
    diff --git a/www/templates/gpio-config.html b/www/templates/gpio-config.html index a0ffb1132..27e386308 100644 --- a/www/templates/gpio-config.html +++ b/www/templates/gpio-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/indextpl.html b/www/templates/indextpl.html index 5d17e0493..54c29597c 100644 --- a/www/templates/indextpl.html +++ b/www/templates/indextpl.html @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -510,7 +510,7 @@
    Search specific tags
  • Add
  • Play
  • Clear/Play
  • -
  • Track list
  • +
  • Show tracks
  • Close
diff --git a/www/templates/lib-config.html b/www/templates/lib-config.html index 8bc0ef729..497f533a5 100644 --- a/www/templates/lib-config.html +++ b/www/templates/lib-config.html @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/lop-config.html b/www/templates/lop-config.html index 6aa2d4d16..93d6c7305 100644 --- a/www/templates/lop-config.html +++ b/www/templates/lop-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/mpd-config.html b/www/templates/mpd-config.html index e49744713..cb412a989 100644 --- a/www/templates/mpd-config.html +++ b/www/templates/mpd-config.html @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> @@ -159,18 +159,19 @@

MPD Config

-
+ +
@@ -181,7 +182,7 @@

MPD Config

Adjust the volume of songs as they play so that they sound as though they are of equal loudness.
- - NOTE: output bit depth will be converted to 16 bit. + NOTE: output bit depth will be converted to 16 bit.
@@ -198,7 +199,7 @@

MPD Config

-
+
- NOTE: MPD 0.21.6 is offered as an option for enthusiasts that want to test the newer 0.21.y series. Known issues in the context of moOde include (1) Failure to output to Bluetooth speaker and (2) Distortion on DSD playback in certain scenarios.
+ NOTE: MPD 0.21.y (Testing) is offered as an option for enthusiasts that want to test the newer series. Known issues in the context of moOde include (1) Failure to output to Bluetooth speaker and (2) Distortion on DSD playback in certain scenarios.
The MPD database will be regenerated after switching versions.
diff --git a/www/templates/spo-config.html b/www/templates/spo-config.html index 3a361cc38..9c4f00175 100644 --- a/www/templates/spo-config.html +++ b/www/templates/spo-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/sqe-config.html b/www/templates/sqe-config.html index 856e44d96..13c59dd42 100644 --- a/www/templates/sqe-config.html +++ b/www/templates/sqe-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/sys-config.html b/www/templates/sys-config.html index 039a7f195..460d6713a 100644 --- a/www/templates/sys-config.html +++ b/www/templates/sys-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/templates/upp-config.html b/www/templates/upp-config.html index f86f15fcb..7ed304ee9 100644 --- a/www/templates/upp-config.html +++ b/www/templates/upp-config.html @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */ --> diff --git a/www/upp-config.php b/www/upp-config.php index 8857fc603..6a4424fae 100755 --- a/www/upp-config.php +++ b/www/upp-config.php @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * 2019-04-12 TC moOde 5.0 + * 2019-05-07 TC moOde 5.2 * */