Bug 2242 - DISC number is not displayed
: DISC number is not displayed
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Web Interface
: 6.2.0
: PC Windows XP
: P2 normal (vote)
: ---
Assigned To: Robert Moser II
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-10-03 11:28 UTC by Philip Meyer
Modified: 2008-09-15 14:36 UTC (History)
0 users

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philip Meyer 2005-10-03 11:28:51 UTC
I have selected a display format of "DISC-TRACKNUM. TITLE".  The disc number 
is not displayed anywhere (neither when browsing albums, or in the currently 
playing list, neither in the web UI or squeezebox display.  I have tried 
changing the display format string to remove the -, but it doesn't seem to 
make any difference.

It would be nice if there was a way of specifying in the display format to 
optionally display the disc number only if there is a disc tag (ie. such that 
any literal characters are not displayed before the track number - in my case, 
I wouldn't want the - displayed if there is only one disk in the album set).

Also, when browsing down to song information, the disc number is not currently 
displayed.
Comment 1 Dan Sully 2005-10-03 11:34:15 UTC
Phil - just checked in subversion change 4519

You'll need to wipe & rescan.
Comment 2 Blackketter Dean 2005-10-03 11:40:17 UTC
Dan suggested I reopen this bug to fix the case where a DISCC is 1 (i.e. it's a tagged in a set of 1 discs.)  

In the case where DISC and DISCC are both 1, we should just suppress the disc number display 
altogether.
Comment 3 Blackketter Dean 2005-10-03 11:41:22 UTC
Dan also suggested I assign it to Moser.  Ok with that, Robert?
Comment 4 Philip Meyer 2005-10-03 11:45:33 UTC
That was quick!  6 minutes between raising the bug to entering fixed state.  
Does the change cover the display format and song info display?
Comment 5 Robert Moser II 2005-10-03 12:41:23 UTC
So what exactly did you want to do?  Suppress both DISC and DISCC when DISCC is
1?  Or just suppress DISC in that case, leaving DISCC to display a 1?

In any case, it isn't too hard to do this, we just need to change the entry in
%parsedFormats to match what we want.

For example:

$parsedFormats{'DISC'} 
    = sub {
            my $output = '';
            my $album = $_[0]->album();
            if ($album) {
                my ($disc, $discc) = $album->get(qw(disc discc));
                if ($discc && $discc > 1) {
                    $output = $disc;
                }
            }
            return (defined $output ? $output : '');
        };

Similarly for DISCC if so desired.
Comment 6 Blackketter Dean 2005-10-04 16:15:43 UTC
Supress both if DISCC is 1 and DISC is 1 (or undefined).
If DISCC is 1 and DISC is greater than one, then DISCC is bogus, so suppress just DISCC.

How's that sound?
Comment 7 Philip Meyer 2005-10-05 00:46:41 UTC
Sounds good to me.
Comment 8 Robert Moser II 2005-10-06 14:58:08 UTC
Fixed in change 4572.
Comment 9 Philip Meyer 2005-10-07 11:26:41 UTC
DISC number now seems to be displayed in Web UI and Squeezebox UI browse lists 
when DISC tag is present, otherwise not.  Also displays disk number in song 
info.  Great!

However, it seems to have broken the "Treat multi-disk sets as a single album" 
setting.  All of my multi-disk albums are now displayed as a separate album 
for each disk (with exactly the same name - ie doesn't add "disk n" or 
anything to each instance like "treat as multiple albums").
Comment 10 Robert Moser II 2005-10-07 11:37:40 UTC
That's a separate issue which Dan is currently working on.