View Full Version : Closing a window
June 14th, 2009, 12:18 AM
This may sound dumb but is there any way to close a window by it reference.
Dialog.Close() only seems to close windows whos type="dialog" not type="window"
I wont users to be able click a button and close any current open windows other then the original window, but I can't seem to find anyway to do this. I have print dir() the window object trying to find any hidden functions. Grep'd through source code and can't find a single thing on how to do it.
June 14th, 2009, 05:19 AM
you are right. thats not in the api and we need to get it in there.
hopefully in coming version.
June 15th, 2009, 03:32 PM
Along the same lines I also noticed that if you call mc.GetApp().ActivateWindow() it doesn't run the <onload> until what would be the onUnLoad event when the window is of type Dialog. Came across this when I was trying to open a window with params and wanted the onload event to handle those params.
September 24th, 2009, 03:53 PM
just had the same experience with a dialog.
an attempt to pass parameters to a dialog and using them in the dialog made boxee crash.
October 1st, 2010, 04:17 PM
I just put up a post on using dialogs on the Boxee Developer blog here:
Going to queue up a post on passing parameters next week, but basically dialogs are executed in the same context as the window that activated it. What that means is that you do not have to use the App object to pass parameters - you can just pass regular Python data objects like variables, lists or dictionaries.
Powered by vBulletin® Version 4.1.12 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.