[mythtv] Re: [patch]building a tree for video{tree|gallery}

Leo Weppelman leo at wau.mis.ah.nl
Fri Oct 1 01:43:57 EDT 2004


On Thu, Sep 30, 2004 at 04:14:36PM -0400, thor wrote:
> On Thursday 30 September 2004 02:59 pm, Leo Weppelman wrote:
> 
> > I haven't yet figured it out, but... Would it be an idea to drop the
> > updirs in the gallery mode and just use the quit-key (escape) to go
> > up one level?
> 
>  In the gallery code, you can ask the current level of the tree if it has
> a grandparent. If it does, you put in an "up level" icon.

Yes, I understand that. The problem is not so much the condition of when to
add an updir. The problem is how to get it displayed, while keeping the
tree clean of it ;-)

If the tree returned by the videoList class is to be re-used, the sub-clases
using it should not modify it...right?

Currently, I see the following options to attack this problem:
  1) Provide a method to add/remove updirs in the videoList class
  2) have the classes that need updirs insert/remove them themselves.
     What I mean is that when the gallery code enters a subdirectory that
     should have an updir-node it can add one to the tree. Removal should
     be done when leaving that level.
     I don't really like it much it sounds messy and error prone, but
     can be made to work ;-)
  3) Do not add an entry to the tree, but fake one on display time.
     I have been looking at this, but I got lost in a maze of twisty
     UI-passages...

So I was planning to investigate solution 1 today ;-)

Leo.


More information about the mythtv-dev mailing list