I tried this patch (after adding an AND to the additional SQL statement), and it works like a charm. IMHO, it would be great if this could be added to the CVS.

At 5:13 PM -0500 2/5/05, Chris Pinkham wrote:
> I am running the CVS version from Feb 2. I have the "Always use browse mode
 when changing channels in LiveTV" option turned on.

 If I use the remote's up/down arrows to switch channels, the OSD displays
 all channels in the database, even the ones that don't appear in the EPG
 because they are marked invisible. Is this intentional?

When the 'visible' flag was added, browse mode wasn't modified to honor the setting when browing channels. Changing browse mode to support the visible flag looks like it would be just 1 line of code in tv_rec.cpp in TVRec::DoGetNextChannel. I guess if it's not on the EPG then it probably shouldn't be visible in browse mode. If you want to test a fix, edit libs/libmythtv/tv_rec.cpp and search for TVRec::DoGetNextChannel. Find the following section in that method:

    QString wherepart = QString("cardinput.cardid = capturecard.cardid AND "
                                "capturecard.cardid = \"%1\" AND "
                                "capturecard.hostname = \"%2\" AND "
                                "cardinput.sourceid = channel.sourceid ")
                                .arg(cardid)
                                .arg(gContext->GetHostName());

Add a line below the "capturecard.hostname" line so it looks like this:

    QString wherepart = QString("cardinput.cardid = capturecard.cardid AND "
                                "capturecard.cardid = \"%1\" AND "
                                "capturecard.hostname = \"%2\" AND "
                                "channel.visible = 1 "

add AND to above

                                "cardinput.sourceid = channel.sourceid ")
                                .arg(cardid)
                                .arg(gContext->GetHostName());

That should cause the code to only look at visible channels when trying to
find the next channel above or below the current one.  I think that should
be all it needs to fix it for you.  If it does, I can get the fix in CVS.

-- Dan Wilga [EMAIL PROTECTED] Web Administrator http://www.mtholyoke.edu Mount Holyoke College Tel: 413-538-3027 South Hadley, MA 01075 "Who left the cake out in the rain?"
_______________________________________________
mythtv-dev mailing list
[email protected]
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev

Reply via email to