From: Jos v.d.V. <jo...@us...> - 2006-03-19 21:41:44
|
Update of /cvsroot/win32forth/win32forth/apps/Player4 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23691/apps/Player4 Modified Files: Catalog.f Mediatree.f Log Message: Jos: Solved the problem with unstructered disks. ( Bug reported by Dirk ) Index: Mediatree.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/Player4/Mediatree.f,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** Mediatree.f 12 Mar 2006 17:00:39 -0000 1.26 --- Mediatree.f 19 Mar 2006 21:41:37 -0000 1.27 *************** *** 93,97 **** dup to hPrev ; - struct{ \ PrevMusic DWORD PrevMusicRecord --- 93,96 ---- *************** *** 125,138 **** ; : AddArtist { PrevRecAdr } ( rec-addr PrevRecAdr - ) dup CountedArtist 1 max PrevRecAdr @ CountedArtist 1 max compareia 0<> if dup PrevRecAdr ! true to OtherArtist? NotPlayable dup RecordDef Artist hPrev 2 pick RecordDef Request- c@ ! if rot drop hRequests ! else rot CountedFilename music? ! if hMusic ! else hMovies ! then then 1 AddItemHierarical PrevRecAdr hArtist ! --- 124,142 ---- ; + : hMusic/hMovie ( rec-adr - hMusic|hMovie ) + CountedFilename music? + if hMusic + else hMovies + then + ; + : AddArtist { PrevRecAdr } ( rec-addr PrevRecAdr - ) dup CountedArtist 1 max PrevRecAdr @ CountedArtist 1 max compareia 0<> + over RecordDef Cnt_Artist c@ 0> and if dup PrevRecAdr ! true to OtherArtist? NotPlayable dup RecordDef Artist hPrev 2 pick RecordDef Request- c@ ! if rot drop hRequests ! else rot hMusic/hMovie then 1 AddItemHierarical PrevRecAdr hArtist ! *************** *** 143,146 **** --- 147,151 ---- : AddAlbum { PrevRecAdr } ( rec-addr PrevRecAdr - ) dup CountedAlbum 1 max PrevRecAdr @ CountedAlbum 1 max compareia 0<> OtherArtist? or + over RecordDef Cnt_Artist c@ 0> and if dup PrevRecAdr ! NotPlayable RecordDef Album hPrev PrevRecAdr hArtist @ *************** *** 150,157 **** ; ! : AddTitle ( rec-addr PrevRecAdr - ) ! >r ! RecordDef CountedTitle +InlineRecord InlineRecord +null ! InlineRecord 1+ hPrev r> hAlbum @ 0 AddItemHierarical drop ; --- 155,165 ---- ; ! : AddTitle { rec-addr PrevRecAdr } ( rec-addr PrevRecAdr - ) ! rec-addr RecordDef CountedTitle +InlineRecord InlineRecord +null ! InlineRecord 1+ hPrev PrevRecAdr ! rec-addr RecordDef Cnt_Artist c@ 0> ! if hAlbum @ ! else drop rec-addr hMusic/hMovie ! then 0 AddItemHierarical drop ; Index: Catalog.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/Player4/Catalog.f,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** Catalog.f 12 Mar 2006 17:00:38 -0000 1.27 --- Catalog.f 19 Mar 2006 21:41:37 -0000 1.28 *************** *** 515,525 **** drop ! >r 1- dup r> ascii \ -scan >r 2dup - >r 1+ ! r@ struct, InlineRecord RecordDef Cnt_Album c! ! struct, InlineRecord RecordDef Album r@ cmove ! r> - 1- dup r> ascii \ -scan drop 2dup - swap 1+ over ! struct, InlineRecord RecordDef Cnt_Artist c! ! struct, InlineRecord RecordDef Artist rot cmove drop --- 515,530 ---- drop ! >r 1- dup r> ascii \ -scan >r 2dup - r@ swap >r 0> ! if 1+ r@ struct, InlineRecord RecordDef Cnt_Album c! ! struct, InlineRecord RecordDef Album r@ cmove ! else struct, InlineRecord RecordDef Cnt_Album c! ! then \ 4 ! r> - 1- dup r> ascii \ -scan 0> ! if 2dup - swap 1+ over ! struct, InlineRecord RecordDef Cnt_Artist c! ! struct, InlineRecord RecordDef Artist rot cmove ! else 0 struct, InlineRecord RecordDef Cnt_Artist c! drop ! then drop |