[mythtv] Bruce, a question for you about schedules

David Engel david at istwok.net
Fri Jun 22 15:48:00 UTC 2007

On Thu, Jun 21, 2007 at 08:53:23PM -0500, Kevin Kuphal wrote:
> have a pointer.  I've been considering the idea of adding a simple feature
> to Myth where, if you have an upcoming showing of a progam recorded by a
> power search (such as I do for Premier episodes of shows), that you could,
> when selecting the upcoming episode, be given another option (along with
> don't/never record, edit options, override) that would allow you to set up a
> separate title/program specific rule as if the showing was not already being
> recorded.  As it stands now, I have to wait or remember to look for the show

Good idea.  Something like this has occurred to me in the past, but
I've never taken the time to flesh it out.  As Bruce already noted,
this could be useful for non-search rules too.  About the only rule
type it doesn't make any sense on are manual recording rules.  Single
and override rules are debatable.

To check for a manual recording rule, you'll need to load the
PI::record member if needed.  This can be done directly or indirectly
by calling PI::GetProgramRecordingStatus().  Then, check
record->getSearchType() for kManualSearch.

> What I'm looking for pointers on is what to query in the database or what
> condition to key off to know when to present that button.  I only want it to
> show on non-title/program specific rules such as power searches and then let
> me present the standard dialog window for creating a new title/program
> specific rule.  If you have some advice, I'd greatly appreciate it.

Bruce already pointed you toweard the dialog in programinfo.cpp.  To
actually create a new rule, look at SR:;loadByProgram().  You'll
probably want to modify this to take an extra, optional parameter
(defaults to off) which always creates a new rule by bypassing the
call to loadByID().

David Engel
david at istwok.net

More information about the mythtv-dev mailing list