"mediafile/airings" options dialog

22 views
Skip to first unread message

Brian Schneider

unread,
Aug 21, 2011, 12:31:01 PM8/21/11
to sagetv-b...@googlegroups.com
I just checked in some changes to support the new mediafile_airings_options_dialog.xml dialog I added.

I could use some help though as I don't have much free time today.  Take a look at the structure I put in place, but the basic jist is that the calling window for the dialog (e.g. either the EPG, or Airings window, or Recordings window) passes in a set of parameters (using a global parameters variable) and then adjusts what to display/hide on the dialog.  The intent is to have one central dialog that can be used for both recordings that exist plus upcoming recordings (which the options need to be slightly different for).

Then the rest of the functionality needs to be tested/merged/etc.  Make sense?

I've been fighting with line 55 in mediafile_airings_options_dialog.xml where I try to change the label of a button... for some reason I'm getting a runtime exception but just don't have a chance to debug it.

Thoughts?  Can Tom or David run with this the rest of today?  I'm not going to have much time to play with it.

Tom Miranda

unread,
Aug 21, 2011, 12:39:10 PM8/21/11
to sagetv-b...@googlegroups.com
I think David is busy with the Recordings Options so I'll have a look at this.

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/AbnmbkPs3TMJ.
To post to this group, send email to sagetv-b...@googlegroups.com.
To unsubscribe from this group, send email to sagetv-boxee-d...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/sagetv-boxee-dev?hl=en.

Michael Reid

unread,
Aug 21, 2011, 12:41:18 PM8/21/11
to sagetv-b...@googlegroups.com
Anyone that can help with favorites lemme know.  My time over the next three weeks as I pointed out is limited and I really want to get this pig done.  I feel like some of the other ui elements are waiting on these screens.

~Mike

Tom Miranda

unread,
Aug 21, 2011, 12:59:20 PM8/21/11
to sagetv-b...@googlegroups.com
Just make sure you check your latest into svn.

David Hamann

unread,
Aug 21, 2011, 1:01:57 PM8/21/11
to sagetv-b...@googlegroups.com
actually, I've given up on my version of the record options, and will be trying to use Brian's.  I'll have some time to look at this tonight.  I just have to get the epg to work on my system first.

Brian Schneider

unread,
Aug 21, 2011, 1:43:08 PM8/21/11
to sagetv-b...@googlegroups.com
OK... a huge thunderstorm just rolled into my area so my outdoor plans have been scrapped.

Tom - I will keep working on this and try to clean some things up so that it's semi usable.  Do you want to work on the filtering/sorting/grouping that I saw you started to check in to r136?

I'll let you know once I get this new generic dialog in a usable state.

Tom Miranda

unread,
Aug 21, 2011, 1:50:39 PM8/21/11
to sagetv-b...@googlegroups.com
Too late, I'm already working on it.  I changed it so it no longer uses window parameters, that just keeps blowing up my Boxee Box.  I went with your global var method instead.  If you want I'll checkin what I have and you can continue to work on it.

Please advise...

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/xjAaXtlV0n4J.

Brian Schneider

unread,
Aug 21, 2011, 2:12:31 PM8/21/11
to sagetv-b...@googlegroups.com
Tom - sounds good... you can keep working... I'm thinking through what common functions we need but go ahead until you need a break.

Tom Miranda

unread,
Aug 21, 2011, 2:15:19 PM8/21/11
to sagetv-b...@googlegroups.com
The "Record Options" still needs to be done.  David is taking a break on that so maybe you can look into that?  You could also look at the bug list and see if you want to take on any of that.  Lots of things to do really :)

On Sun, Aug 21, 2011 at 2:12 PM, Brian Schneider <lehi...@gmail.com> wrote:
Tom - sounds good... you can keep working... I'm thinking through what common functions we need but go ahead until you need a break.

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/JtaPq0enVogJ.

Brian Schneider

unread,
Aug 21, 2011, 2:28:16 PM8/21/11
to sagetv-b...@googlegroups.com
I'll work on "Record Options" (which will be a new/small .xml which the new generic mediafile_airings_options_dialog can call).

