Add initial Flash support

This commit is contained in:
Joshua Granick
2014-06-13 17:22:05 -07:00
parent affe97e040
commit 210ab867e0
39 changed files with 1179 additions and 609 deletions

View File

@@ -0,0 +1,42 @@
import ::APP_MAIN::;
class ApplicationMain {
private var app:lime.app.Application;
public static function main () {
var app = new ::APP_MAIN:: ();
var config:lime.app.Config = {
antialiasing: Std.int (::WIN_ANTIALIASING::),
borderless: ::WIN_BORDERLESS::,
depthBuffer: ::WIN_DEPTH_BUFFER::,
fps: Std.int (::WIN_FPS::),
fullscreen: ::WIN_FULLSCREEN::,
height: Std.int (::WIN_HEIGHT::),
orientation: "::WIN_ORIENTATION::",
resizable: ::WIN_RESIZABLE::,
stencilBuffer: ::WIN_STENCIL_BUFFER::,
title: "::APP_TITLE::",
vsync: ::WIN_VSYNC::,
width: Std.int (::WIN_WIDTH::),
}
app.create (config);
var result = app.exec ();
#if sys
Sys.exit (result);
#end
}
}

View File

@@ -0,0 +1,6 @@
-main ApplicationMain ::HAXE_FLAGS::
-swf-version ::SWF_VERSION::
-swf ::BUILD_DIR::/flash/bin/::APP_FILE::.swf
-swf-header ::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end:::::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end:::::WIN_FPS:::::WIN_FLASHBACKGROUND::
-cp ::BUILD_DIR::/flash/haxe
-debug

View File

@@ -0,0 +1,6 @@
-main ApplicationMain ::HAXE_FLAGS::
-swf-version ::SWF_VERSION::
-swf ::BUILD_DIR::/flash/bin/::APP_FILE::.swf
-swf-header ::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end:::::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end:::::WIN_FPS:::::WIN_FLASHBACKGROUND::
-cp ::BUILD_DIR::/flash/haxe
-D final

View File

@@ -0,0 +1,5 @@
-main ApplicationMain ::HAXE_FLAGS::
-swf-version ::SWF_VERSION::
-swf ::BUILD_DIR::/flash/bin/::APP_FILE::.swf
-swf-header ::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end:::::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end:::::WIN_FPS:::::WIN_FLASHBACKGROUND::
-cp ::BUILD_DIR::/flash/haxe

View File

@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="utf-8" ?>
<application xmlns="http://ns.adobe.com/air/application/3.3">
<id>::APP_PACKAGE::</id>
<versionNumber>::APP_VERSION::</versionNumber>
<filename>::APP_FILE::</filename>
<name>::APP_TITLE::</name>
<description>::APP_DESCRIPTION::</description>
<!-- <copyright>????</copyright> -->
<initialWindow>
<title>::APP_TITLE::</title>
<content>::APP_FILE::.swf</content>
<systemChrome>standard</systemChrome>
<transparent>false</transparent>
<visible>true</visible>
<minimizable>true</minimizable>
<maximizable>false</maximizable>
<resizable>::WIN_RESIZABLE::</resizable>
<!-- <width>::WIN_WIDTH::</width>
<height>::WIN_HEIGHT::</height>
<minSize>320 240</minSize>
<maxSize>1280 960</maxSize> -->
</initialWindow>
<installFolder>::APP_COMPANY::/::APP_TITLE::</installFolder>
<programMenuFolder>::APP_TITLE::</programMenuFolder>
<!-- <icon>
<image16x16>icon_16.png</image16x16>
<image32x32>icon_32.png</image32x32>
<image48x48>icon_48.png</image48x48>
<image128x128>icon_128.png</image128x128>
</icon> -->
<customUpdateUI>false</customUpdateUI>
<allowBrowserInvocation>false</allowBrowserInvocation>
<!-- <fileTypes>
<fileType>
<name>adobe.VideoFile</name>
<extension>avf</extension>
<description>Adobe Video File</description>
<contentType>application/vnd.adobe.video-file</contentType>
<icon>
<image16x16>icons/avfIcon_16.png</image16x16>
<image32x32>icons/avfIcon_32.png</image32x32>
<image48x48>icons/avfIcon_48.png</image48x48>
<image128x128>icons/avfIcon_128.png</image128x128>
</icon>
</fileType>
</fileTypes> -->
<android>
<manifestAdditions>
<![CDATA[
<manifest>
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
</manifest>
]]>
</manifestAdditions>
</android>
</application>

