[mythtv] Fwd: [PATCH] Add profile groups

Geoffrey Hausheer ou401cru02 at sneakemail.com
Sun Sep 14 21:55:25 EDT 2003

On Sun, 14 Sep 2003 18:28:38 -0700, "Bruce Markey bjm-at-lvcm.com
|mythtv/1.0-Allow|" <2obvhk58d70t at sneakemail.com> said:
> I think it might be helpful if the profile group name and the
> profile name appeared on the top line above each of the page.
> I got disorientated a few time and would like to see maybe:
>   Software Encoders - LiveTV: Image size
That is a good idea.  I'm not really sure how to implement it at the
moment, as the menus aren't hierarchical in that way, and I'm still not
very good at GUI changes, but I'll look into it.
> I'd like to see the default profile names "High-Resolution"
> and "Low-Resolution". However, I realize others may not
> treat Default as a medium res and may have other needs for
> extra parameters. Maybe "Custom1" and "Custom2" would be
> a better generic solution.
This is really up to Isaac.  He can name them as he wants.  The 'Default'
and 'Live TV' need to remain, but it is just a one line cange in
recordingprofiles.h and a searh-replace in cvs.sql
> In bad testing, I found that I could merrily create several
> groups with the same name. Editing their profiles caused 
> segfaults. I didn't look into why because the user shouldn't
> get there. There should probably be a check to be sure a new
> group name is unique. 
> I could create groups for hostnames that don't exist. It could
> check for a match in capturecard.hostname. This might be
> overkill. However, I'm guessing that "localhost" would be a
> bad choice with slave backends and shouldn't be allowed.
Yeah I know about both of these.  I'm not sure how to do the first (when
the profile gets saved, it is too late to do error checking).  I could
make sure that the default profile was unique, but I'm not sure what to
do if the user manually changes the name to be the same as another
profile.  I could make the SQL database enforce uniqueness on the name,
but in theory, the user might want the same name for multiple groups
(just selecting a different hostname for each.  This is just a GUI thing,
and my GUI-fu is still weak.  The second could be checked by
cross-refernecing the capture-card list hostnames, and instead of having
a lineEdit box, have a pull down selector box.  This would also save
error prone typing.  I can probably throw that together easily enough. 
This is probably a good idea, since a NULL hostname really makes no sense
(the default should always win in this case).  Thanks for bringing this
up, I'll try to put together a patch that addresses as many of the issues
as I know how.

> The "cvs.sql" is good enough for testing the patch. However,
> the existing things in the CVS cvs.sql need to be included
> at the bottom and it needs to be modified in some way so that
> it will only do the DROPs and CREATEs of the tables the first
> time it is run.
Ugh.  Not sure how to manage that.  Perhaps one of the SQL experts could
work some voodoo there.

> As you have mentioned before, there is no way to delete a group
> once it has been created. I can imagine that many people will
> create bogus groups out of confusion or curiosity. This isn't
> necessary for the first commit but may be good to have down
> the line.
I don't have a clue how to implement this in the GUI.  actually deleting
the profiles and profile groups is trivial  once someone show me how to
hook a command to the delete key.

> Good stuff, Geoff,
glad it works for you.


More information about the mythtv-dev mailing list