Template fix
This commit is contained in:
@@ -48,6 +48,12 @@ class DefaultAssetLibrary extends AssetLibrary {
|
||||
|
||||
super ();
|
||||
|
||||
#if (openfl && !flash)
|
||||
::if (assets != null)::
|
||||
::foreach assets::::if (type == "font")::openfl.text.Font.registerFont (__ASSET__OPENFL__::flatName::);::end::
|
||||
::end::::end::
|
||||
#end
|
||||
|
||||
#if flash
|
||||
|
||||
::if (assets != null)::::foreach assets::::if (embed)::className.set ("::id::", __ASSET__::flatName::);::else::path.set ("::id::", "::resourceName::");::end::
|
||||
@@ -72,12 +78,6 @@ class DefaultAssetLibrary extends AssetLibrary {
|
||||
|
||||
#else
|
||||
|
||||
#if openfl
|
||||
::if (assets != null)::
|
||||
::foreach assets::::if (type == "font")::openfl.text.Font.registerFont (__ASSET__OPENFL__::flatName::);::end::
|
||||
::end::::end::
|
||||
#end
|
||||
|
||||
#if (windows || mac || linux)
|
||||
|
||||
var useManifest = false;
|
||||
@@ -803,13 +803,12 @@ class DefaultAssetLibrary extends AssetLibrary {
|
||||
::end::::end::::end::
|
||||
::end::
|
||||
|
||||
#end
|
||||
#end
|
||||
|
||||
#if openfl
|
||||
#if (openfl && !flash)
|
||||
::if (assets != null)::::foreach assets::::if (type == "font")::@:keep #if display private #end class __ASSET__OPENFL__::flatName:: extends openfl.text.Font { public function new () { ::if (embed)::var font = new __ASSET__::flatName:: (); src = font.src; name = font.name;::else::__fontPath = #if ios "assets/" + #end "::targetPath::"; name = "::fontName::";::end:: super (); }}
|
||||
::end::::end::::end::
|
||||
#end
|
||||
|
||||
#end
|
||||
#end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user