Binary file not shown.

View File

@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<title>::APP_TITLE::</title>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
swfobject.embedSWF ("::APP_FILE::.swf", "nme-application", "::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end::", "::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end::", "::SWF_VERSION::", "expressInstall.swf", ::WIN_PARAMETERS::);
</script>
<style>
html, body, #nme-application { width:::if (WIN_WIDTH == "0")::100%::else::::WIN_WIDTH::px::end::; height:::if (WIN_HEIGHT == "0")::100%::else::::WIN_HEIGHT::px::end::; }
body { margin:0; padding:0; overflow:hidden; }
</style>
</head>
<body>
<div id="nme-application"></div>
</body>
</html>

View File

@@ -0,0 +1,14 @@
{
"name": "::APP_TITLE::",
"description": "::APP_DESCRIPTION::",
"version": "::APP_VERSION::",
"app": {
"launch": {
"local_path": "index.html"
}
},
"icons": {
"16": "icon_16.png",
"128": "icon_128.png"
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,21 @@
<widget defaultmode="application">
<widgetname>::APP_TITLE::</widgetname>
<description>::APP_DESCRIPTION::</description>
<width>::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end::</width>
<height>::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end::</height>
<author>
<name>::APP_COMPANY::</name>
<!-- <email></email> -->
<organization>::APP_COMPANY::</organization>
<!-- <link></link> -->
</author>
<icon width="128" height="128">icon_128.png</icon>
<icon width="64" height="64">icon_64.png</icon>
<icon width="32" height="32">icon_32.png</icon>
<icon width="16" height="16">icon_16.png</icon>
<id>
<host>::APP_PACKAGE_HOST::</host>
<name>::APP_PACKAGE_NAME::</name>
<revised>::REVISION_DATE::</revised>
</id>
</widget>

Binary file not shown.

View File

@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<title>::APP_TITLE::</title>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
swfobject.embedSWF ("::APP_FILE::.swf", "nme-application", "::if (WIN_WIDTH == "0")::800::else::::WIN_WIDTH::::end::", "::if (WIN_HEIGHT == "0")::500::else::::WIN_HEIGHT::::end::", "::SWF_VERSION::", "expressInstall.swf", ::WIN_PARAMETERS::);
</script>
<style>
html, body, #nme-application { width:::if (WIN_WIDTH == "0")::100%::else::::WIN_WIDTH::px::end::; height:::if (WIN_HEIGHT == "0")::100%::else::::WIN_HEIGHT::px::end::; }
body { margin:0; padding:0; overflow:hidden; }
</style>
</head>
<body>
<div id="nme-application"></div>
</body>
</html>

File diff suppressed because one or more lines are too long

Binary file not shown.

View File

@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<title>::APP_TITLE::</title>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
swfobject.embedSWF ("::APP_FILE::.swf", "nme-application", "::if (WIN_WIDTH == 0)::800::else::::WIN_WIDTH::::end::", "::if (WIN_HEIGHT == 0)::500::else::::WIN_HEIGHT::::end::", "::SWF_VERSION::", "expressInstall.swf", ::WIN_PARAMETERS::);
</script>
<style>
html, body, #nme-application { width:::if (WIN_WIDTH == 0)::100%::else::::WIN_WIDTH::px::end::; height:::if (WIN_HEIGHT == 0)::100%::else::::WIN_HEIGHT::px::end::; }
body { margin:0; padding:0; overflow:hidden; }
</style>
</head>
<body>
<div id="nme-application" />
</body>
</html>

File diff suppressed because one or more lines are too long