Tom Miranda

unread,
Aug 21, 2011, 3:02:29 PM8/21/11
to sagetv-b...@googlegroups.com
Great.  I'll continue to work on the airing/mediafile options dialog.

Any idea how to pass a ListItem between windows?

On Sun, Aug 21, 2011 at 2:28 PM, Brian Schneider <lehi...@gmail.com> wrote:
I'll work on "Record Options" (which will be a new/small .xml which the new generic mediafile_airings_options_dialog can call).

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/NT7fDlU_-pIJ.

Tom Miranda

unread,
Aug 21, 2011, 3:14:55 PM8/21/11
to sagetv-b...@googlegroups.com
Found an easy way - Just pass the windowID and listID then use mc.GetFocusedItem().  Assuming of course it's focused!

Brian Schneider

unread,
Aug 21, 2011, 7:37:55 PM8/21/11
to sagetv-b...@googlegroups.com
Tom - when do you think you'll be committing your updates to the new options dialog?  I've made some nice progress on the recording options dialog and would like to integrate that in after your changes are committed.  I'll keep working on it until then.

Tom Miranda

unread,
Aug 21, 2011, 8:04:11 PM8/21/11
to sagetv-b...@googlegroups.com
Just committed a version.  It's not done but it's progressing.  I changed the way parameters are passed to the dialog so you'll need to take a look at that.  I recommend we stay consistent in passing parameters.

From my experience launching Windows with params crashes my box so we need to stay away from that.  I'm just passing a dictionary with some pre-defined data in it.  To pass a ListItem I'm just passing the windowID and controlID and then getting the item directly from the control.  In all cases the item in focus will be the one we are interested in.

I'm not going to do much more tonight, but I'll monitor my email up to about 10:00 PM (Eastern US).

On Sun, Aug 21, 2011 at 7:37 PM, Brian Schneider <lehi...@gmail.com> wrote:
Tom - when do you think you'll be committing your updates to the new options dialog?  I've made some nice progress on the recording options dialog and would like to integrate that in after your changes are committed.  I'll keep working on it until then.

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/SMCIycPQJYoJ.

Brian Schneider

unread,
Aug 21, 2011, 8:44:14 PM8/21/11
to sagetv-b...@googlegroups.com
Great... I'll do a quick merge in now with your r138 so the record options button goes to my new .xmls.

Tom Miranda

unread,
Aug 21, 2011, 9:10:58 PM8/21/11
to sagetv-b...@googlegroups.com
The MediaFile/Airing dialog has a long way to go.....

On Sun, Aug 21, 2011 at 8:44 PM, Brian Schneider <lehi...@gmail.com> wrote:
Great... I'll do a quick merge in now with your r138 so the record options button goes to my new .xmls.

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/eIm8plkFcAoJ.

Brian Schneider

unread,
Aug 21, 2011, 9:32:22 PM8/21/11
to sagetv-b...@googlegroups.com
Agree, but you've done a nice job running with this.  I just checked in r140 with the initial shell of the Record Options which is now called from the mediafile/airings dialog.

I'm going to work a little longer to see if I can get the end time adjustment to work (left/right arrows to add/subtract a minute do work so have fun with that for now)

Brian Schneider

unread,
Aug 21, 2011, 10:12:26 PM8/21/11
to sagetv-b...@googlegroups.com
OK I'm done for the night.  Just checked in r141 and have the end time adjustment nearly working.

I'm having some issues with my call to the Sage API SetRecordingTimes*(.  I pass in the airing (item) plus two long numbers, one start time, one end time, but I keep getting a Sage API exception below... does this have something to do with how long numbers are passed to Sage?

22:08:10 T:8348 M:901787648   DEBUG: sagex API call "SetRecordingTimes" [args: (<mc.ListItem; proxy of <Swig Object of type 'XAPP::ListItem *' at 0xa3992a8> >, 1313978400000L, 1313982660000L)] FAILED!
22:08:10 T:8348 M:901787648   DEBUG: sagex API error response:
                                            MSG: None
                                            ERROR: Unknown Object Type: sage.e$f for Sage Object: sage.e$f@1d69b44
