autodemo.quote = new (function()
{
    this.newSize = function(width, height)
    {
        $(this.fo).width(width);
        $(this.fo).height(height);
    }
    
    this.handleEvent = function(ownerID, eventName)
    {
        if (ownerID == 'window' && eventName == 'load')
        {
            if (!$.browser.safari && $('#quotes').length)
            {
                var quotes = $('#quotes');
                var quoteText = $('#quotes .quote1').text();
                var quoteName = $('#quotes .quote2 span').text();
                var flash = new cFlash('/static/swf/QuoteText.swf', 8, quotes.width(), quotes.height() + 20);
                flash.setAltHTML(quotes.html());
                flash.setParameter('wmode', 'transparent');
                flash.setVariable('quoteText', escape(quoteText));
                flash.setVariable('quoteName', escape(quoteName));
                flash.writeIn('quotes');
                this.fo = flash.__fo;
            }
        }
    }
    
    autodemo.addEventListener(this, 'window');
});