 	 *  @playerversion AIR 1.1
 	 *  @productversion Flex 3
 	 */
-	public function getAssociatedModuleFactory(
-						fontName:String, bold:Boolean, italic:Boolean,
-						object:Object,
-						defaultModuleFactory:IFlexModuleFactory):
-						IFlexModuleFactory
-	{
-
-		var font:EmbeddedFont;
-		font = cachedFontsForObjects[object];
-		if (!font)
-		{
-			font = new EmbeddedFont(fontName, bold, italic);
-			cachedFontsForObjects[object] = font;
-		}
+    public function getAssociatedModuleFactory(
+                        fontName:String, bold:Boolean, italic:Boolean,
+                        object:Object,
+                        defaultModuleFactory:IFlexModuleFactory,
+                        systemManager:ISystemManager,
+                        embeddedCff:*=undefined):
+                        IFlexModuleFactory
+    {
+
+        var font:EmbeddedFont;
+        font = cachedFontsForObjects[object];
+        if (!font)
+        {
+            font = new EmbeddedFont(fontName, bold, italic);
+            cachedFontsForObjects[object] = font;
+        }
         else
         {
             // replace if not the same

                font.bold != bold ||
                font.italic != italic)
            {
			    font = new EmbeddedFont(fontName, bold, italic);
			    cachedFontsForObjects[object] = font;
            }

        }

		var fontDictionary:Dictionary = fonts[createFontKey(font)];
		if (fontDictionary)
		{
			// First lookup in the dictionary. If not found, then
			// take the first moduleFactory in the dictionary.
			// A module can register a font that is not unique and still
			// use that font as long as its components specify the moduleFactory.
			// A module can use fonts in other modules but
			// to get consistent behavior the font should be unique.
			var found:int = fontDictionary[defaultModuleFactory];

			if (found)
				return defaultModuleFactory;
										
			for (var iter:Object in fontDictionary)
			{
				return iter as IFlexModuleFactory;
			}
		}
		
		return null;
	}
}

}

package mx.core
{

import flash.system.Capabilities;
import flash.text.FontStyle;
import flash.text.TextField;
import flash.text.TextFormat;
import flash.text.engine.FontDescription;
import flash.utils.Dictionary;
import flash.utils.getQualifiedClassName;

import mx.managers.ISystemManager;
import mx.resources.IResourceManager;
import mx.resources.ResourceManager;

use namespace mx_internal;

