Posted: February 4, 2010 at 12:29 pm
I had someone come to me with some issues using the CSS item in QueueLoader. We went back and forth and I had forgotten that QueueLoader parses the stylesheet from the loader data internally. OK great, but still couldn't get the text to style. I've actually had problems with textfields and css in general in the past. So I did a little troubleshooting and was able to get it working fine. Seems the issue was making sure you set the textfield's css property BEFORE adding any html text to it. This sort of seems obvious in hindsight, but it's not one of those immediately obvious things when your scanning over code and/or tracking the flow of your functions. So yeah, do that first
Here's some slightly updated CSS code:
// CSS Example
import com.hydrotik.queueloader.QueueLoader;
import com.hydrotik.queueloader.QueueLoaderEvent;
import com.hydrotik.queueloader.QueueLoaderConst;
var _oLoader:QueueLoader = new QueueLoader();
var tf:TextField = this.getChildByName("css_text") as TextField;
var css:StyleSheet;
_oLoader.addItem("../includes/admin/test.css", null, {title:"CSS"});
_oLoader.addEventListener(QueueLoaderEvent.ITEM_COMPLETE, onItemComplete,false, 0, true);
_oLoader.addEventListener(QueueLoaderEvent.QUEUE_PROGRESS, onQueueProgress, false, 0, true);
_oLoader.addEventListener(QueueLoaderEvent.QUEUE_COMPLETE, onQueueComplete,false, 0, true);
_oLoader.execute();
function onQueueProgress(event:QueueLoaderEvent):void {
trace("\t>>onQueueProgress: "+event.queuepercentage);
}
function onItemComplete(event:QueueLoaderEvent):void {
trace("\t>> "+event.type, "item title: "+event.title);
if (event.fileType == QueueLoaderConst.FILE_CSS) {
trace("\t\tCSS: "+event.content.styleNames);
css = event.content;
}
}
function onQueueComplete(event:QueueLoaderEvent):void {
trace("** "+event.type);
// MAKE SURE YOU STYLE THE FIELD FIRST BEFORE SETTING THE HTML TEXT!!
tf.styleSheet = css;
tf.htmlText = "<p>This is a Test <a href='http://www.test.com'> More Text</a></p>";
}
This person also suggested that I provide detailed guides for people and a website to promote QL. There are plenty of examples within this blog as well as a place on github to keep track of QueueLoader and (hopefully) promote it. Github is also the most authoritative source on QueueLoader. It even has a logo! That said, his comments do bring up a couple of points. The first is that between the code snippets and the examples on the blog, as well as the examples.fla file in the slighty older zip file, it might be a bit confusing on how to get set up. If you download the older example files, you can then get the latest version of QL and overwrite it/update it by placing it in the proper package. The only thing that has changed significantly is the QueueLoaderConst file. If you are checking for specific item type, then you would need to change the class i.e. QueueLoader.FILE_CSS to QueueLoaderConst.FILE_CSS. This was done to improve performance. Also be sure to include the import to QueueLoaderConst.
Said person (I swear I'm not picking you:) also suggested that QL is geared towards more hard core actionscripters which isn't really the case. I know it's a jump getting into some external library based utilities, but I think (and hope) QL is set up to be almost as easy as using a core loader class and is easier to use then other options out there. I'm thinking the frustration comes from the disjointed hosting locations/examples and putting the information in the users hands. On the flip side however, there are plenty of recent links to github and I encourage you to check out the wiki as all the examples are there. Also do a search on the blog, there are a ton of posts on QL and many of the examples are still close enough to the current structure, they should get the idea across. If something is out of date on github let me know, or feel free to fork it!
Lastly, I know the documentation can be improved, the files could be retroactively updated, etc. But keep in mind that I don't get paid for this, I very rarely get a donation (I'm actually surprised when i do get one;), I've never gotten a job from QL, and for quite some time I have had no help with QL. I really, really enjoy working on QL and Flash in general and I'm certainly not complaining. Most importantly, I also would hate to discourage people from coming to me with issues or needing help. Just wanted to get this off my chest:)
Posted: November 25, 2009 at 1:07 pm
Github is the social networking version of a version control system. The learning curve with Git can be a little tricky at first, but after installing and learning the basic commands you will be up and running. The beauty of Git lies in the way it collects and organizes changes and data. Merging from multiples sources is reliable and makes for more contributions. This will hopefully encourage more people to get involved with Open Source projects including QueueLoader! I will still be providing a standalone link either here on the site or on the deprecated Google Page, but for wiki usage and change info definitely go to Github.
QueueLoader on Github
Posted: November 23, 2009 at 9:03 pm

