mp3.c
branchtrunk
changeset 34 afc13760179b
parent 30 f8a59739816b
equal deleted inserted replaced
33:65ed49cbc08b 34:afc13760179b
   561             cString buff=cString::sprintf("%d.\t%s",num,*TitleArtist(pi.Title,pi.Artist));
   561             cString buff=cString::sprintf("%d.\t%s",num,*TitleArtist(pi.Title,pi.Artist));
   562             int fg=clrWhite, bg=clrGray50;
   562             int fg=clrWhite, bg=clrGray50;
   563             int hash=MakeHash(buff);
   563             int hash=MakeHash(buff);
   564             if(num==mode->Num) { fg=clrBlack; bg=clrCyan; hash=(hash^77) + 23; }
   564             if(num==mode->Num) { fg=clrBlack; bg=clrCyan; hash=(hash^77) + 23; }
   565             if(all || hash!=hashlist[i]) {
   565             if(all || hash!=hashlist[i]) {
   566               char *s=rindex(buff,'\t');
   566               const char *s=rindex(buff,'\t');
   567               if(s) {
   567               if(s) {
   568                 *s++=0;
   568                 Write(5,i,bwc-5,s,fg,bg);
       
   569                 buff.Truncate(s-buff);
   569                 Write(0,i,5,buff,fg,bg);
   570                 Write(0,i,5,buff,fg,bg);
   570                 Write(5,i,bwc-5,s,fg,bg);
       
   571                 }
   571                 }
   572               else
   572               else
   573                 Write(0,i,bwc,buff,fg,bg);
   573                 Write(0,i,bwc,buff,fg,bg);
   574               flush=true;
   574               flush=true;
   575               hashlist[i]=hash;
   575               hashlist[i]=hash;