Firefox plugin development and embedding an .swf in xul with html:embed
I have a big problem with my firefox plugin. 开发者_如何学JAVAI have a button, which opens a new window for me, where I want to include that .swf file.
Here is the XUL code for the embedding:
<html:embed src="Reader.swf"
width="250"
height="250"
type="application/x-shockwave-flash" />
-> html namespace was set above:
xmlns:html="http://www.w3.org/1999/xhtml"
Reader.swf is in the same directory as the xul file
without the html:embed, the window opens without problems, but as soon as I change that, firefox crashes without warning or something, it just disapears from the process bar.
the .swf file works properly when I open it from my operating system (its windows 7 64 bit) and is coded in as3.
can somebody help me?
Instead of placing the swf file directly into the new window, try wrapping it in a minimal html page. Or you could use the html page that flash generates for you when you publish your movie. I haven't played with XUL, but I have noticed that placing swf files directly into browsers is a little inconsistent across browsers. For example, some browsers will scale the movie to 100% of the available window space, others will not.
精彩评论