google-code-export / sagetv-addons

Automatically exported from code.google.com/p/sagetv-addons
1 stars 0 forks source link

Add methods to Task for optionally displaying task status in header #282

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Can you add methods to the Task class that can be used to determine if the 
Task's status should be shown in the STV header?

I'm thinking of something simple, maybe two methods:

setShowIcon(boolean)
isShowIcon()

The STV can then invoke these methods to determine which Tasks should or should 
not be displayed.

Original issue reported on code.google.com by tom.mira...@gmail.com on 15 Jan 2011 at 12:13

GoogleCodeExporter commented 9 years ago
Who's going to be calling setShowIcon()?  Will you just be getting a total and 
displaying that or something?  If so, might it make more sense to provide an 
aggregate function, say, in ServerClient that does all the aggregation 
calculations for you?  I guess I'm just not really sure what you're planning to 
display in the header and therefore not quite sure what these methods are going 
to be doing/providing.

Original comment by de...@battams.ca on 15 Jan 2011 at 3:51

GoogleCodeExporter commented 9 years ago
I envision it being called by the STVi, something like this:

- When the task is getting created one of the parameters the user can define is 
"Show Status in Header". This will use setShowIcon(boolean).
- When the header is displayed the STVi will scan all of the tasks (using 
isShowIcon(Task) and for those that the user selected "yes" the "dot" will be 
displayed in the main header.

So if I have three Tasks defined I can set it up so only the status of one of 
them appears in the header (because the other two I don't really care about 
seeing.)

Original comment by tom.mira...@gmail.com on 15 Jan 2011 at 12:15

GoogleCodeExporter commented 9 years ago
And the engine must then also call setShowIcon(false) when the task moves to 
complete or failed state?

Original comment by de...@battams.ca on 15 Jan 2011 at 1:42

GoogleCodeExporter commented 9 years ago
No, the STV will check the state.  There is really nothing for the engine to do 
at all.  All the work will be done by the STV, I just need a boolean flag that 
I can set and check for each Task.

Original comment by tom.mira...@gmail.com on 15 Jan 2011 at 2:04

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r1329.

Original comment by de...@battams.ca on 19 Jan 2011 at 8:30

GoogleCodeExporter commented 9 years ago
Fix verified.

Original comment by de...@battams.ca on 12 May 2011 at 1:36