Allow the font library path to be specified with a parameter
authorTom Hughes <tom@compton.nu>
Sun, 25 Mar 2012 10:01:53 +0000 (11:01 +0100)
committerTom Hughes <tom@compton.nu>
Sun, 25 Mar 2012 11:46:47 +0000 (12:46 +0100)
potlatch2.mxml

index 87c1e5c..ea4ed06 100644 (file)
                private function startInit():void {
                        var loader:Loader = new Loader();
                        loader.contentLoaderInfo.addEventListener(Event.COMPLETE, startApp);
-                       loader.load(new URLRequest("FontLibrary.swf"));
+            if (loaderInfo.parameters['font_library']) {
+                           loader.load(new URLRequest(loaderInfo.parameters['font_library']));
+            } else {
+                           loader.load(new URLRequest("FontLibrary.swf"));
+            }
 
             if (loaderInfo.parameters['locale'] && loaderInfo.parameters['locale']!='en_US') {
                 // we don't bother with localisation if the user is en_US, as P2 is in English by default