Just completed a rush project for the film Across The Hall. Being that this is a noir styled film, I came up with a simple class that emulates the effect of sign letters turning on. Could work for Fluorescent lights as well as other stuff. Easiest way to use it is to link the MovieClip in your library you intend to export and point the base class path to FluorescentBallastFlicker.

Then in your code, instantiate and attach the MovieClip to your DisplayObject and the MovieClip will automatically set its alpha to 0 and will be ready to turn on.
The turnOn() method takes the arguments; seconds of turn on time, seconds of delay, and an optional callback function when the effect has finished.
_hSign.turnOn(1, 0);
_oSign.turnOn(2, .5);
_tSign.turnOn(2, 1);
_eSign.turnOn(2, 1.5);
_lSign.turnOn(2, 2);
_riverview.turnOn(2, 2.5, startSite);
Once the item is on, you can use the badBallast() method to emulate a loose connection. The lower the number the more frequent the flickering.
Download Fluorescent Ballast and Neon Flicker Class Source Code!
Posted: November 23, 2009 at 11:00 am
I was the victim of Malware over the weekend. So the blog has a new look and my apologies for the temporary default theme. Trying to get everything back in order and more posts to come soon!
Posted: October 6, 2009 at 11:30 pm
Announcing a long overdue update of QueueLoader last week. Fixes include finally addressing the error handling of a missing item that is first loaded. Also some optimization of the utility with interfaces.
Click here to download
The google group has been growing and hopefully it has been helpful. I set up an approval process for membership to reduce the amount of spam. I typically approve members within 12 hours.
Click here to join
Any additional suggestions or issues are welcome. Also feel free to click on our sponsors!
Posted: January 29, 2009 at 1:12 pm
This is a condensed collection of freelance web design and development projects that I have done for clients in Anguilla, British West Indies. Anguilla is located on the most north eastern edge of the Caribbean islands and is known for its amazing beaches.
Currently all of the web development work I do is done in Flash. For all of these projects I provide SEO (Search Engine Optimization) content using a PHP based technique for "ghosting" pages, sections within the Flash are tracked using Google Analytics, as well as an external XML file for easy updating copy content and some graphical resources.
Feel free to contact me for more info.
Tequila Sunrise Villa

Charming Escapes Collection

Maris Edwards Design

Lloyd's Bed and Breakfast

Purple Rose Florist

Ambia Bed and Breakfast

Posted: November 30, 2008 at 12:57 pm

I'm excited about the launch of www.youwillknowthetruth.com. Keep checking the site as clues will be released frequently leading up to the moment of truth!

Posted: December 20, 2007 at 10:35 pm
Here's my latest tweening module for Go called HydroTween. Using HydroTween with the Go system is as easy as:
HydroTween.go(target, {width:760}, .8, 0, Exponential.easeInOut, onCompleteHandler);
Be sure to go to goasap.org to get the Go source.
HydroTween Source
Posted: December 4, 2007 at 12:32 am
Latest Version Info:
Click here for the current rev
Click here for the usage guide
Click here for the change log
Also click here for any posts related to the latest changes:
QueueLoader Updates
Rev 10 Update
You can easily draw the frames of an externally loaded SWF to bitmap objects in an Array which was suggested by Carlos Ulloa. I'm still looking for people to help with rigorous testing and features. Contact me if you are interested.
Posted: December 4, 2007 at 12:19 am
Had a great time at the Papervision 2.0 seminar with John Grden and Andy Zupko here in NYC. Lot of eager people braving the cold snowy weather. It was slow at times trying to get everyone going on Flex. This gave me time to get the demos working in AS3 only FDT projects. Hopefully with John's and Andy's blessing I can put those demos here on the blog