From 0dbace41fe33a9bc2460a58be1022f11b35f4b8c Mon Sep 17 00:00:00 2001 From: Karl 'vollmerk' Vollmer Date: Tue, 5 Aug 2008 01:46:01 +0000 Subject: added paging to the localplay playlist, fixed some preferences issues I introduced with the form register and caching --- lib/class/browse.class.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'lib/class/browse.class.php') diff --git a/lib/class/browse.class.php b/lib/class/browse.class.php index cd424ec1..cc72e4ca 100644 --- a/lib/class/browse.class.php +++ b/lib/class/browse.class.php @@ -196,6 +196,7 @@ class Browse { case 'album': case 'artist': case 'tag': + case 'playlist_localplay': case 'shoutbox': case 'live_stream': // Set it @@ -215,7 +216,6 @@ class Browse { // Rien a faire break; } // end type whitelist - } // set_type /** @@ -790,10 +790,10 @@ class Browse { * and requires the correct template based on the * type that we are currently browsing */ - public static function show_objects($object_ids='', $ajax=false) { + public static function show_objects($object_ids=false, $ajax=false) { $object_ids = $object_ids ? $object_ids : self::get_saved(); - + // Reset the total items self::$total_objects = count($object_ids); @@ -818,7 +818,7 @@ class Browse { Ajax::start_container('browse_content'); // Switch on the type of browsing we're doing - switch ($_SESSION['browse']['type']) { + switch (self::$type) { case 'song': show_box_top(_('Songs') . $match, $class); Song::build_cache($object_ids); @@ -857,6 +857,11 @@ class Browse { require_once Config::get('prefix') . '/templates/show_playlist_songs.inc.php'; show_box_bottom(); break; + case 'playlist_localplay': + show_box_top(_('Current Playlist')); + require_once Config::get('prefix') . '/templates/show_localplay_playlist.inc.php'; + show_box_bottom(); + break; case 'catalog': show_box_top(_('Catalogs'), $class); require_once Config::get('prefix') . '/templates/show_catalogs.inc.php'; -- cgit