We've been working with Flare recently to visualize potential learner flows through elearning courses. One of the cool features within flare is the ability to zoom in on a visualization via the mouse scrollwheel, similar to the browsers Ctrl-Scoll functionality to change font sizes.
Everything works fine in Flex, using the default html publishing templates, but we found that the scoll message was not being propigated through when using SWFObject.
I updated the code to the latest swfobject version (v 2.0), but still no love. After trolling the web for a while, I discovered that there are a number of issues involving wmode="transparent". By removing that attribute, everything started working. Unfortunately, I am not sure whether the real issue was a combination of an older version of swfobject and the wmode bug, or whether simply turning off wmode in the older version would have fixed the problem.
Here's the syntax:
<script type="text/javascript">
// <![CDATA[
var flashvars = {
config: "/files/simFlow/config.xml"
};
var params = {
//using wmode transparent causes mouse click wheel support to break
//wmode: "transparent"
};
var attributes = {
id: "simflow",
name: "simflow",
style: "width:100%; height:100%;"
};
var so = swfobject.embedSWF("someFlashFile.swf", "simFlow", "100%", "100%", "9.0.115", "/files/flexSupportFiles//swfobject2/expressInstall.swf", flashvars, params, attributes);
// ]]>
</script>
<div id="simFlow" style="width:100%; height:100%;"> </div>
Jul 2, 2009 at 2:45 PM Hey. Great info. That was the exact problem i was having. Simply removed the wmode, which wasn't needed anyways, and it worked like a charm. Thanks!
Nov 12, 2009 at 5:42 AM Well this is very interesting indeed.Would love to read a little more of this. Great post. Thanks for the heads-up…This blog was very informative and knowledgeable