[mythtv-commits] mythtv commit: r10376 - in branches/mythtv-atscsrcid by danielk

mythtv at cvs.mythtv.org mythtv at cvs.mythtv.org
Tue Jul 4 00:36:35 UTC 2006


      Author: danielk
        Date: 2006-07-04 00:36:33 +0000 (Tue, 04 Jul 2006)
New Revision: 10376
   Changeset: http://cvs.mythtv.org/trac/changeset/10376

Modified:

   branches/mythtv-atscsrcid/libs/libmythtv/channelbase.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/channelbase.h
   branches/mythtv-atscsrcid/libs/libmythtv/channelutil.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/channelutil.h
   branches/mythtv-atscsrcid/libs/libmythtv/dbcheck.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/guidegrid.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/previouslist.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/previouslist.h
   branches/mythtv-atscsrcid/libs/libmythtv/proglist.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/programinfo.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/tv_rec.cpp
   branches/mythtv-atscsrcid/libs/libmythtv/videosource.cpp
   branches/mythtv-atscsrcid/programs/mythbackend/mainserver.cpp
   branches/mythtv-atscsrcid/programs/mythfrontend/globalsettings.cpp
   branches/mythtv-atscsrcid/programs/mythfrontend/manualschedule.cpp

Log:

Refs #1966. Changes channel sorting to be a bit smarter.

Instead of sorting on the fly using the database ChannelUtil::GetNextChannel(), this adds two methods GetChannels() and SortChannels() to create a sorted list of channels, and changes GetNextChannel() to take this sorted list.

This means we don't need a DB query for this and it means that we can use more sophisticated sorting methods. The reason I wrote this was because the atscsrcid removal removes the only reasonable DB sort method for channels. This repurposes "channum" sorting to be the new smart channum sorting which first compares major channels then minor channels, then compares the channum's numerically if possible, and then compares the channum's as strings, and finally if this fails compares the callsigns. If any of these differ the channels will be ordered uniquely and in a sensical manner. This new channum order supercedes all the ordering methods except callsign ordering which remains the same.

This works well for me, but I need some people in other countries to test this; I have a valid atscsrcid, for both ATSC and NTSC sources, I'm not sure if that is the case for everyone.

There are also a couple cases I would like someone familiar with the scheduling and schedule viewing to look at. In ProgramList::FromProgram() the ordering was by whatever channel ordering was set to, I changed this to chanid. Does this need to be ordered exactly like the channels are? Also In ProgramList::FromRecorded() I used a better approximation to the new smart ordering that the database can handle, same question here, is this approximation sufficient? The first is probably more important since I can't sort them exactly the same way without expanding the "LIMIT 1000".






More information about the mythtv-commits mailing list