[mythtv] [PATCH/APP] Program rankings

Chris Pinkham cpinkham at bc2va.org
Sat Jun 28 17:42:13 EDT 2003


> Here's a patch plus a tarball of additional files needed to
> use ranking to do conflict resolution.  It can be set to run
> before or after the existing conflict resolution or not at

Haven't had a chance to take a look at this other than reading
through your patch and looking at the screenshots, but figured
I'd throw in my $0.02 anyway.

Looks good.  I think you might want to give Weekslot
recordinds the same ranking as Timeslot though.  Right now
a weekslot recording doesn't get any ranking even though
it's technically more specific than a timeslot.

You also probably should allow changing of a program's rank
by going into the Advanced Recording Options screen rather
than hiding the SRRank setting. Look at how the recording type
and profile can be changed in that file.  Around like 497
in the original source, you'll find a couple lines like this:

    vbox->addWidget(type->configWidget(this, dialog));
    vbox->addWidget(profile->configWidget(this, dialog));

Those display the config widget for the type and profile on the
advanced recording dialog.  You should be able to add yours
by doing:

    vbox->addWidget(rank->configWidget(this, dialog));

You might look at the SRProfileSelector and SRRecordingType for more
info and use something like this instead of what you have for the
rank class:

class SRRank: public SpinBoxSetting, public SRSetting {
public:
    SRRank(const ScheduledRecording& parent):
       SpinBoxSetting(-1000, 1000, 1),
       SRSetting(parent, "rank") {
       setLabel(QObject::tr("Program ranking for recording conflicts"));
       setValue(0);
    };
};

Glad you put in negative ranks also.

Chris



More information about the mythtv-dev mailing list