22:08:10 T:8348 M:901722112   DEBUG: sagex API exception:
                                            java.lang.Exception: Unknown Object Type: sage.e$f for Sage Object: sage.e$f@1d69b44

                                            at sagex.remote.builder.SimpleJSONBuilder.handleError(SimpleJSONBuilder.java:68)

Derek Battams

unread,
Aug 21, 2011, 11:05:47 PM8/21/11
to sagetv-b...@googlegroups.com
This falls under the same category as the Record() API call.  The call returns an obfuscated Sage object on success, which can't be transmitted via the remote APIs.  You should notice that the API call is actually working even though it's throwing an exception.  For now, the work around is to simply catch the exception and ignore it.  Sean will be providing a fix in the remote APIs that will suppress the exception by simply returning a (useless) string value when these API calls [Record(), SetRecordingTimes(), possibly others] are used.  To tell which ones are affected by this issue, look at the Sage API docs and any API call that returns a java.lang.Object will fall into this category.

Side note, if you're actually passing the long vars with the 'L' notation appended then don't, just pass the arg as a regular python number.  If you're constructing the call and using EvaluateExpression() as the Sage API call then to pass a long use java_lang_Long_parseLong("123456789"):

# Assuming airing is a python var holding a Boxee ListItem wrapped Sage Airing object
sageAPI.EvaluateExpression('SetRecordingTimes(GetAiringForID(%s), java_lang_Long_parseLong("1234567788"), java_lang_Long_parseLong("1234567678")') % airing.GetProperty('AiringID')

If you're making a direct API call (recommended, where possible) then:

sageAPI.SetRecordingTimes(airing, 1234567788, 1234567678) # Much cleaner :)

  - Derek

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/3x9wB1WkipwJ.

Brian Schneider

unread,
Aug 22, 2011, 6:08:04 AM8/22/11
to sagetv-b...@googlegroups.com
Thanks Derek.  FYI... I do use the direct call below where I pass in two long variables... but it still appends the L onto the end... can you check the sage.py to see if there's a way that you need to handle it there?

sageAPI.SetRecordingTimes(airing, 1234567788, 1234567678)

e.g. see line 122 in the file below:


Derek Battams

unread,
Aug 22, 2011, 8:37:27 AM8/22/11
to sagetv-b...@googlegroups.com
Ok, the way you're calling it is fine.

  - Derek



--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/YzVgeN2G_pUJ.

Brian Schneider

unread,
Aug 22, 2011, 8:57:21 AM8/22/11
to sagetv-b...@googlegroups.com
Super... I'll just add in the exception handling tonight or tomorrow and we should be set.

Tom Miranda

unread,
Aug 22, 2011, 8:33:11 PM8/22/11
to sagetv-b...@googlegroups.com
I just committed version 142 which has a lot of improvements in the episode dialog.  Most things should be working except when you change any of the airing status items in the EPG the grid is not updated.  (The changes actually happen in the database, but you must manually reload the EPG to see them.)

Please file bug reports for stuff that does not work.

On Mon, Aug 22, 2011 at 8:57 AM, Brian Schneider <lehi...@gmail.com> wrote:
Super... I'll just add in the exception handling tonight or tomorrow and we should be set.

--
You received this message because you are subscribed to the Google Groups "SageTV for Boxee (Development)" group.
To view this discussion on the web visit https://groups.google.com/d/msg/sagetv-boxee-dev/-/EC5qcyx7vygJ.

Brian Schneider

unread,
Aug 22, 2011, 10:36:04 PM8/22/11
to sagetv-b...@googlegroups.com
Likewise... I just committed r144 which should now be a nearly fully working "Record Options" subdialog (minus the favorites piece) where you can adjust the end time for an airing.

David Hamann

unread,
Aug 23, 2011, 1:34:31 AM8/23/11
to sagetv-b...@googlegroups.com
This is coming along very nicely.

Unless anyone objects can we delete recordings_options_episode.xml (window 14077), since it's been replaced by mediafile_airing_options.xml (14999)

Reply all
Reply to author
Forward
0 new messages