How make a full screen Flash activity opened using hulahop.webview.WebView close from Flash?
frank at gsc.uy
Thu May 16 10:40:28 EDT 2013
I have Flash activity in which all user interaction is done through
Flash. Basically what I did was create a hulahop.webview.WebView
instance and make it load a HTML (see code at the end) that load a
.swf file in full screen. So far so good, the problem come when I try
close the entire activity from inside Flash UI (with a close button).
sentence and then from the Flash app "execute it". I create a simple
HTML file with just a button and a "window.close();" in the onclick
event and make it work using the Browse activity. For that, I changed
the gecko profile used by the Browse activity (setting the variable
"dom.allow_scripts_to_close_windows" to true). That made possible
close the entire Browse activity using the "window.close();"
even I made it using the same profile that worked for the Browse
I think that the problem is related to the way my activity manager the
hulahop.webview.WebView instance. I know Python but I'm a completely
newbie in GTK, Sugar and hulahop, and is hard to me find out the
problem. I write to this list hoping that someone with the enough
experience in those tech could take few minutes and help me.
Thanks in advance
from hulahop.webview import WebView
HTML = os.getcwd()+'/index.html'
def __init__(self, handle):
activity.Activity.__init__(self, handle, False)
canvas = gtk.HBox()
self.browser = WebBrowser()
def destroy(self, widget=None):
self.browser = None
self.browser = WebView()
More information about the Devel