/[gnump3d]/gnump3d/lib/gnump3d/tagcache.pm
ViewVC logotype

Diff of /gnump3d/lib/gnump3d/tagcache.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1.1.1 by skx, Mon Jul 28 22:26:11 2003 UTC revision 1.2 by skx, Fri Oct 31 17:04:49 2003 UTC
# Line 368  sub _formatSingleFile ( ) Line 368  sub _formatSingleFile ( )
368              $key = 'TITLE';              $key = 'TITLE';
369          }          }
370    
371            #
372            # Allow the song length in seconds to be used
373            # this is used in the advanced playlists.
374            #
375            if ( $key eq "SECONDS" )
376            {
377                my $length = $TAGS{'LENGTH'} || "";
378                my $hours  = 0;
379                my $mins   = 0;
380                my $secs   = 0;
381    
382                if ( $length =~ /^([0-9]+):([0-9]+):([0-9]+)$/ )
383                {
384                    $hours = $1;
385                    $mins  = $2;
386                    $secs  = $3;
387                }
388                else
389                {
390                    if ( $length =~ /^([0-9]+):([0-9]+)$/ )
391                    {
392                        $hours= 0;
393                        $mins = $1;
394                        $secs = $2;
395                    }
396                }
397    
398                $length = ( $secs * 60 ) +
399                          ( $mins * 60 * 60 ) +
400                          ( $hours * 60 * 60 * 60 );
401    
402                $format = $pre . $length . $post;
403            }
404    
405          if (defined( $TAGS{$key} ) )          if (defined( $TAGS{$key} ) )
406          {          {
407              # Do the insertion.              # Do the insertion.

Legend:
Removed from v.1.1.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26