diff options
-rw-r--r-- | albums.php | 3 | ||||
-rwxr-xr-x | docs/CHANGELOG | 3 | ||||
-rw-r--r-- | lib/class/album.class.php | 5 | ||||
-rw-r--r-- | lib/class/catalog.class.php | 4 | ||||
-rwxr-xr-x | lib/class/vainfo.class.php | 7 | ||||
-rw-r--r-- | lib/general.lib.php | 2 | ||||
-rw-r--r-- | play/index.php | 8 |
7 files changed, 23 insertions, 9 deletions
@@ -165,12 +165,13 @@ switch ($_REQUEST['action']) { Catalog::update_single_item('album',$_REQUEST['album_id']); - echo "<br /><b>" . _('Update From Tags Complete') . "</b> "; + echo "<br /><strong>" . _('Update From Tags Complete') . "</strong> "; echo "<a href=\"" . Config::get('web_path') . "/albums.php?action=show&album=" . scrub_out($_REQUEST['album_id']) . "\">[" . _('Return') . "]</a>"; show_box_bottom(); break; // Browse by Album case 'broken': + exit; switch($match) { case 'Show_all': $offset_limit = 99999; diff --git a/docs/CHANGELOG b/docs/CHANGELOG index d93f56b1..8b1236ad 100755 --- a/docs/CHANGELOG +++ b/docs/CHANGELOG @@ -4,6 +4,9 @@ -------------------------------------------------------------------------- v.3.4-Alpha2 + - Fixed Album Disk support for OGG's and added display to browse + albums + - Added Album Disk support for id3v2 (Thx Hugo Haas) - Updated LastFM pluging, must uninstall/reinstall to make it work will add in auto-update later - Adjusted LastFM reporting to reduce lag betwen songs. You must diff --git a/lib/class/album.class.php b/lib/class/album.class.php index cb767b15..dc42aa2d 100644 --- a/lib/class/album.class.php +++ b/lib/class/album.class.php @@ -225,6 +225,11 @@ class Album { $this->year = "N/A"; } + // If we've got a disk append it + if ($this->disk) { + $this->f_name_link .= ' [' . _('Disk') . ' ' . $this->disk . ']'; + } + } // format /** diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php index b9e5aefd..536be20f 100644 --- a/lib/class/catalog.class.php +++ b/lib/class/catalog.class.php @@ -953,7 +953,7 @@ class Catalog { $artist = $results['artist']; $album = $results['album']; $genre = $results['genre']; - $disk = $results['pos']; + $disk = $results['disk']; /* Clean up Old Vars */ unset($vainfo,$key); @@ -1893,7 +1893,7 @@ class Catalog { $size = $results['size']; $song_time = $results['time']; $track = $results['track']; - $disk = $results['pos']; + $disk = $results['disk']; $year = $results['year']; $comment = $results['comment']; $current_time = time(); diff --git a/lib/class/vainfo.class.php b/lib/class/vainfo.class.php index bc1c27b6..517d4c30 100755 --- a/lib/class/vainfo.class.php +++ b/lib/class/vainfo.class.php @@ -303,12 +303,15 @@ class vainfo { /* go through them all! */ foreach ($tags as $tag=>$data) { - + /* We need to translate a few of these tags */ switch ($tag) { case 'tracknumber': $array['track'] = $this->_clean_tag($data['0']); break; + case 'discnumber': + $array['disk'] = $this->_clean_tag($data['0']); + break; case 'date': $array['year'] = $this->_clean_tag($data['0']); break; @@ -366,7 +369,7 @@ class vainfo { switch ($tag) { case 'pos': $el = split('/', $data['0']); - $array['pos'] = $el[0]; + $array['disk'] = $el[0]; break; case 'track_number': $array['track'] = $this->_clean_tag($data['0'],$this->_file_encoding); diff --git a/lib/general.lib.php b/lib/general.lib.php index 8a1f2eea..b83942ec 100644 --- a/lib/general.lib.php +++ b/lib/general.lib.php @@ -233,7 +233,7 @@ function clean_tag_info($results,$key,$filename) { $info['title'] = stripslashes(trim($results[$key]['title'])); $info['year'] = intval($results[$key]['year']); $info['track'] = intval($results[$key]['track']); - $info['pos'] = intval($results[$key]['pos']); + $info['disk'] = intval($results[$key]['disk']); $info['comment'] = Dba::escape(str_replace($clean_array,$wipe_array,$results[$key]['comment'])); /* This are pulled from the info array */ diff --git a/play/index.php b/play/index.php index 10ab8208..15e06041 100644 --- a/play/index.php +++ b/play/index.php @@ -315,14 +315,16 @@ if ($bytesStreamed > $minBytesStreamed) { if ($tmp_playlist->type == 'vote') { $tmp_playlist->delete_track($song_id); } - } + } // if tmp_playlist + + /* Set the Song as Played if it isn't already */ + $song->set_played(); + } // if enough bytes are streamed else { debug_event('stream',$bytesStreamed .' of ' . $song->size . ' streamed, less than ' . $minBytesStreamed . ' not collecting stats','5'); } -/* Set the Song as Played if it isn't already */ -$song->set_played(); /* Clean up any open ends */ if ($GLOBALS['user']->prefs['play_type'] == 'downsample' || !$song->native_stream()) { |