mythtv/programs/mythfrontend/playbackbox.cpp
John Poet's patch to allow sorting of episodes by programid
instead of recording date.

John, sorry I didn't look at this before it went in but in playing with it now, I've found a significant bug. After playing a file then exiting playback, it does not find it's matching item in the list and the selection highlight seems to always fall to the last item on the list.

I think what needs to be addressed is in the section starting
around line 1234:

   // Try to find our old place in the title list.  Scan the new
   // titles backwards until we find where we were or go past.  This
   // is somewhat inefficient, but it works.

   QString oldsTitle = oldtitle;
   oldsTitle.remove(prefixes);
   titleIndex = titleList.count() - 1;
   for (int i = titleIndex; i >= 0; i--)
   {

       sTitle = titleList[i];
       sTitle.remove(prefixes);

       if (oldsTitle > sTitle)
           break;

       titleIndex = i;

       if (oldsTitle == sTitle)
           break;
   }

This loop is geared to match a list sorted by title but you need
some sort of "if (episodeSort == "Id")" variation that loops
over programid. This means that you'll probably need some sort
of programidList also.

--  bjm
_______________________________________________
mythtv-dev mailing list
[email protected]
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev

Reply via email to