"});
}
}
});
if ($("#search-results-list").length == 0) {
// append to nav
$("#nav").parent().append("
");
}
listItems.sort(function(x, y) { return x.score - y.score; }); // put in order
$("#search-results-list").css("display","block").html(listItems.map(function(x) { return x.item; }).join(""));
}
function match(textParts, query) {
var queryParts = query.split(".");
if (queryParts.length == 1) {
var queryPart = queryParts[0];
for (var i = 0; i < textParts.length; ++i) {
var textPart = textParts[i];
if (textPart.indexOf(queryPart) > -1) {
// We don't want to match the same part twice, so let's remove it
textParts[i] = textParts[i].split(queryPart).join("");
return textPart.length - queryPart.length;
}
}
} else {
var offset = -1;
outer:
while (true) {
++offset;
if (queryParts.length + offset > textParts.length) {
return -1;
}
var scoreSum = 0;
for (var i = 0; i < queryParts.length; ++i) {
var queryPart = queryParts[i];
var textPart = textParts[i + offset];
var index = textPart.indexOf(queryPart);
if (index != 0) {
continue outer;
}
scoreSum += textPart.length - queryPart.length;
}
return scoreSum;
}
}
}
function searchMatch(text, queryParts) {
text = text.toLowerCase();
var textParts = text.split(".");
var scoreSum = 0;
for (var i = 0; i < queryParts.length; ++i) {
var score = match(textParts, queryParts[i]);
if (score == -1) {
return -1;
}
scoreSum += score + text.length;
}
return scoreSum;
}
================================================
FILE: assets/docs-theme/templates/package_description.mtt
================================================
::api.currentPageName:: version ::api.getValue('version')::
::api.getValue("description")::
================================================
FILE: assets/docs-theme/templates/topbar.mtt
================================================
================================================
FILE: dependencies/extension-api/build.gradle
================================================
buildscript {
repositories {
mavenCentral()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:::ANDROID_GRADLE_PLUGIN::'
}
}
apply plugin: 'com.android.library'
android {
namespace 'org.haxe.extension'
compileSdkVersion Integer.parseInt(project.ANDROID_BUILD_SDK_VERSION)
buildToolsVersion project.ANDROID_BUILD_TOOLS_VERSION
defaultConfig {
minSdkVersion Integer.parseInt(project.ANDROID_BUILD_MIN_SDK_VERSION)
targetSdkVersion Integer.parseInt(project.ANDROID_BUILD_TARGET_SDK_VERSION)
}
}
================================================
FILE: dependencies/extension-api/src/main/AndroidManifest.xml
================================================
================================================
FILE: dependencies/extension-api/src/main/java/org/haxe/HXCPP.java
================================================
package org.haxe;
// Wrapper for native library
public class HXCPP {
private static boolean mInit = false;
public static native void main ();
public static void run (String inClassName) {
System.loadLibrary (inClassName);
if (!mInit) {
mInit = true;
main ();
}
}
}
================================================
FILE: dependencies/extension-api/src/main/java/org/haxe/extension/Extension.java
================================================
package org.haxe.extension;
import android.app.Activity;
import android.content.res.AssetManager;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.view.View;
public class Extension {
public static AssetManager assetManager;
public static Handler callbackHandler;
public static Activity mainActivity;
public static Context mainContext;
public static View mainView;
public static String packageName;
/**
* Called when an activity you launched exits, giving you the requestCode
* you started it with, the resultCode it returned, and any additional data
* from it.
*/
public boolean onActivityResult (int requestCode, int resultCode, Intent data) {
return true;
}
public boolean onRequestPermissionsResult(int requestCode, String permissions[], int[] grantResults) {
return true;
}
public boolean onBackPressed () {
return true;
}
/**
* Called when the activity is starting.
*/
public void onCreate (Bundle savedInstanceState) {
}
/**
* Perform any final cleanup before an activity is destroyed.
*/
public void onDestroy () {
}
/**
* Called when the overall system is running low on memory,
* and actively running processes should trim their memory usage.
* This is a backwards compatibility method as it is called at the same time as
* onTrimMemory(TRIM_MEMORY_COMPLETE).
*/
public void onLowMemory () {
}
/**
* Called when the a new Intent is received
*/
public void onNewIntent (Intent intent) {
}
/**
* Called as part of the activity lifecycle when an activity is going into
* the background, but has not (yet) been killed.
*/
public void onPause () {
}
/**
* Called after {@link #onStop} when the current activity is being
* re-displayed to the user (the user has navigated back to it).
*/
public void onRestart () {
}
/**
* Called after {@link #onRestart}, or {@link #onPause}, for your activity
* to start interacting with the user.
*/
public void onResume () {
}
/**
* Called after onStart() when the activity is being re-initialized from
* a previously saved state.
*/
public void onRestoreInstanceState (Bundle savedState) {
}
/**
* Called to retrieve per-instance state from an activity before being
* killed so that the state can be restored in onCreate
*/
public void onSaveInstanceState (Bundle outState) {
}
/**
* Called after {@link #onCreate} — or after {@link #onRestart} when
* the activity had been stopped, but is now again being displayed to the
* user.
*/
public void onStart () {
}
/**
* Called when the activity is no longer visible to the user, because
* another activity has been resumed and is covering this one.
*/
public void onStop () {
}
/**
* Called when the operating system has determined that it is a
* good time for a process to trim unneeded memory from its process.
*
* See http://developer.android.com/reference/android/content/ComponentCallbacks2.html for the level explanation.
*/
public void onTrimMemory (int level) {
}
}
================================================
FILE: dependencies/extension-api/src/main/java/org/haxe/lime/HaxeObject.java
================================================
package org.haxe.lime;
import android.util.Log;
import java.lang.Boolean;
import java.lang.Byte;
import java.lang.Character;
import java.lang.Short;
import java.lang.Integer;
import java.lang.Long;
import java.lang.Float;
import java.lang.Double;
/**
A placeholder for an object created in Haxe. You can call the object's
functions using `callN("functionName")`, where N is the number of arguments.
Caution: the Haxe function will run on whichever thread you call it from.
Java code typically runs on the UI thread, not Haxe's main thread, which can
easily cause thread-related errors. This cannot be easily remedied using Java
code, but is fixable in Haxe using `lime.system.JNI.JNISafety`.
Sample usage:
```haxe
// MyHaxeObject.hx
import lime.system.JNI;
class MyHaxeObject implements JNISafety
{
@:runOnMainThread
public function onActivityResult(requestCode:Int, resultCode:Int):Void
{
// Insert code to process the result. This code will safely run on the
// main Haxe thread.
}
}
```
```java
// MyJavaTool.java
import android.content.Intent;
import org.haxe.extension.Extension;
import org.haxe.lime.HaxeObject;
public class MyJavaTool extends Extension
{
private static var haxeObject:HaxeObject;
public static function registerHaxeObject(object:HaxeObject)
{
haxeObject = object;
}
// onActivityResult() always runs on the Android UI thread.
@Override public boolean onActivityResult(int requestCode, int resultCode, Intent data)
{
haxeObject.call2(requestCode, resultCode);
return true;
}
}
```
**/
public class HaxeObject
{
public long __haxeHandle;
public HaxeObject(long value)
{
__haxeHandle = value;
}
public static HaxeObject create(long inHandle)
{
if (inHandle == 0)
return null;
return new HaxeObject(inHandle);
}
protected void finalize() throws Throwable {
try {
Lime.releaseReference(__haxeHandle);
} finally {
super.finalize();
}
}
public Object call0(String function)
{
//Log.e("HaxeObject","Calling obj0" + function + "()" );
return Lime.callObjectFunction(__haxeHandle,function,new Object[0]);
}
public Object call1(String function,Object arg0)
{
Object[] args = new Object[1];
args[0] = arg0;
//Log.e("HaxeObject","Calling obj1 " + function + "(" + arg0 + ")" );
return Lime.callObjectFunction(__haxeHandle,function,args);
}
public Object call2(String function,Object arg0,Object arg1)
{
Object[] args = new Object[2];
args[0] = arg0;
args[1] = arg1;
//Log.e("HaxeObject","Calling obj2 " + function + "(" + arg0 + "," + arg1 + ")" );
return Lime.callObjectFunction(__haxeHandle,function,args);
}
public Object call3(String function,Object arg0,Object arg1,Object arg2)
{
Object[] args = new Object[3];
args[0] = arg0;
args[1] = arg1;
args[2] = arg2;
//Log.e("HaxeObject","Calling obj3 " + function + "(" + arg0 + "," + arg1 + "," + arg2 + ")" );
return Lime.callObjectFunction(__haxeHandle,function,args);
}
public Object call4(String function,Object arg0,Object arg1,Object arg2,Object arg3)
{
Object[] args = new Object[4];
args[0] = arg0;
args[1] = arg1;
args[2] = arg2;
args[3] = arg3;
//Log.e("HaxeObject","Calling obj4 " + function + "(" + arg0 + "," + arg1 + "," + arg2 + "," + arg3 + ")" );
return Lime.callObjectFunction(__haxeHandle,function,args);
}
public double callD0(String function)
{
//Log.e("HaxeObject","Calling objD0 " + function + "()" );
return Lime.callNumericFunction(__haxeHandle,function,new Object[0]);
}
public double callD1(String function,Object arg0)
{
Object[] args = new Object[1];
args[0] = arg0;
//Log.e("HaxeObject","Calling D1 " + function + "(" + arg0 + ")" );
return Lime.callNumericFunction(__haxeHandle,function,args);
}
public double callD2(String function,Object arg0,Object arg1)
{
Object[] args = new Object[2];
args[0] = arg0;
args[1] = arg1;
//Log.e("HaxeObject","Calling D2 " + function + "(" + arg0 + "," + arg1 + ")" );
return Lime.callNumericFunction(__haxeHandle,function,args);
}
public double callD3(String function,Object arg0,Object arg1,Object arg2)
{
Object[] args = new Object[2];
args[0] = arg0;
args[1] = arg1;
args[2] = arg2;
//Log.e("HaxeObject","Calling D3 " + function + "(" + arg0 + "," + arg1 + "," + arg2 + ")" );
return Lime.callNumericFunction(__haxeHandle,function,args);
}
public Object call(String function, Object[] args)
{
return Lime.callObjectFunction(__haxeHandle,function,args);
}
public double callD(String function, Object[] args)
{
return Lime.callNumericFunction(__haxeHandle,function,args);
}
}
================================================
FILE: dependencies/extension-api/src/main/java/org/haxe/lime/Lime.java
================================================
package org.haxe.lime;
public class Lime {
static {
System.loadLibrary("lime");
}
public static native void onCallback (long inHandle);
public static native Object callObjectFunction (long inHandle, String function, Object[] args);
public static native double callNumericFunction (long inHandle, String function, Object[] args);
public static native void releaseReference (long inHandle);
}
================================================
FILE: dependencies/extension-api/src/main/java/org/haxe/lime/Value.java
================================================
package org.haxe.lime;
public class Value {
double mValue;
public Value (double inValue) { mValue = inValue; }
public Value (int inValue) { mValue = inValue; }
public Value (short inValue) { mValue = inValue; }
public Value (char inValue) { mValue = inValue; }
public Value (boolean inValue) { mValue = inValue ? 1.0 : 0.0; }
public double getDouble () { return mValue; }
}
================================================
FILE: dependencies/lzma_worker-min.js
================================================
var e=function(){"use strict";function r(e,r){postMessage({action:xt,cbn:r,result:e})}function t(e){var r=[];return r[e-1]=void 0,r}function o(e,r){return i(e[0]+r[0],e[1]+r[1])}function n(e,r){return u(~~Math.max(Math.min(e[1]/Ot,2147483647),-2147483648)&~~Math.max(Math.min(r[1]/Ot,2147483647),-2147483648),c(e)&c(r))}function s(e,r){var t,o;return e[0]==r[0]&&e[1]==r[1]?0:(t=0>e[1],o=0>r[1],t&&!o?-1:!t&&o?1:h(e,r)[1]<0?-1:1)}function i(e,r){var t,o;for(r%=0x10000000000000000,e%=0x10000000000000000,t=r%Ot,o=Math.floor(e/Ot)*Ot,r=r-t+o,e=e-o+t;0>e;)e+=Ot,r-=Ot;for(;e>4294967295;)e-=Ot,r+=Ot;for(r%=0x10000000000000000;r>0x7fffffff00000000;)r-=0x10000000000000000;for(;-0x8000000000000000>r;)r+=0x10000000000000000;return[e,r]}function _(e,r){return e[0]==r[0]&&e[1]==r[1]}function a(e){return e>=0?[e,0]:[e+Ot,-Ot]}function c(e){return e[0]>=2147483648?~~Math.max(Math.min(e[0]-Ot,2147483647),-2147483648):~~Math.max(Math.min(e[0],2147483647),-2147483648)}function u(e,r){var t,o;return t=e*Ot,o=r,0>r&&(o+=Ot),[o,t]}function f(e){return 30>=e?1<e[1])throw Error("Neg");return s=f(r),o=e[1]*s%0x10000000000000000,n=e[0]*s,t=n-n%Ot,o+=t,n-=t,o>=0x8000000000000000&&(o-=0x10000000000000000),[n,o]}function d(e,r){var t;return r&=63,t=f(r),i(Math.floor(e[0]/t),e[1]/t)}function p(e,r){var t;return r&=63,t=d(e,r),0>e[1]&&(t=o(t,m([2,0],63-r))),t}function h(e,r){return i(e[0]-r[0],e[1]-r[1])}function P(e,r){return e.Mc=r,e.Lc=0,e.Yb=r.length,e}function l(e){return e.Lc>=e.Yb?-1:255&e.Mc[e.Lc++]}function v(e,r,t,o){return e.Lc>=e.Yb?-1:(o=Math.min(o,e.Yb-e.Lc),M(e.Mc,e.Lc,r,t,o),e.Lc+=o,o)}function B(e){return e.Mc=t(32),e.Yb=0,e}function S(e){var r=e.Mc;return r.length=e.Yb,r}function g(e,r){e.Mc[e.Yb++]=r<<24>>24}function k(e,r,t,o){M(r,t,e.Mc,e.Yb,o),e.Yb+=o}function R(e,r,t,o,n){var s;for(s=r;t>s;++s)o[n++]=e.charCodeAt(s)}function M(e,r,t,o,n){for(var s=0;n>s;++s)t[o+s]=e[r+s]}function D(e,r){Ar(r,1<a;a+=8)g(o,255&c(d(n,a)));r.yb=(_.W=0,_.oc=t,_.pc=0,Mr(_),_.d.Ab=o,Fr(_),wr(_),br(_),_.$.rb=_.n+1-2,Qr(_.$,1<<_.Y),_.i.rb=_.n+1-2,Qr(_.i,1<<_.Y),void(_.g=Gt),X({},_))}function w(e,r,t){return e.Nb=B({}),b(e,P({},r),e.Nb,a(r.length),t),e}function E(e,r,t){var o,n,s,i,_="",c=[];for(n=0;5>n;++n){if(s=l(r),-1==s)throw Error("truncated input");c[n]=s<<24>>24}if(o=ir({}),!ar(o,c))throw Error("corrupted input");for(n=0;64>n;n+=8){if(s=l(r),-1==s)throw Error("truncated input");s=s.toString(16),1==s.length&&(s="0"+s),_=s+""+_}/^0+$|^f+$/i.test(_)?e.Tb=At:(i=parseInt(_,16),e.Tb=i>4294967295?At:a(i)),e.yb=nr(o,r,t,e.Tb)}function L(e,r){return e.Nb=B({}),E(e,P({},r),e.Nb),e}function y(e,r,o,n){var s;e.Bc=r,e._b=o,s=r+o+n,(null==e.c||e.Kb!=s)&&(e.c=null,e.Kb=s,e.c=t(e.Kb)),e.H=e.Kb-o}function C(e,r){return e.c[e.f+e.o+r]}function z(e,r,t,o){var n,s;for(e.T&&e.o+r+o>e.h&&(o=e.h-(e.o+r)),++t,s=e.f+e.o+r,n=0;o>n&&e.c[s+n]==e.c[s+n-t];++n);return n}function F(e){return e.h-e.o}function I(e){var r,t,o;for(o=e.f+e.o-e.Bc,o>0&&--o,t=e.f+e.h-o,r=0;t>r;++r)e.c[r]=e.c[o+r];e.f-=o}function x(e){var r;++e.o,e.o>e.zb&&(r=e.f+e.o,r>e.H&&I(e),N(e))}function N(e){var r,t,o;if(!e.T)for(;;){if(o=-e.f+e.Kb-e.h,!o)return;if(r=v(e.cc,e.c,e.f+e.h,o),-1==r)return e.zb=e.h,t=e.f+e.zb,t>e.H&&(e.zb=e.H-e.f),void(e.T=1);e.h+=r,e.h>=e.o+e._b&&(e.zb=e.h-e._b)}}function O(e,r){e.f+=r,e.zb-=r,e.o-=r,e.h-=r}function A(e,r,o,n,s){var i,_,a;1073741567>r&&(e.Fc=16+(n>>1),a=~~((r+o+n+s)/2)+256,y(e,r+o,n+s,a),e.ob=n,i=r+1,e.p!=i&&(e.L=t(2*(e.p=i))),_=65536,e.qb&&(_=r-1,_|=_>>1,_|=_>>2,_|=_>>4,_|=_>>8,_>>=1,_|=65535,_>16777216&&(_>>=1),e.Ec=_,++_,_+=e.R),_!=e.rc&&(e.ub=t(e.rc=_)))}function H(e,r){var t,o,n,s,i,_,a,c,u,f,m,d,p,h,P,l,v,B,S,g,k;if(e.h>=e.o+e.ob)h=e.ob;else if(h=e.h-e.o,e.xb>h)return W(e),0;for(v=0,P=e.o>e.p?e.o-e.p:0,o=e.f+e.o,l=1,c=0,u=0,e.qb?(k=Tt[255&e.c[o]]^255&e.c[o+1],c=1023&k,k^=(255&e.c[o+2])<<8,u=65535&k,f=(k^Tt[255&e.c[o+3]]<<5)&e.Ec):f=255&e.c[o]^(255&e.c[o+1])<<8,n=e.ub[e.R+f]||0,e.qb&&(s=e.ub[c]||0,i=e.ub[1024+u]||0,e.ub[c]=e.o,e.ub[1024+u]=e.o,s>P&&e.c[e.f+s]==e.c[o]&&(r[v++]=l=2,r[v++]=e.o-s-1),i>P&&e.c[e.f+i]==e.c[o]&&(i==s&&(v-=2),r[v++]=l=3,r[v++]=e.o-i-1,s=i),0!=v&&s==n&&(v-=2,l=1)),e.ub[e.R+f]=e.o,S=(e.k<<1)+1,g=e.k<<1,d=p=e.w,0!=e.w&&n>P&&e.c[e.f+n+e.w]!=e.c[o+e.w]&&(r[v++]=l=e.w,r[v++]=e.o-n-1),t=e.Fc;;){if(P>=n||0==t--){e.L[S]=e.L[g]=0;break}if(a=e.o-n,_=(e.k>=a?e.k-a:e.k-a+e.p)<<1,B=e.f+n,m=p>d?d:p,e.c[B+m]==e.c[o+m]){for(;++m!=h&&e.c[B+m]==e.c[o+m];);if(m>l&&(r[v++]=l=m,r[v++]=a-1,m==h)){e.L[g]=e.L[_],e.L[S]=e.L[_+1];break}}(255&e.c[o+m])>(255&e.c[B+m])?(e.L[g]=n,g=_+1,n=e.L[g],p=m):(e.L[S]=n,S=_,n=e.L[S],d=m)}return W(e),v}function G(e){e.f=0,e.o=0,e.h=0,e.T=0,N(e),e.k=0,O(e,-1)}function W(e){var r;++e.k>=e.p&&(e.k=0),x(e),1073741823==e.o&&(r=e.o-e.p,T(e.L,2*e.p,r),T(e.ub,e.rc,r),O(e,r))}function T(e,r,t){var o,n;for(o=0;r>o;++o)n=e[o]||0,t>=n?n=0:n-=t,e[o]=n}function Z(e,r){e.qb=r>2,e.qb?(e.w=0,e.xb=4,e.R=66560):(e.w=2,e.xb=3,e.R=0)}function Y(e,r){var t,o,n,s,i,_,a,c,u,f,m,d,p,h,P,l,v;do{if(e.h>=e.o+e.ob)d=e.ob;else if(d=e.h-e.o,e.xb>d){W(e);continue}for(p=e.o>e.p?e.o-e.p:0,o=e.f+e.o,e.qb?(v=Tt[255&e.c[o]]^255&e.c[o+1],_=1023&v,e.ub[_]=e.o,v^=(255&e.c[o+2])<<8,a=65535&v,e.ub[1024+a]=e.o,c=(v^Tt[255&e.c[o+3]]<<5)&e.Ec):c=255&e.c[o]^(255&e.c[o+1])<<8,n=e.ub[e.R+c],e.ub[e.R+c]=e.o,P=(e.k<<1)+1,l=e.k<<1,f=m=e.w,t=e.Fc;;){if(p>=n||0==t--){e.L[P]=e.L[l]=0;break}if(i=e.o-n,s=(e.k>=i?e.k-i:e.k-i+e.p)<<1,h=e.f+n,u=m>f?f:m,e.c[h+u]==e.c[o+u]){for(;++u!=d&&e.c[h+u]==e.c[o+u];);if(u==d){e.L[l]=e.L[s],e.L[P]=e.L[s+1];break}}(255&e.c[o+u])>(255&e.c[h+u])?(e.L[l]=n,l=s+1,n=e.L[l],m=u):(e.L[P]=n,P=s,n=e.L[P],f=u)}W(e)}while(0!=--r)}function V(e,r,t){var o=e.o-r-1;for(0>o&&(o+=e.M);0!=t;--t)o>=e.M&&(o=0),e.Lb[e.o++]=e.Lb[o++],e.o>=e.M&&$(e)}function j(e,r){(null==e.Lb||e.M!=r)&&(e.Lb=t(r)),e.M=r,e.o=0,e.h=0}function $(e){var r=e.o-e.h;r&&(k(e.cc,e.Lb,e.h,r),e.o>=e.M&&(e.o=0),e.h=e.o)}function K(e,r){var t=e.o-r-1;return 0>t&&(t+=e.M),e.Lb[t]}function q(e,r){e.Lb[e.o++]=r,e.o>=e.M&&$(e)}function J(e){$(e),e.cc=null}function Q(e){return e-=2,4>e?e:3}function U(e){return 4>e?0:10>e?e-3:e-6}function X(e,r){return e.cb=r,e.Z=null,e.zc=1,e}function er(e,r){return e.Z=r,e.cb=null,e.zc=1,e}function rr(e){if(!e.zc)throw Error("bad state");return e.cb?or(e):tr(e),e.zc}function tr(e){var r=sr(e.Z);if(-1==r)throw Error("corrupted input");e.Pb=At,e.Pc=e.Z.g,(r||s(e.Z.Nc,Gt)>=0&&s(e.Z.g,e.Z.Nc)>=0)&&($(e.Z.B),J(e.Z.B),e.Z.e.Ab=null,e.zc=0)}function or(e){Rr(e.cb,e.cb.Xb,e.cb.uc,e.cb.Kc),e.Pb=e.cb.Xb[0],e.cb.Kc[0]&&(Or(e.cb),e.zc=0)}function nr(e,r,t,o){return e.e.Ab=r,J(e.B),e.B.cc=t,_r(e),e.U=0,e.ib=0,e.Jc=0,e.Ic=0,e.Qc=0,e.Nc=o,e.g=Gt,e.jc=0,er({},e)}function sr(e){var r,t,n,i,_,u;if(u=c(e.g)&e.Dc,vt(e.e,e.Gb,(e.U<<4)+u)){if(vt(e.e,e.Zb,e.U))n=0,vt(e.e,e.Cb,e.U)?(vt(e.e,e.Db,e.U)?(vt(e.e,e.Eb,e.U)?(t=e.Qc,e.Qc=e.Ic):t=e.Ic,e.Ic=e.Jc):t=e.Jc,e.Jc=e.ib,e.ib=t):vt(e.e,e.pb,(e.U<<4)+u)||(e.U=7>e.U?9:11,n=1),n||(n=mr(e.sb,e.e,u)+2,e.U=7>e.U?8:11);else if(e.Qc=e.Ic,e.Ic=e.Jc,e.Jc=e.ib,n=2+mr(e.Rb,e.e,u),e.U=7>e.U?7:10,_=at(e.kb[Q(n)],e.e),_>=4){if(i=(_>>1)-1,e.ib=(2|1&_)<_)e.ib+=ut(e.kc,e.ib-_-1,e.e,i);else if(e.ib+=Bt(e.e,i-4)<<4,e.ib+=ct(e.Fb,e.e),0>e.ib)return-1==e.ib?1:-1}else e.ib=_;if(s(a(e.ib),e.g)>=0||e.ib>=e.nb)return-1;V(e.B,e.ib,n),e.g=o(e.g,a(n)),e.jc=K(e.B,0)}else r=Pr(e.gb,c(e.g),e.jc),e.jc=7>e.U?vr(r,e.e):Br(r,e.e,K(e.B,e.ib)),q(e.B,e.jc),e.U=U(e.U),e.g=o(e.g,Wt);return 0}function ir(e){e.B={},e.e={},e.Gb=t(192),e.Zb=t(12),e.Cb=t(12),e.Db=t(12),e.Eb=t(12),e.pb=t(192),e.kb=t(4),e.kc=t(114),e.Fb=_t({},4),e.Rb=dr({}),e.sb=dr({}),e.gb={};for(var r=0;4>r;++r)e.kb[r]=_t({},6);return e}function _r(e){e.B.h=0,e.B.o=0,gt(e.Gb),gt(e.pb),gt(e.Zb),gt(e.Cb),gt(e.Db),gt(e.Eb),gt(e.kc),lr(e.gb);for(var r=0;4>r;++r)gt(e.kb[r].G);pr(e.Rb),pr(e.sb),gt(e.Fb.G),St(e.e)}function ar(e,r){var t,o,n,s,i,_,a;if(5>r.length)return 0;for(a=255&r[0],n=a%9,_=~~(a/9),s=_%5,i=~~(_/5),t=0,o=0;4>o;++o)t+=(255&r[1+o])<<8*o;return t>99999999||!ur(e,n,s,i)?0:cr(e,t)}function cr(e,r){return 0>r?0:(e.Ob!=r&&(e.Ob=r,e.nb=Math.max(e.Ob,1),j(e.B,Math.max(e.nb,4096))),1)}function ur(e,r,t,o){if(r>8||t>4||o>4)return 0;hr(e.gb,t,r);var n=1<e.O;++e.O)e.ec[e.O]=_t({},3),e.hc[e.O]=_t({},3)}function mr(e,r,t){if(!vt(r,e.wc,0))return at(e.ec[t],r);var o=8;return o+=vt(r,e.wc,1)?8+at(e.tc,r):at(e.hc[t],r)}function dr(e){return e.wc=t(2),e.ec=t(16),e.hc=t(16),e.tc=_t({},8),e.O=0,e}function pr(e){gt(e.wc);for(var r=0;e.O>r;++r)gt(e.ec[r].G),gt(e.hc[r].G);gt(e.tc.G)}function hr(e,r,o){var n,s;if(null==e.V||e.u!=o||e.I!=r)for(e.I=r,e.qc=(1<n;++n)e.V[n]=Sr({})}function Pr(e,r,t){return e.V[((r&e.qc)<>>8-e.u)]}function lr(e){var r,t;for(t=1<r;++r)gt(e.V[r].Ib)}function vr(e,r){var t=1;do t=t<<1|vt(r,e.Ib,t);while(256>t);return t<<24>>24}function Br(e,r,t){var o,n,s=1;do if(n=t>>7&1,t<<=1,o=vt(r,e.Ib,(1+n<<8)+s),s=s<<1|o,n!=o){for(;256>s;)s=s<<1|vt(r,e.Ib,s);break}while(256>s);return s<<24>>24}function Sr(e){return e.Ib=t(768),e}function gr(e,r){var t,o,n,s;e.jb=r,n=e.a[r].r,o=e.a[r].j;do e.a[r].t&&(st(e.a[n]),e.a[n].r=n-1,e.a[r].Ac&&(e.a[n-1].t=0,e.a[n-1].r=e.a[r].r2,e.a[n-1].j=e.a[r].j2)),s=n,t=o,o=e.a[s].j,n=e.a[s].r,e.a[s].j=t,e.a[s].r=r,r=s;while(r>0);return e.mb=e.a[0].j,e.q=e.a[0].r}function kr(e){e.l=0,e.J=0;for(var r=0;4>r;++r)e.v[r]=0}function Rr(e,r,t,n){var i,u,f,m,d,p,P,l,v,B,S,g,k,R,M;if(r[0]=Gt,t[0]=Gt,n[0]=1,e.oc&&(e.b.cc=e.oc,G(e.b),e.W=1,e.oc=null),!e.pc){if(e.pc=1,R=e.g,_(e.g,Gt)){if(!F(e.b))return void Er(e,c(e.g));xr(e),k=c(e.g)&e.y,kt(e.d,e.C,(e.l<<4)+k,0),e.l=U(e.l),f=C(e.b,-e.s),rt(Xr(e.A,c(e.g),e.J),e.d,f),e.J=f,--e.s,e.g=o(e.g,Wt)}if(!F(e.b))return void Er(e,c(e.g));for(;;){if(P=Lr(e,c(e.g)),B=e.mb,k=c(e.g)&e.y,u=(e.l<<4)+k,1==P&&-1==B)kt(e.d,e.C,u,0),f=C(e.b,-e.s),M=Xr(e.A,c(e.g),e.J),7>e.l?rt(M,e.d,f):(v=C(e.b,-e.v[0]-1-e.s),tt(M,e.d,v,f)),e.J=f,e.l=U(e.l);else{if(kt(e.d,e.C,u,1),4>B){if(kt(e.d,e.bb,e.l,1),B?(kt(e.d,e.hb,e.l,1),1==B?kt(e.d,e.Ub,e.l,0):(kt(e.d,e.Ub,e.l,1),kt(e.d,e.vc,e.l,B-2))):(kt(e.d,e.hb,e.l,0),1==P?kt(e.d,e._,u,0):kt(e.d,e._,u,1)),1==P?e.l=7>e.l?9:11:(Kr(e.i,e.d,P-2,k),e.l=7>e.l?8:11),m=e.v[B],0!=B){for(p=B;p>=1;--p)e.v[p]=e.v[p-1];e.v[0]=m}}else{for(kt(e.d,e.bb,e.l,0),e.l=7>e.l?7:10,Kr(e.$,e.d,P-2,k),B-=4,g=Tr(B),l=Q(P),mt(e.K[l],e.d,g),g>=4&&(d=(g>>1)-1,i=(2|1&g)<g?Pt(e.Sb,i-g-1,e.d,d,S):(Rt(e.d,S>>4,d-4),pt(e.S,e.d,15&S),++e.Qb)),m=B,p=3;p>=1;--p)e.v[p]=e.v[p-1];e.v[0]=m,++e.Mb}e.J=C(e.b,P-1-e.s)}if(e.s-=P,e.g=o(e.g,a(P)),!e.s){if(e.Mb>=128&&wr(e),e.Qb>=16&&br(e),r[0]=e.g,t[0]=Mt(e.d),!F(e.b))return void Er(e,c(e.g));if(s(h(e.g,R),[4096,0])>=0)return e.pc=0,void(n[0]=0)}}}}function Mr(e){var r,t;e.b||(r={},t=4,e.X||(t=2),Z(r,t),e.b=r),Ur(e.A,e.eb,e.fb),(e.ab!=e.wb||e.Hb!=e.n)&&(A(e.b,e.ab,4096,e.n,274),e.wb=e.ab,e.Hb=e.n)}function Dr(e){var r;for(e.v=t(4),e.a=[],e.d={},e.C=t(192),e.bb=t(12),e.hb=t(12),e.Ub=t(12),e.vc=t(12),e._=t(192),e.K=[],e.Sb=t(114),e.S=ft({},4),e.$=qr({}),e.i=qr({}),e.A={},e.m=[],e.P=[],e.lb=[],e.nc=t(16),e.x=t(4),e.Q=t(4),e.Xb=[Gt],e.uc=[Gt],e.Kc=[0],e.fc=t(5),e.yc=t(128),e.vb=0,e.X=1,e.D=0,e.Hb=-1,e.mb=0,r=0;4096>r;++r)e.a[r]={};for(r=0;4>r;++r)e.K[r]=ft({},6);return e}function br(e){for(var r=0;16>r;++r)e.nc[r]=ht(e.S,r);e.Qb=0}function wr(e){var r,t,o,n,s,i,_,a;for(n=4;128>n;++n)i=Tr(n),o=(i>>1)-1,r=(2|1&i)<s;++s){for(t=e.K[s],_=s<<6,i=0;e.$b>i;++i)e.P[_+i]=dt(t,i);for(i=14;e.$b>i;++i)e.P[_+i]+=(i>>1)-1-4<<6;for(a=128*s,n=0;4>n;++n)e.lb[a+n]=e.P[_+n];for(;128>n;++n)e.lb[a+n]=e.P[_+Tr(n)]+e.yc[n]}e.Mb=0}function Er(e,r){Nr(e),Wr(e,r&e.y);for(var t=0;5>t;++t)bt(e.d)}function Lr(e,r){var t,o,n,s,i,_,a,c,u,f,m,d,p,h,P,l,v,B,S,g,k,R,M,D,b,w,E,L,y,I,x,N,O,A,H,G,W,T,Z,Y,V,j,$,K,q,J,Q,X,er,rr;if(e.jb!=e.q)return p=e.a[e.q].r-e.q,e.mb=e.a[e.q].j,e.q=e.a[e.q].r,p;if(e.q=e.jb=0,e.N?(d=e.vb,e.N=0):d=xr(e),E=e.D,b=F(e.b)+1,2>b)return e.mb=-1,1;for(b>273&&(b=273),Y=0,u=0;4>u;++u)e.x[u]=e.v[u],e.Q[u]=z(e.b,-1,e.x[u],273),e.Q[u]>e.Q[Y]&&(Y=u);if(e.Q[Y]>=e.n)return e.mb=Y,p=e.Q[Y],Ir(e,p-1),p;if(d>=e.n)return e.mb=e.m[E-1]+4,Ir(e,d-1),d;if(a=C(e.b,-1),v=C(e.b,-e.v[0]-1-1),2>d&&a!=v&&2>e.Q[Y])return e.mb=-1,1;if(e.a[0].Hc=e.l,A=r&e.y,e.a[1].z=Yt[e.C[(e.l<<4)+A]>>>2]+nt(Xr(e.A,r,e.J),e.l>=7,v,a),st(e.a[1]),B=Yt[2048-e.C[(e.l<<4)+A]>>>2],Z=B+Yt[2048-e.bb[e.l]>>>2],v==a&&(V=Z+zr(e,e.l,A),e.a[1].z>V&&(e.a[1].z=V,it(e.a[1]))),m=d>=e.Q[Y]?d:e.Q[Y],2>m)return e.mb=e.a[1].j,1;e.a[1].r=0,e.a[0].bc=e.x[0],e.a[0].ac=e.x[1],e.a[0].dc=e.x[2],e.a[0].lc=e.x[3],f=m;do e.a[f--].z=268435455;while(f>=2);for(u=0;4>u;++u)if(T=e.Q[u],!(2>T)){G=Z+Cr(e,u,e.l,A);do s=G+Jr(e.i,T-2,A),x=e.a[T],x.z>s&&(x.z=s,x.r=0,x.j=u,x.t=0);while(--T>=2)}if(D=B+Yt[e.bb[e.l]>>>2],f=e.Q[0]>=2?e.Q[0]+1:2,d>=f){for(L=0;f>e.m[L];)L+=2;for(;c=e.m[L+1],s=D+yr(e,c,f,A),x=e.a[f],x.z>s&&(x.z=s,x.r=0,x.j=c+4,x.t=0),f!=e.m[L]||(L+=2,L!=E);++f);}for(t=0;;){if(++t,t==m)return gr(e,t);if(S=xr(e),E=e.D,S>=e.n)return e.vb=S,e.N=1,gr(e,t);if(++r,O=e.a[t].r,e.a[t].t?(--O,e.a[t].Ac?($=e.a[e.a[t].r2].Hc,$=4>e.a[t].j2?7>$?8:11:7>$?7:10):$=e.a[O].Hc,$=U($)):$=e.a[O].Hc,O==t-1?$=e.a[t].j?U($):7>$?9:11:(e.a[t].t&&e.a[t].Ac?(O=e.a[t].r2,N=e.a[t].j2,$=7>$?8:11):(N=e.a[t].j,$=4>N?7>$?8:11:7>$?7:10),I=e.a[O],4>N?N?1==N?(e.x[0]=I.ac,e.x[1]=I.bc,e.x[2]=I.dc,e.x[3]=I.lc):2==N?(e.x[0]=I.dc,e.x[1]=I.bc,e.x[2]=I.ac,e.x[3]=I.lc):(e.x[0]=I.lc,e.x[1]=I.bc,e.x[2]=I.ac,e.x[3]=I.dc):(e.x[0]=I.bc,e.x[1]=I.ac,e.x[2]=I.dc,e.x[3]=I.lc):(e.x[0]=N-4,e.x[1]=I.bc,e.x[2]=I.ac,e.x[3]=I.dc)),e.a[t].Hc=$,e.a[t].bc=e.x[0],e.a[t].ac=e.x[1],e.a[t].dc=e.x[2],e.a[t].lc=e.x[3],_=e.a[t].z,a=C(e.b,-1),v=C(e.b,-e.x[0]-1-1),A=r&e.y,o=_+Yt[e.C[($<<4)+A]>>>2]+nt(Xr(e.A,r,C(e.b,-2)),$>=7,v,a),R=e.a[t+1],g=0,R.z>o&&(R.z=o,R.r=t,R.j=-1,R.t=0,g=1),B=_+Yt[2048-e.C[($<<4)+A]>>>2],Z=B+Yt[2048-e.bb[$]>>>2],v!=a||t>R.r&&!R.j||(V=Z+(Yt[e.hb[$]>>>2]+Yt[e._[($<<4)+A]>>>2]),R.z>=V&&(R.z=V,R.r=t,R.j=0,R.t=0,g=1)),w=F(e.b)+1,w=w>4095-t?4095-t:w,b=w,!(2>b)){if(b>e.n&&(b=e.n),!g&&v!=a&&(q=Math.min(w-1,e.n),P=z(e.b,0,e.x[0],q),P>=2)){for(K=U($),H=r+1&e.y,M=o+Yt[2048-e.C[(K<<4)+H]>>>2]+Yt[2048-e.bb[K]>>>2],y=t+1+P;y>m;)e.a[++m].z=268435455;s=M+(J=Jr(e.i,P-2,H),J+Cr(e,0,K,H)),x=e.a[y],x.z>s&&(x.z=s,x.r=t+1,x.j=0,x.t=1,x.Ac=0)}for(j=2,W=0;4>W;++W)if(h=z(e.b,-1,e.x[W],b),!(2>h)){l=h;do{for(;t+h>m;)e.a[++m].z=268435455;s=Z+(Q=Jr(e.i,h-2,A),Q+Cr(e,W,$,A)),x=e.a[t+h],x.z>s&&(x.z=s,x.r=t,x.j=W,x.t=0)}while(--h>=2);if(h=l,W||(j=h+1),w>h&&(q=Math.min(w-1-h,e.n),P=z(e.b,h,e.x[W],q),P>=2)){for(K=7>$?8:11,H=r+h&e.y,n=Z+(X=Jr(e.i,h-2,A),X+Cr(e,W,$,A))+Yt[e.C[(K<<4)+H]>>>2]+nt(Xr(e.A,r+h,C(e.b,h-1-1)),1,C(e.b,h-1-(e.x[W]+1)),C(e.b,h-1)),K=U(K),H=r+h+1&e.y,k=n+Yt[2048-e.C[(K<<4)+H]>>>2],M=k+Yt[2048-e.bb[K]>>>2],y=h+1+P;t+y>m;)e.a[++m].z=268435455;s=M+(er=Jr(e.i,P-2,H),er+Cr(e,0,K,H)),x=e.a[t+y],x.z>s&&(x.z=s,x.r=t+h+1,x.j=0,x.t=1,x.Ac=1,x.r2=t,x.j2=W)}}if(S>b){for(S=b,E=0;S>e.m[E];E+=2);e.m[E]=S,E+=2}if(S>=j){for(D=B+Yt[e.bb[$]>>>2];t+S>m;)e.a[++m].z=268435455;for(L=0;j>e.m[L];)L+=2;for(h=j;;++h)if(i=e.m[L+1],s=D+yr(e,i,h,A),x=e.a[t+h],x.z>s&&(x.z=s,x.r=t,x.j=i+4,x.t=0),h==e.m[L]){if(w>h&&(q=Math.min(w-1-h,e.n),P=z(e.b,h,i,q),P>=2)){for(K=7>$?7:10,H=r+h&e.y,n=s+Yt[e.C[(K<<4)+H]>>>2]+nt(Xr(e.A,r+h,C(e.b,h-1-1)),1,C(e.b,h-(i+1)-1),C(e.b,h-1)),K=U(K),H=r+h+1&e.y,k=n+Yt[2048-e.C[(K<<4)+H]>>>2],M=k+Yt[2048-e.bb[K]>>>2],y=h+1+P;t+y>m;)e.a[++m].z=268435455;s=M+(rr=Jr(e.i,P-2,H),rr+Cr(e,0,K,H)),x=e.a[t+y],x.z>s&&(x.z=s,x.r=t+h+1,x.j=0,x.t=1,x.Ac=1,x.r2=t,x.j2=i+4)}if(L+=2,L==E)break}}}}}function yr(e,r,t,o){var n,s=Q(t);return n=128>r?e.lb[128*s+r]:e.P[(s<<6)+Zr(r)]+e.nc[15&r],n+Jr(e.$,t-2,o)}function Cr(e,r,t,o){var n;return r?(n=Yt[2048-e.hb[t]>>>2],1==r?n+=Yt[e.Ub[t]>>>2]:(n+=Yt[2048-e.Ub[t]>>>2],n+=wt(e.vc[t],r-2))):(n=Yt[e.hb[t]>>>2],n+=Yt[2048-e._[(t<<4)+o]>>>2]),n}function zr(e,r,t){return Yt[e.hb[r]>>>2]+Yt[e._[(r<<4)+t]>>>2]}function Fr(e){kr(e),Dt(e.d),gt(e.C),gt(e._),gt(e.bb),gt(e.hb),gt(e.Ub),gt(e.vc),gt(e.Sb),et(e.A);for(var r=0;4>r;++r)gt(e.K[r].G);jr(e.$,1<0&&(Y(e.b,r),e.s+=r)}function xr(e){var r=0;return e.D=H(e.b,e.m),e.D>0&&(r=e.m[e.D-2],r==e.n&&(r+=z(e.b,r-1,e.m[e.D-1],273-r))),++e.s,r}function Nr(e){e.b&&e.W&&(e.b.cc=null,e.W=0)}function Or(e){Nr(e),e.d.Ab=null}function Ar(e,r){e.ab=r;for(var t=0;r>1<>24;for(var t=0;4>t;++t)e.fc[1+t]=e.ab>>8*t<<24>>24;k(r,e.fc,0,5)}function Wr(e,r){if(e.Gc){kt(e.d,e.C,(e.l<<4)+r,1),kt(e.d,e.bb,e.l,0),e.l=7>e.l?7:10,Kr(e.$,e.d,0,r);var t=Q(2);mt(e.K[t],e.d,63),Rt(e.d,67108863,26),pt(e.S,e.d,15)}}function Tr(e){return 2048>e?Zt[e]:2097152>e?Zt[e>>10]+20:Zt[e>>20]+40}function Zr(e){return 131072>e?Zt[e>>6]+12:134217728>e?Zt[e>>16]+32:Zt[e>>26]+52}function Yr(e,r,t,o){8>t?(kt(r,e.db,0,0),mt(e.Vb[o],r,t)):(t-=8,kt(r,e.db,0,1),8>t?(kt(r,e.db,1,0),mt(e.Wb[o],r,t)):(kt(r,e.db,1,1),mt(e.ic,r,t-8)))}function Vr(e){e.db=t(2),e.Vb=t(16),e.Wb=t(16),e.ic=ft({},8);for(var r=0;16>r;++r)e.Vb[r]=ft({},3),e.Wb[r]=ft({},3);return e}function jr(e,r){gt(e.db);for(var t=0;r>t;++t)gt(e.Vb[t].G),gt(e.Wb[t].G);gt(e.ic.G)}function $r(e,r,t,o,n){var s,i,_,a,c;for(s=Yt[e.db[0]>>>2],i=Yt[2048-e.db[0]>>>2],_=i+Yt[e.db[1]>>>2],a=i+Yt[2048-e.db[1]>>>2],c=0,c=0;8>c;++c){if(c>=t)return;o[n+c]=s+dt(e.Vb[r],c)}for(;16>c;++c){if(c>=t)return;o[n+c]=_+dt(e.Wb[r],c-8)}for(;t>c;++c)o[n+c]=a+dt(e.ic,c-8-8)}function Kr(e,r,t,o){Yr(e,r,t,o),0==--e.sc[o]&&($r(e,o,e.rb,e.Cc,272*o),e.sc[o]=e.rb)}function qr(e){return Vr(e),e.Cc=[],e.sc=[],e}function Jr(e,r,t){return e.Cc[272*t+r]}function Qr(e,r){for(var t=0;r>t;++t)$r(e,t,e.rb,e.Cc,272*t),e.sc[t]=e.rb}function Ur(e,r,o){var n,s;if(null==e.V||e.u!=o||e.I!=r)for(e.I=r,e.qc=(1<n;++n)e.V[n]=ot({})}function Xr(e,r,t){return e.V[((r&e.qc)<>>8-e.u)]}function et(e){var r,t=1<r;++r)gt(e.V[r].tb)}function rt(e,r,t){var o,n,s=1;for(n=7;n>=0;--n)o=t>>n&1,kt(r,e.tb,s,o),s=s<<1|o}function tt(e,r,t,o){var n,s,i,_,a=1,c=1;for(s=7;s>=0;--s)n=o>>s&1,_=c,a&&(i=t>>s&1,_+=1+i<<8,a=i==n),kt(r,e.tb,_,n),c=c<<1|n}function ot(e){return e.tb=t(768),e}function nt(e,r,t,o){var n,s,i=1,_=7,a=0;if(r)for(;_>=0;--_)if(s=t>>_&1,n=o>>_&1,a+=wt(e.tb[(1+s<<8)+i],n),i=i<<1|n,s!=n){--_;break}for(;_>=0;--_)n=o>>_&1,a+=wt(e.tb[i],n),i=i<<1|n;return a}function st(e){e.j=-1,e.t=0}function it(e){e.j=0,e.t=0}function _t(e,r){return e.F=r,e.G=t(1<o;++o)t=vt(r,e.G,n),n<<=1,n+=t,s|=t<s;++s)n=vt(t,e,r+i),i<<=1,i+=n,_|=n<>>n&1,kt(r,e.G,s,o),s=s<<1|o}function dt(e,r){var t,o,n=1,s=0;for(o=e.F;0!=o;)--o,t=r>>>o&1,s+=wt(e.G[n],t),n=(n<<1)+t;return s}function pt(e,r,t){var o,n,s=1;for(n=0;e.F>n;++n)o=1&t,kt(r,e.G,s,o),s=s<<1|o,t>>=1}function ht(e,r){var t,o,n=1,s=0;for(o=e.F;0!=o;--o)t=1&r,r>>>=1,s+=wt(e.G[n],t),n=n<<1|t;return s}function Pt(e,r,t,o,n){var s,i,_=1;for(i=0;o>i;++i)s=1&n,kt(t,e,r+_,s),_=_<<1|s,n>>=1}function lt(e,r,t,o){var n,s,i=1,_=0;for(s=t;0!=s;--s)n=1&o,o>>>=1,_+=Yt[(2047&(e[r+i]-n^-n))>>>2],i=i<<1|n;return _}function vt(e,r,t){var o,n=r[t];return o=(e.E>>>11)*n,(-2147483648^o)>(-2147483648^e.Bb)?(e.E=o,r[t]=n+(2048-n>>>5)<<16>>16,-16777216&e.E||(e.Bb=e.Bb<<8|l(e.Ab),e.E<<=8),0):(e.E-=o,e.Bb-=o,r[t]=n-(n>>>5)<<16>>16,-16777216&e.E||(e.Bb=e.Bb<<8|l(e.Ab),e.E<<=8),1)}function Bt(e,r){var t,o,n=0;for(t=r;0!=t;--t)e.E>>>=1,o=e.Bb-e.E>>>31,e.Bb-=e.E&o-1,n=n<<1|1-o,-16777216&e.E||(e.Bb=e.Bb<<8|l(e.Ab),e.E<<=8);return n}function St(e){e.Bb=0,e.E=-1;for(var r=0;5>r;++r)e.Bb=e.Bb<<8|l(e.Ab)}function gt(e){for(var r=e.length-1;r>=0;--r)e[r]=1024}function kt(e,r,t,s){var i,_=r[t];i=(e.E>>>11)*_,s?(e.xc=o(e.xc,n(a(i),[4294967295,0])),e.E-=i,r[t]=_-(_>>>5)<<16>>16):(e.E=i,r[t]=_+(2048-_>>>5)<<16>>16),-16777216&e.E||(e.E<<=8,bt(e))}function Rt(e,r,t){for(var n=t-1;n>=0;--n)e.E>>>=1,1==(r>>>n&1)&&(e.xc=o(e.xc,a(e.E))),-16777216&e.E||(e.E<<=8,bt(e))}function Mt(e){return o(o(a(e.Jb),e.mc),[4,0])}function Dt(e){e.mc=Gt,e.xc=Gt,e.E=-1,e.Jb=1,e.Oc=0}function bt(e){var r,t=c(p(e.xc,32));if(0!=t||s(e.xc,[4278190080,0])<0){e.mc=o(e.mc,a(e.Jb)),r=e.Oc;do g(e.Ab,r+t),r=255;while(0!=--e.Jb);e.Oc=c(e.xc)>>>24}++e.Jb,e.xc=m(n(e.xc,[16777215,0]),8)}function wt(e,r){return Yt[(2047&(e-r^-r))>>>2]}function Et(e){for(var r,t,o,n=0,s=0,i=e.length,_=[],a=[];i>n;++n,++s){if(r=255&e[n],128&r)if(192==(224&r)){if(n+1>=i)return e;if(t=255&e[++n],128!=(192&t))return e;a[s]=(31&r)<<6|63&t}else{if(224!=(240&r))return e;
if(n+2>=i)return e;if(t=255&e[++n],128!=(192&t))return e;if(o=255&e[++n],128!=(192&o))return e;a[s]=(15&r)<<12|(63&t)<<6|63&o}else{if(!r)return e;a[s]=r}16383==s&&(_.push(String.fromCharCode.apply(String,a)),s=-1)}return s>0&&(a.length=s,_.push(String.fromCharCode.apply(String,a))),_.join("")}function Lt(e){var r,t,o,n=[],s=0,i=e.length;if("object"==typeof e)return e;for(R(e,0,i,n,0),o=0;i>o;++o)r=n[o],r>=1&&127>=r?++s:s+=!r||r>=128&&2047>=r?2:3;for(t=[],s=0,o=0;i>o;++o)r=n[o],r>=1&&127>=r?t[s++]=r<<24>>24:!r||r>=128&&2047>=r?(t[s++]=(192|r>>6&31)<<24>>24,t[s++]=(128|63&r)<<24>>24):(t[s++]=(224|r>>12&15)<<24>>24,t[s++]=(128|r>>6&63)<<24>>24,t[s++]=(128|63&r)<<24>>24);return t}function yt(e){return e[1]+e[0]}function Ct(e,t,o,n){function s(){try{for(var e,r=(new Date).getTime();rr(a.c.yb);)if(i=yt(a.c.yb.Pb)/yt(a.c.Tb),(new Date).getTime()-r>200)return n(i),Nt(s,0),0;n(1),e=S(a.c.Nb),Nt(o.bind(null,e),0)}catch(t){o(null,t)}}var i,_,a={},c=void 0===o&&void 0===n;if("function"!=typeof o&&(_=o,o=n=0),n=n||function(e){return void 0!==_?r(e,_):void 0},o=o||function(e,r){return void 0!==_?postMessage({action:Ft,cbn:_,result:e,error:r}):void 0},c){for(a.c=w({},Lt(e),Vt(t));rr(a.c.yb););return S(a.c.Nb)}try{a.c=w({},Lt(e),Vt(t)),n(0)}catch(u){return o(null,u)}Nt(s,0)}function zt(e,t,o){function n(){try{for(var e,r=0,i=(new Date).getTime();rr(c.d.yb);)if(++r%1e3==0&&(new Date).getTime()-i>200)return _&&(s=yt(c.d.yb.Z.g)/a,o(s)),Nt(n,0),0;o(1),e=Et(S(c.d.Nb)),Nt(t.bind(null,e),0)}catch(u){t(null,u)}}var s,i,_,a,c={},u=void 0===t&&void 0===o;if("function"!=typeof t&&(i=t,t=o=0),o=o||function(e){return void 0!==i?r(_?e:-1,i):void 0},t=t||function(e,r){return void 0!==i?postMessage({action:It,cbn:i,result:e,error:r}):void 0},u){for(c.d=L({},e);rr(c.d.yb););return Et(S(c.d.Nb))}try{c.d=L({},e),a=yt(c.d.Tb),_=a>-1,o(0)}catch(f){return t(null,f)}Nt(n,0)}var Ft=1,It=2,xt=3,Nt="function"==typeof setImmediate?setImmediate:setTimeout,Ot=4294967296,At=[4294967295,-Ot],Ht=[0,-0x8000000000000000],Gt=[0,0],Wt=[1,0],Tt=function(){var e,r,t,o=[];for(e=0;256>e;++e){for(t=e,r=0;8>r;++r)0!=(1&t)?t=t>>>1^-306674912:t>>>=1;o[e]=t}return o}(),Zt=function(){var e,r,t,o=2,n=[0,1];for(t=2;22>t;++t)for(r=1<<(t>>1)-1,e=0;r>e;++e,++o)n[o]=t<<24>>24;return n}(),Yt=function(){var e,r,t,o,n=[];for(r=8;r>=0;--r)for(o=1<<9-r-1,e=1<<9-r,t=o;e>t;++t)n[t]=(r<<6)+(e-t<<6>>>9-r-1);return n}(),Vt=function(){var e=[{s:16,f:64,m:0},{s:20,f:64,m:0},{s:19,f:64,m:1},{s:20,f:64,m:1},{s:21,f:128,m:1},{s:22,f:128,m:1},{s:23,f:128,m:1},{s:24,f:255,m:1},{s:25,f:255,m:1}];return function(r){return e[r-1]||e[6]}}();return"undefined"==typeof onmessage||"undefined"!=typeof window&&void 0!==window.document||!function(){onmessage=function(r){r&&r.gc&&(r.gc.action==It?e.decompress(r.gc.gc,r.gc.cbn):r.gc.action==Ft&&e.compress(r.gc.gc,r.gc.Rc,r.gc.cbn))}}(),{compress:Ct,decompress:zt}}();this.LZMA=this.LZMA_WORKER=e;
================================================
FILE: dependencies/webgl-debug.js
================================================
/*
** Copyright (c) 2012 The Khronos Group Inc.
**
** Permission is hereby granted, free of charge, to any person obtaining a
** copy of this software and/or associated documentation files (the
** "Materials"), to deal in the Materials without restriction, including
** without limitation the rights to use, copy, modify, merge, publish,
** distribute, sublicense, and/or sell copies of the Materials, and to
** permit persons to whom the Materials are furnished to do so, subject to
** the following conditions:
**
** The above copyright notice and this permission notice shall be included
** in all copies or substantial portions of the Materials.
**
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
*/
// Various functions for helping debug WebGL apps.
WebGLDebugUtils = function() {
/**
* Wrapped logging function.
* @param {string} msg Message to log.
*/
var log = function(msg) {
if (window.console && window.console.log) {
window.console.log(msg);
}
};
/**
* Wrapped error logging function.
* @param {string} msg Message to log.
*/
var error = function(msg) {
if (window.console && window.console.error) {
window.console.error(msg);
} else {
log(msg);
}
};
/**
* Which arguments are enums based on the number of arguments to the function.
* So
* 'texImage2D': {
* 9: { 0:true, 2:true, 6:true, 7:true },
* 6: { 0:true, 2:true, 3:true, 4:true },
* },
*
* means if there are 9 arguments then 6 and 7 are enums, if there are 6
* arguments 3 and 4 are enums
*
* @type {!Object.}
*/
var glValidEnumContexts = {
// Generic setters and getters
'enable': {1: { 0:true }},
'disable': {1: { 0:true }},
'getParameter': {1: { 0:true }},
// Rendering
'drawArrays': {3:{ 0:true }},
'drawElements': {4:{ 0:true, 2:true }},
// Shaders
'createShader': {1: { 0:true }},
'getShaderParameter': {2: { 1:true }},
'getProgramParameter': {2: { 1:true }},
'getShaderPrecisionFormat': {2: { 0: true, 1:true }},
// Vertex attributes
'getVertexAttrib': {2: { 1:true }},
'vertexAttribPointer': {6: { 2:true }},
// Textures
'bindTexture': {2: { 0:true }},
'activeTexture': {1: { 0:true }},
'getTexParameter': {2: { 0:true, 1:true }},
'texParameterf': {3: { 0:true, 1:true }},
'texParameteri': {3: { 0:true, 1:true, 2:true }},
'texImage2D': {
9: { 0:true, 2:true, 6:true, 7:true },
6: { 0:true, 2:true, 3:true, 4:true }
},
'texSubImage2D': {
9: { 0:true, 6:true, 7:true },
7: { 0:true, 4:true, 5:true }
},
'copyTexImage2D': {8: { 0:true, 2:true }},
'copyTexSubImage2D': {8: { 0:true }},
'generateMipmap': {1: { 0:true }},
'compressedTexImage2D': {7: { 0: true, 2:true }},
'compressedTexSubImage2D': {8: { 0: true, 6:true }},
// Buffer objects
'bindBuffer': {2: { 0:true }},
'bufferData': {3: { 0:true, 2:true }},
'bufferSubData': {3: { 0:true }},
'getBufferParameter': {2: { 0:true, 1:true }},
// Renderbuffers and framebuffers
'pixelStorei': {2: { 0:true, 1:true }},
'readPixels': {7: { 4:true, 5:true }},
'bindRenderbuffer': {2: { 0:true }},
'bindFramebuffer': {2: { 0:true }},
'checkFramebufferStatus': {1: { 0:true }},
'framebufferRenderbuffer': {4: { 0:true, 1:true, 2:true }},
'framebufferTexture2D': {5: { 0:true, 1:true, 2:true }},
'getFramebufferAttachmentParameter': {3: { 0:true, 1:true, 2:true }},
'getRenderbufferParameter': {2: { 0:true, 1:true }},
'renderbufferStorage': {4: { 0:true, 1:true }},
// Frame buffer operations (clear, blend, depth test, stencil)
'clear': {1: { 0: { 'enumBitwiseOr': ['COLOR_BUFFER_BIT', 'DEPTH_BUFFER_BIT', 'STENCIL_BUFFER_BIT'] }}},
'depthFunc': {1: { 0:true }},
'blendFunc': {2: { 0:true, 1:true }},
'blendFuncSeparate': {4: { 0:true, 1:true, 2:true, 3:true }},
'blendEquation': {1: { 0:true }},
'blendEquationSeparate': {2: { 0:true, 1:true }},
'stencilFunc': {3: { 0:true }},
'stencilFuncSeparate': {4: { 0:true, 1:true }},
'stencilMaskSeparate': {2: { 0:true }},
'stencilOp': {3: { 0:true, 1:true, 2:true }},
'stencilOpSeparate': {4: { 0:true, 1:true, 2:true, 3:true }},
// Culling
'cullFace': {1: { 0:true }},
'frontFace': {1: { 0:true }},
// ANGLE_instanced_arrays extension
'drawArraysInstancedANGLE': {4: { 0:true }},
'drawElementsInstancedANGLE': {5: { 0:true, 2:true }},
// EXT_blend_minmax extension
'blendEquationEXT': {1: { 0:true }}
};
/**
* Map of numbers to names.
* @type {Object}
*/
var glEnums = null;
/**
* Map of names to numbers.
* @type {Object}
*/
var enumStringToValue = null;
/**
* Initializes this module. Safe to call more than once.
* @param {!WebGLRenderingContext} ctx A WebGL context. If
* you have more than one context it doesn't matter which one
* you pass in, it is only used to pull out constants.
*/
function init(ctx) {
if (glEnums == null) {
glEnums = { };
enumStringToValue = { };
for (var propertyName in ctx) {
if (typeof ctx[propertyName] == 'number') {
glEnums[ctx[propertyName]] = propertyName;
enumStringToValue[propertyName] = ctx[propertyName];
}
}
}
}
/**
* Checks the utils have been initialized.
*/
function checkInit() {
if (glEnums == null) {
throw 'WebGLDebugUtils.init(ctx) not called';
}
}
/**
* Returns true or false if value matches any WebGL enum
* @param {*} value Value to check if it might be an enum.
* @return {boolean} True if value matches one of the WebGL defined enums
*/
function mightBeEnum(value) {
checkInit();
return (glEnums[value] !== undefined);
}
/**
* Gets an string version of an WebGL enum.
*
* Example:
* var str = WebGLDebugUtil.glEnumToString(ctx.getError());
*
* @param {number} value Value to return an enum for
* @return {string} The string version of the enum.
*/
function glEnumToString(value) {
checkInit();
var name = glEnums[value];
return (name !== undefined) ? ("gl." + name) :
("/*UNKNOWN WebGL ENUM*/ 0x" + value.toString(16) + "");
}
/**
* Returns the string version of a WebGL argument.
* Attempts to convert enum arguments to strings.
* @param {string} functionName the name of the WebGL function.
* @param {number} numArgs the number of arguments passed to the function.
* @param {number} argumentIndx the index of the argument.
* @param {*} value The value of the argument.
* @return {string} The value as a string.
*/
function glFunctionArgToString(functionName, numArgs, argumentIndex, value) {
var funcInfo = glValidEnumContexts[functionName];
if (funcInfo !== undefined) {
var funcInfo = funcInfo[numArgs];
if (funcInfo !== undefined) {
if (funcInfo[argumentIndex]) {
if (typeof funcInfo[argumentIndex] === 'object' &&
funcInfo[argumentIndex]['enumBitwiseOr'] !== undefined) {
var enums = funcInfo[argumentIndex]['enumBitwiseOr'];
var orResult = 0;
var orEnums = [];
for (var i = 0; i < enums.length; ++i) {
var enumValue = enumStringToValue[enums[i]];
if ((value & enumValue) !== 0) {
orResult |= enumValue;
orEnums.push(glEnumToString(enumValue));
}
}
if (orResult === value) {
return orEnums.join(' | ');
} else {
return glEnumToString(value);
}
} else {
return glEnumToString(value);
}
}
}
}
if (value === null) {
return "null";
} else if (value === undefined) {
return "undefined";
} else {
return value.toString();
}
}
/**
* Converts the arguments of a WebGL function to a string.
* Attempts to convert enum arguments to strings.
*
* @param {string} functionName the name of the WebGL function.
* @param {number} args The arguments.
* @return {string} The arguments as a string.
*/
function glFunctionArgsToString(functionName, args) {
// apparently we can't do args.join(",");
var argStr = "";
var numArgs = args.length;
for (var ii = 0; ii < numArgs; ++ii) {
argStr += ((ii == 0) ? '' : ', ') +
glFunctionArgToString(functionName, numArgs, ii, args[ii]);
}
return argStr;
};
function makePropertyWrapper(wrapper, original, propertyName) {
//log("wrap prop: " + propertyName);
wrapper.__defineGetter__(propertyName, function() {
return original[propertyName];
});
// TODO(gmane): this needs to handle properties that take more than
// one value?
wrapper.__defineSetter__(propertyName, function(value) {
//log("set: " + propertyName);
original[propertyName] = value;
});
}
// Makes a function that calls a function on another object.
function makeFunctionWrapper(original, functionName) {
//log("wrap fn: " + functionName);
var f = original[functionName];
return function() {
//log("call: " + functionName);
var result = f.apply(original, arguments);
return result;
};
}
/**
* Given a WebGL context returns a wrapped context that calls
* gl.getError after every command and calls a function if the
* result is not gl.NO_ERROR.
*
* @param {!WebGLRenderingContext} ctx The webgl context to
* wrap.
* @param {!function(err, funcName, args): void} opt_onErrorFunc
* The function to call when gl.getError returns an
* error. If not specified the default function calls
* console.log with a message.
* @param {!function(funcName, args): void} opt_onFunc The
* function to call when each webgl function is called.
* You can use this to log all calls for example.
* @param {!WebGLRenderingContext} opt_err_ctx The webgl context
* to call getError on if different than ctx.
*/
function makeDebugContext(ctx, opt_onErrorFunc, opt_onFunc, opt_err_ctx) {
opt_err_ctx = opt_err_ctx || ctx;
init(ctx);
opt_onErrorFunc = opt_onErrorFunc || function(err, functionName, args) {
// apparently we can't do args.join(",");
var argStr = "";
var numArgs = args.length;
for (var ii = 0; ii < numArgs; ++ii) {
argStr += ((ii == 0) ? '' : ', ') +
glFunctionArgToString(functionName, numArgs, ii, args[ii]);
}
error("WebGL error "+ glEnumToString(err) + " in "+ functionName +
"(" + argStr + ")");
};
// Holds booleans for each GL error so after we get the error ourselves
// we can still return it to the client app.
var glErrorShadow = { };
// Makes a function that calls a WebGL function and then calls getError.
function makeErrorWrapper(ctx, functionName) {
return function() {
if (opt_onFunc) {
opt_onFunc(functionName, arguments);
}
var result = ctx[functionName].apply(ctx, arguments);
var err = opt_err_ctx.getError();
if (err != 0) {
glErrorShadow[err] = true;
opt_onErrorFunc(err, functionName, arguments);
}
return result;
};
}
// Make a an object that has a copy of every property of the WebGL context
// but wraps all functions.
var wrapper = {};
for (var propertyName in ctx) {
if (typeof ctx[propertyName] == 'function') {
if (propertyName != 'getExtension') {
wrapper[propertyName] = makeErrorWrapper(ctx, propertyName);
} else {
var wrapped = makeErrorWrapper(ctx, propertyName);
wrapper[propertyName] = function () {
var result = wrapped.apply(ctx, arguments);
return makeDebugContext(result, opt_onErrorFunc, opt_onFunc, opt_err_ctx);
};
}
} else {
makePropertyWrapper(wrapper, ctx, propertyName);
}
}
// Override the getError function with one that returns our saved results.
wrapper.getError = function() {
for (var err in glErrorShadow) {
if (glErrorShadow.hasOwnProperty(err)) {
if (glErrorShadow[err]) {
glErrorShadow[err] = false;
return err;
}
}
}
return ctx.NO_ERROR;
};
return wrapper;
}
function resetToInitialState(ctx) {
var numAttribs = ctx.getParameter(ctx.MAX_VERTEX_ATTRIBS);
var tmp = ctx.createBuffer();
ctx.bindBuffer(ctx.ARRAY_BUFFER, tmp);
for (var ii = 0; ii < numAttribs; ++ii) {
ctx.disableVertexAttribArray(ii);
ctx.vertexAttribPointer(ii, 4, ctx.FLOAT, false, 0, 0);
ctx.vertexAttrib1f(ii, 0);
}
ctx.deleteBuffer(tmp);
var numTextureUnits = ctx.getParameter(ctx.MAX_TEXTURE_IMAGE_UNITS);
for (var ii = 0; ii < numTextureUnits; ++ii) {
ctx.activeTexture(ctx.TEXTURE0 + ii);
ctx.bindTexture(ctx.TEXTURE_CUBE_MAP, null);
ctx.bindTexture(ctx.TEXTURE_2D, null);
}
ctx.activeTexture(ctx.TEXTURE0);
ctx.useProgram(null);
ctx.bindBuffer(ctx.ARRAY_BUFFER, null);
ctx.bindBuffer(ctx.ELEMENT_ARRAY_BUFFER, null);
ctx.bindFramebuffer(ctx.FRAMEBUFFER, null);
ctx.bindRenderbuffer(ctx.RENDERBUFFER, null);
ctx.disable(ctx.BLEND);
ctx.disable(ctx.CULL_FACE);
ctx.disable(ctx.DEPTH_TEST);
ctx.disable(ctx.DITHER);
ctx.disable(ctx.SCISSOR_TEST);
ctx.blendColor(0, 0, 0, 0);
ctx.blendEquation(ctx.FUNC_ADD);
ctx.blendFunc(ctx.ONE, ctx.ZERO);
ctx.clearColor(0, 0, 0, 0);
ctx.clearDepth(1);
ctx.clearStencil(-1);
ctx.colorMask(true, true, true, true);
ctx.cullFace(ctx.BACK);
ctx.depthFunc(ctx.LESS);
ctx.depthMask(true);
ctx.depthRange(0, 1);
ctx.frontFace(ctx.CCW);
ctx.hint(ctx.GENERATE_MIPMAP_HINT, ctx.DONT_CARE);
ctx.lineWidth(1);
ctx.pixelStorei(ctx.PACK_ALIGNMENT, 4);
ctx.pixelStorei(ctx.UNPACK_ALIGNMENT, 4);
ctx.pixelStorei(ctx.UNPACK_FLIP_Y_WEBGL, false);
ctx.pixelStorei(ctx.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
// TODO: Delete this IF.
if (ctx.UNPACK_COLORSPACE_CONVERSION_WEBGL) {
ctx.pixelStorei(ctx.UNPACK_COLORSPACE_CONVERSION_WEBGL, ctx.BROWSER_DEFAULT_WEBGL);
}
ctx.polygonOffset(0, 0);
ctx.sampleCoverage(1, false);
ctx.scissor(0, 0, ctx.canvas.width, ctx.canvas.height);
ctx.stencilFunc(ctx.ALWAYS, 0, 0xFFFFFFFF);
ctx.stencilMask(0xFFFFFFFF);
ctx.stencilOp(ctx.KEEP, ctx.KEEP, ctx.KEEP);
ctx.viewport(0, 0, ctx.canvas.width, ctx.canvas.height);
ctx.clear(ctx.COLOR_BUFFER_BIT | ctx.DEPTH_BUFFER_BIT | ctx.STENCIL_BUFFER_BIT);
// TODO: This should NOT be needed but Firefox fails with 'hint'
while(ctx.getError());
}
function makeLostContextSimulatingCanvas(canvas) {
var unwrappedContext_;
var wrappedContext_;
var onLost_ = [];
var onRestored_ = [];
var wrappedContext_ = {};
var contextId_ = 1;
var contextLost_ = false;
var resourceId_ = 0;
var resourceDb_ = [];
var numCallsToLoseContext_ = 0;
var numCalls_ = 0;
var canRestore_ = false;
var restoreTimeout_ = 0;
// Holds booleans for each GL error so can simulate errors.
var glErrorShadow_ = { };
canvas.getContext = function(f) {
return function() {
var ctx = f.apply(canvas, arguments);
// Did we get a context and is it a WebGL context?
if (ctx instanceof WebGLRenderingContext) {
if (ctx != unwrappedContext_) {
if (unwrappedContext_) {
throw "got different context"
}
unwrappedContext_ = ctx;
wrappedContext_ = makeLostContextSimulatingContext(unwrappedContext_);
}
return wrappedContext_;
}
return ctx;
}
}(canvas.getContext);
function wrapEvent(listener) {
if (typeof(listener) == "function") {
return listener;
} else {
return function(info) {
listener.handleEvent(info);
}
}
}
var addOnContextLostListener = function(listener) {
onLost_.push(wrapEvent(listener));
};
var addOnContextRestoredListener = function(listener) {
onRestored_.push(wrapEvent(listener));
};
function wrapAddEventListener(canvas) {
var f = canvas.addEventListener;
canvas.addEventListener = function(type, listener, bubble) {
switch (type) {
case 'webglcontextlost':
addOnContextLostListener(listener);
break;
case 'webglcontextrestored':
addOnContextRestoredListener(listener);
break;
default:
f.apply(canvas, arguments);
}
};
}
wrapAddEventListener(canvas);
canvas.loseContext = function() {
if (!contextLost_) {
contextLost_ = true;
numCallsToLoseContext_ = 0;
++contextId_;
while (unwrappedContext_.getError());
clearErrors();
glErrorShadow_[unwrappedContext_.CONTEXT_LOST_WEBGL] = true;
var event = makeWebGLContextEvent("context lost");
var callbacks = onLost_.slice();
setTimeout(function() {
//log("numCallbacks:" + callbacks.length);
for (var ii = 0; ii < callbacks.length; ++ii) {
//log("calling callback:" + ii);
callbacks[ii](event);
}
if (restoreTimeout_ >= 0) {
setTimeout(function() {
canvas.restoreContext();
}, restoreTimeout_);
}
}, 0);
}
};
canvas.restoreContext = function() {
if (contextLost_) {
if (onRestored_.length) {
setTimeout(function() {
if (!canRestore_) {
throw "can not restore. webglcontestlost listener did not call event.preventDefault";
}
freeResources();
resetToInitialState(unwrappedContext_);
contextLost_ = false;
numCalls_ = 0;
canRestore_ = false;
var callbacks = onRestored_.slice();
var event = makeWebGLContextEvent("context restored");
for (var ii = 0; ii < callbacks.length; ++ii) {
callbacks[ii](event);
}
}, 0);
}
}
};
canvas.loseContextInNCalls = function(numCalls) {
if (contextLost_) {
throw "You can not ask a lost contet to be lost";
}
numCallsToLoseContext_ = numCalls_ + numCalls;
};
canvas.getNumCalls = function() {
return numCalls_;
};
canvas.setRestoreTimeout = function(timeout) {
restoreTimeout_ = timeout;
};
function isWebGLObject(obj) {
//return false;
return (obj instanceof WebGLBuffer ||
obj instanceof WebGLFramebuffer ||
obj instanceof WebGLProgram ||
obj instanceof WebGLRenderbuffer ||
obj instanceof WebGLShader ||
obj instanceof WebGLTexture);
}
function checkResources(args) {
for (var ii = 0; ii < args.length; ++ii) {
var arg = args[ii];
if (isWebGLObject(arg)) {
return arg.__webglDebugContextLostId__ == contextId_;
}
}
return true;
}
function clearErrors() {
var k = Object.keys(glErrorShadow_);
for (var ii = 0; ii < k.length; ++ii) {
delete glErrorShadow_[k];
}
}
function loseContextIfTime() {
++numCalls_;
if (!contextLost_) {
if (numCallsToLoseContext_ == numCalls_) {
canvas.loseContext();
}
}
}
// Makes a function that simulates WebGL when out of context.
function makeLostContextFunctionWrapper(ctx, functionName) {
var f = ctx[functionName];
return function() {
// log("calling:" + functionName);
// Only call the functions if the context is not lost.
loseContextIfTime();
if (!contextLost_) {
//if (!checkResources(arguments)) {
// glErrorShadow_[wrappedContext_.INVALID_OPERATION] = true;
// return;
//}
var result = f.apply(ctx, arguments);
return result;
}
};
}
function freeResources() {
for (var ii = 0; ii < resourceDb_.length; ++ii) {
var resource = resourceDb_[ii];
if (resource instanceof WebGLBuffer) {
unwrappedContext_.deleteBuffer(resource);
} else if (resource instanceof WebGLFramebuffer) {
unwrappedContext_.deleteFramebuffer(resource);
} else if (resource instanceof WebGLProgram) {
unwrappedContext_.deleteProgram(resource);
} else if (resource instanceof WebGLRenderbuffer) {
unwrappedContext_.deleteRenderbuffer(resource);
} else if (resource instanceof WebGLShader) {
unwrappedContext_.deleteShader(resource);
} else if (resource instanceof WebGLTexture) {
unwrappedContext_.deleteTexture(resource);
}
}
}
function makeWebGLContextEvent(statusMessage) {
return {
statusMessage: statusMessage,
preventDefault: function() {
canRestore_ = true;
}
};
}
return canvas;
function makeLostContextSimulatingContext(ctx) {
// copy all functions and properties to wrapper
for (var propertyName in ctx) {
if (typeof ctx[propertyName] == 'function') {
wrappedContext_[propertyName] = makeLostContextFunctionWrapper(
ctx, propertyName);
} else {
makePropertyWrapper(wrappedContext_, ctx, propertyName);
}
}
// Wrap a few functions specially.
wrappedContext_.getError = function() {
loseContextIfTime();
if (!contextLost_) {
var err;
while (err = unwrappedContext_.getError()) {
glErrorShadow_[err] = true;
}
}
for (var err in glErrorShadow_) {
if (glErrorShadow_[err]) {
delete glErrorShadow_[err];
return err;
}
}
return wrappedContext_.NO_ERROR;
};
var creationFunctions = [
"createBuffer",
"createFramebuffer",
"createProgram",
"createRenderbuffer",
"createShader",
"createTexture"
];
for (var ii = 0; ii < creationFunctions.length; ++ii) {
var functionName = creationFunctions[ii];
wrappedContext_[functionName] = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return null;
}
var obj = f.apply(ctx, arguments);
obj.__webglDebugContextLostId__ = contextId_;
resourceDb_.push(obj);
return obj;
};
}(ctx[functionName]);
}
var functionsThatShouldReturnNull = [
"getActiveAttrib",
"getActiveUniform",
"getBufferParameter",
"getContextAttributes",
"getAttachedShaders",
"getFramebufferAttachmentParameter",
"getParameter",
"getProgramParameter",
"getProgramInfoLog",
"getRenderbufferParameter",
"getShaderParameter",
"getShaderInfoLog",
"getShaderSource",
"getTexParameter",
"getUniform",
"getUniformLocation",
"getVertexAttrib"
];
for (var ii = 0; ii < functionsThatShouldReturnNull.length; ++ii) {
var functionName = functionsThatShouldReturnNull[ii];
wrappedContext_[functionName] = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return null;
}
return f.apply(ctx, arguments);
}
}(wrappedContext_[functionName]);
}
var isFunctions = [
"isBuffer",
"isEnabled",
"isFramebuffer",
"isProgram",
"isRenderbuffer",
"isShader",
"isTexture"
];
for (var ii = 0; ii < isFunctions.length; ++ii) {
var functionName = isFunctions[ii];
wrappedContext_[functionName] = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return false;
}
return f.apply(ctx, arguments);
}
}(wrappedContext_[functionName]);
}
wrappedContext_.checkFramebufferStatus = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return wrappedContext_.FRAMEBUFFER_UNSUPPORTED;
}
return f.apply(ctx, arguments);
};
}(wrappedContext_.checkFramebufferStatus);
wrappedContext_.getAttribLocation = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return -1;
}
return f.apply(ctx, arguments);
};
}(wrappedContext_.getAttribLocation);
wrappedContext_.getVertexAttribOffset = function(f) {
return function() {
loseContextIfTime();
if (contextLost_) {
return 0;
}
return f.apply(ctx, arguments);
};
}(wrappedContext_.getVertexAttribOffset);
wrappedContext_.isContextLost = function() {
return contextLost_;
};
return wrappedContext_;
}
}
return {
/**
* Initializes this module. Safe to call more than once.
* @param {!WebGLRenderingContext} ctx A WebGL context. If
* you have more than one context it doesn't matter which one
* you pass in, it is only used to pull out constants.
*/
'init': init,
/**
* Returns true or false if value matches any WebGL enum
* @param {*} value Value to check if it might be an enum.
* @return {boolean} True if value matches one of the WebGL defined enums
*/
'mightBeEnum': mightBeEnum,
/**
* Gets an string version of an WebGL enum.
*
* Example:
* WebGLDebugUtil.init(ctx);
* var str = WebGLDebugUtil.glEnumToString(ctx.getError());
*
* @param {number} value Value to return an enum for
* @return {string} The string version of the enum.
*/
'glEnumToString': glEnumToString,
/**
* Converts the argument of a WebGL function to a string.
* Attempts to convert enum arguments to strings.
*
* Example:
* WebGLDebugUtil.init(ctx);
* var str = WebGLDebugUtil.glFunctionArgToString('bindTexture', 2, 0, gl.TEXTURE_2D);
*
* would return 'TEXTURE_2D'
*
* @param {string} functionName the name of the WebGL function.
* @param {number} numArgs The number of arguments
* @param {number} argumentIndx the index of the argument.
* @param {*} value The value of the argument.
* @return {string} The value as a string.
*/
'glFunctionArgToString': glFunctionArgToString,
/**
* Converts the arguments of a WebGL function to a string.
* Attempts to convert enum arguments to strings.
*
* @param {string} functionName the name of the WebGL function.
* @param {number} args The arguments.
* @return {string} The arguments as a string.
*/
'glFunctionArgsToString': glFunctionArgsToString,
/**
* Given a WebGL context returns a wrapped context that calls
* gl.getError after every command and calls a function if the
* result is not NO_ERROR.
*
* You can supply your own function if you want. For example, if you'd like
* an exception thrown on any GL error you could do this
*
* function throwOnGLError(err, funcName, args) {
* throw WebGLDebugUtils.glEnumToString(err) +
* " was caused by call to " + funcName;
* };
*
* ctx = WebGLDebugUtils.makeDebugContext(
* canvas.getContext("webgl"), throwOnGLError);
*
* @param {!WebGLRenderingContext} ctx The webgl context to wrap.
* @param {!function(err, funcName, args): void} opt_onErrorFunc The function
* to call when gl.getError returns an error. If not specified the default
* function calls console.log with a message.
* @param {!function(funcName, args): void} opt_onFunc The
* function to call when each webgl function is called. You
* can use this to log all calls for example.
*/
'makeDebugContext': makeDebugContext,
/**
* Given a canvas element returns a wrapped canvas element that will
* simulate lost context. The canvas returned adds the following functions.
*
* loseContext:
* simulates a lost context event.
*
* restoreContext:
* simulates the context being restored.
*
* lostContextInNCalls:
* loses the context after N gl calls.
*
* getNumCalls:
* tells you how many gl calls there have been so far.
*
* setRestoreTimeout:
* sets the number of milliseconds until the context is restored
* after it has been lost. Defaults to 0. Pass -1 to prevent
* automatic restoring.
*
* @param {!Canvas} canvas The canvas element to wrap.
*/
'makeLostContextSimulatingCanvas': makeLostContextSimulatingCanvas,
/**
* Resets a context to the initial state.
* @param {!WebGLRenderingContext} ctx The webgl context to
* reset.
*/
'resetToInitialState': resetToInitialState
};
}();
================================================
FILE: docs/.editorconfig.txt
================================================
# http://editorconfig.org
root = true
[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
max_line_length = 80
trim_trailing_whitespace = true
[*.md]
max_line_length = 0
trim_trailing_whitespace = false
[COMMIT_EDITMSG]
max_line_length = 0
================================================
FILE: docs/.gitignore
================================================
_site
.sass-cache
.jekyll-metadata
*.gem
.bundle
vendor/bundle
================================================
FILE: docs/ImportAll.hx
================================================
package;
import lime.app.Application;
import lime.app.Event;
import lime.app.Future;
import lime.app.IModule;
import lime.app.Module;
import lime.app.Promise;
import lime.graphics.cairo.Cairo;
import lime.graphics.cairo.CairoAntialias;
import lime.graphics.cairo.CairoContent;
import lime.graphics.cairo.CairoExtend;
import lime.graphics.cairo.CairoFillRule;
import lime.graphics.cairo.CairoFilter;
import lime.graphics.cairo.CairoFontFace;
import lime.graphics.cairo.CairoFontOptions;
import lime.graphics.cairo.CairoFormat;
import lime.graphics.cairo.CairoFTFontFace;
import lime.graphics.cairo.CairoGlyph;
import lime.graphics.cairo.CairoHintMetrics;
import lime.graphics.cairo.CairoImageSurface;
import lime.graphics.cairo.CairoLineCap;
import lime.graphics.cairo.CairoLineJoin;
import lime.graphics.cairo.CairoOperator;
import lime.graphics.cairo.CairoPattern;
import lime.graphics.cairo.CairoStatus;
import lime.graphics.cairo.CairoSubpixelOrder;
import lime.graphics.cairo.CairoSurface;
import lime.graphics.opengl.GL;
import lime.graphics.opengl.GLActiveInfo;
import lime.graphics.opengl.GLBuffer;
import lime.graphics.opengl.GLContextAttributes;
import lime.graphics.opengl.GLFramebuffer;
import lime.graphics.opengl.GLProgram;
import lime.graphics.opengl.GLQuery;
import lime.graphics.opengl.GLRenderbuffer;
import lime.graphics.opengl.GLSampler;
import lime.graphics.opengl.GLShader;
import lime.graphics.opengl.GLShaderPrecisionFormat;
import lime.graphics.opengl.GLSync;
import lime.graphics.opengl.GLTexture;
import lime.graphics.opengl.GLTransformFeedback;
import lime.graphics.opengl.GLUniformLocation;
import lime.graphics.opengl.GLVertexArrayObject;
import lime.graphics.CairoRenderContext;
import lime.graphics.Canvas2DRenderContext;
import lime.graphics.DOMRenderContext;
import lime.graphics.FlashRenderContext;
import lime.graphics.Image;
import lime.graphics.ImageBuffer;
import lime.graphics.ImageChannel;
import lime.graphics.ImageFileFormat;
import lime.graphics.ImageType;
import lime.graphics.OpenGLES2RenderContext;
import lime.graphics.OpenGLES3RenderContext;
import lime.graphics.OpenGLRenderContext;
import lime.graphics.PixelFormat;
import lime.graphics.RenderContext;
import lime.graphics.RenderContextAttributes;
import lime.graphics.RenderContextType;
import lime.graphics.WebGL2RenderContext;
import lime.graphics.WebGLRenderContext;
import lime.math.ARGB;
import lime.math.BGRA;
import lime.math.ColorMatrix;
import lime.math.Matrix3;
import lime.math.Matrix4;
import lime.math.Rectangle;
import lime.math.RGBA;
import lime.math.Vector2;
import lime.math.Vector4;
import lime.media.howlerjs.Howl;
import lime.media.howlerjs.Howler;
import lime.media.openal.AL;
import lime.media.openal.ALAuxiliaryEffectSlot;
import lime.media.openal.ALBuffer;
import lime.media.openal.ALC;
import lime.media.openal.ALContext;
import lime.media.openal.ALDevice;
import lime.media.openal.ALEffect;
import lime.media.openal.ALFilter;
import lime.media.openal.ALSource;
import lime.media.vorbis.Vorbis;
import lime.media.vorbis.VorbisComment;
import lime.media.vorbis.VorbisFile;
import lime.media.vorbis.VorbisInfo;
import lime.media.AudioBuffer;
import lime.media.AudioContext;
import lime.media.AudioContextType;
import lime.media.AudioManager;
import lime.media.AudioSource;
import lime.media.FlashAudioContext;
import lime.media.HTML5AudioContext;
import lime.media.OpenALAudioContext;
import lime.media.WebAudioContext;
import lime.net.curl.CURL;
import lime.net.curl.CURLCode;
import lime.net.curl.CURLInfo;
import lime.net.curl.CURLMulti;
import lime.net.curl.CURLMultiCode;
import lime.net.curl.CURLMultiMessage;
import lime.net.curl.CURLMultiOption;
import lime.net.curl.CURLOption;
import lime.net.curl.CURLVersion;
import lime.net.oauth.OAuthClient;
import lime.net.oauth.OAuthConsumer;
import lime.net.oauth.OAuthRequest;
import lime.net.oauth.OAuthSignatureMethod;
import lime.net.oauth.OAuthToken;
import lime.net.oauth.OAuthVersion;
import lime.net.HTTPRequest;
import lime.net.HTTPRequestHeader;
import lime.net.HTTPRequestMethod;
import lime.net.URIParser;
import lime.system.BackgroundWorker;
import lime.system.CFFI;
import lime.system.CFFIPointer;
import lime.system.Clipboard;
import lime.system.Display;
import lime.system.DisplayMode;
import lime.system.Endian;
import lime.system.FileWatcher;
import lime.system.JNI;
import lime.system.Locale;
import lime.system.Sensor;
import lime.system.SensorType;
import lime.system.System;
import lime.system.ThreadPool;
import lime.system.WorkOutput;
import lime.text.harfbuzz.HB;
import lime.text.harfbuzz.HBBlob;
import lime.text.harfbuzz.HBBuffer;
import lime.text.harfbuzz.HBBufferClusterLevel;
import lime.text.harfbuzz.HBBufferContentType;
import lime.text.harfbuzz.HBBufferFlags;
import lime.text.harfbuzz.HBBufferSerializeFlags;
import lime.text.harfbuzz.HBBufferSerializeFormat;
import lime.text.harfbuzz.HBDirection;
import lime.text.harfbuzz.HBFace;
import lime.text.harfbuzz.HBFeature;
import lime.text.harfbuzz.HBFont;
import lime.text.harfbuzz.HBFTFont;
import lime.text.harfbuzz.HBGlyphExtents;
import lime.text.harfbuzz.HBGlyphInfo;
import lime.text.harfbuzz.HBGlyphPosition;
import lime.text.harfbuzz.HBLanguage;
import lime.text.harfbuzz.HBMemoryMode;
import lime.text.harfbuzz.HBScript;
import lime.text.harfbuzz.HBSegmentProperties;
import lime.text.harfbuzz.HBSet;
import lime.text.Font;
import lime.text.Glyph;
import lime.text.GlyphMetrics;
import lime.text.UTF8String;
import lime.ui.FileDialog;
import lime.ui.FileDialogType;
import lime.ui.Gamepad;
import lime.ui.GamepadAxis;
import lime.ui.GamepadButton;
import lime.ui.Haptic;
import lime.ui.Joystick;
import lime.ui.JoystickHatPosition;
import lime.ui.KeyCode;
import lime.ui.KeyModifier;
import lime.ui.MouseButton;
import lime.ui.MouseCursor;
import lime.ui.MouseWheelMode;
import lime.ui.ScanCode;
import lime.ui.Touch;
import lime.ui.Window;
import lime.ui.WindowAttributes;
import lime.utils.ArrayBuffer;
import lime.utils.ArrayBufferView;
import lime.utils.AssetBundle;
import lime.utils.AssetCache;
import lime.utils.AssetLibrary;
import lime.utils.AssetManifest;
import lime.utils.Assets;
import lime.utils.AssetType;
import lime.utils.BytePointer;
import lime.utils.Bytes;
import lime.utils.CompressionAlgorithm;
import lime.utils.DataPointer;
import lime.utils.DataView;
import lime.utils.Float32Array;
import lime.utils.Float64Array;
import lime.utils.Int16Array;
import lime.utils.Int32Array;
import lime.utils.Int8Array;
import lime.utils.Log;
import lime.utils.LogLevel;
import lime.utils.ObjectPool;
import lime.utils.PackedAssetLibrary;
import lime.utils.Preloader;
import lime.utils.Resource;
import lime.utils.UInt16Array;
import lime.utils.UInt32Array;
import lime.utils.UInt8Array;
import lime.utils.UInt8ClampedArray;
================================================
FILE: docs/build.hx
================================================
import hxp.*;
class Build extends Script
{
public function new()
{
super();
var base = new HXML(
{
defines: ["display", "doc-gen", "lime-doc-gen"],
classNames: ["ImportAll"],
libs: ["lime"],
noOutput: true
});
var flash = base.clone();
flash.xml = "xml/Flash.xml";
flash.swf = "obj/docs";
flash.swfVersion = "17.0";
flash.build();
var native = base.clone();
native.cpp = "obj/docs";
native.define("native");
native.define("lime-cffi");
var windows = native.clone();
windows.xml = "xml/Windows.xml";
windows.define("windows");
windows.build();
var mac = native.clone();
mac.xml = "xml/macOS.xml";
mac.define("mac");
mac.build();
var linux = native.clone();
linux.xml = "xml/Linux.xml";
linux.define("linux");
linux.build();
var ios = native.clone();
ios.xml = "xml/iOS.xml";
ios.define("ios");
ios.build();
var android = native.clone();
android.xml = "xml/Android.xml";
android.define("android");
android.build();
var html5 = base.clone();
html5.xml = "xml/HTML5.xml";
html5.js = "obj/docs";
html5.define("html5");
html5.build();
System.runCommand("", "haxelib", [
"run",
"dox",
"-i",
"xml",
"-in",
"lime",
"--title",
"Lime API Reference",
"-D",
"source-path",
"https://github.com/openfl/lime/tree/develop/src/",
"-D",
"website",
"https://lime.openfl.org",
"-D",
"textColor",
"0x777777",
"-theme",
"../assets/docs-theme",
"--toplevel-package",
"lime"
]);
}
}
================================================
FILE: docs/build.hxml
================================================
hxml/flash.hxml
--next
hxml/windows.hxml
--next
hxml/mac.hxml
--next
hxml/linux.hxml
--next
hxml/ios.hxml
--next
hxml/android.hxml
--next
hxml/html5.hxml
--next
-cmd haxelib run dox -i xml -in lime --title "Lime API Reference" -D website "https://lime.openfl.org" -D source-path "https://github.com/openfl/lime/tree/develop/src/" -D textColor 0x777777 -theme ../assets/docs-theme --toplevel-package lime
================================================
FILE: docs/hxml/android.hxml
================================================
-xml xml/Android.xml
-cpp obj/docs
-D display
-D native
-D lime-cffi
-D android
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/flash.hxml
================================================
-xml xml/Flash.xml
-swf obj/docs
-swf-version 17.0
-D display
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/html5.hxml
================================================
-xml xml/HTML5.xml
-js obj/docs
-D display
-D html5
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/ios.hxml
================================================
-xml xml/iOS.xml
-cpp obj/docs
-D display
-D native
-D lime-cffi
-D ios
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/linux.hxml
================================================
-xml xml/Linux.xml
-cpp obj/docs
-D display
-D native
-D lime-cffi
-D linux
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/mac.hxml
================================================
-xml xml/Mac.xml
-cpp obj/docs
-D display
-D native
-D lime-cffi
-D mac
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: docs/hxml/windows.hxml
================================================
-xml xml/Windows.xml
-cpp obj/docs
-D display
-D native
-D lime-cffi
-D windows
-D doc_gen
-D lime-doc-gen
ImportAll
-lib lime
--no-output
================================================
FILE: externs/air/air/desktop/URLFilePromise.hx
================================================
package air.desktop;
extern class URLFilePromise extends flash.events.EventDispatcher implements flash.desktop.IFilePromise
{
var isAsync(default, never):Bool;
var relativePath:String;
var request:flash.net.URLRequest;
function new():Void;
function close():Void;
function open():flash.utils.IDataInput;
function reportError(e:flash.events.ErrorEvent):Void;
}
================================================
FILE: externs/air/air/net/SecureSocketMonitor.hx
================================================
package air.net;
extern class SecureSocketMonitor extends SocketMonitor
{
function new(host:String, port:Int):Void;
}
================================================
FILE: externs/air/air/net/ServiceMonitor.hx
================================================
package air.net;
extern class ServiceMonitor extends flash.events.EventDispatcher
{
var available:Bool;
var lastStatusUpdate(default, never):Date;
var pollInterval:Float;
var running(default, never):Bool;
function new():Void;
function start():Void;
function stop():Void;
private function checkStatus():Void;
static function makeJavascriptSubclass(constructorFunction:Dynamic):Void;
}
================================================
FILE: externs/air/air/net/SocketMonitor.hx
================================================
package air.net;
extern class SocketMonitor extends ServiceMonitor
{
var host(default, never):String;
var port(default, never):Int;
function new(host:String, port:Int):Void;
private function createSocket():flash.net.Socket;
}
================================================
FILE: externs/air/air/net/URLMonitor.hx
================================================
package air.net;
extern class URLMonitor extends ServiceMonitor
{
var acceptableStatusCodes:Array;
var urlRequest(default, never):flash.net.URLRequest;
function new(urlRequest:flash.net.URLRequest, ?acceptableStatusCodes:Array):Void;
}
================================================
FILE: externs/air/air/update/ApplicationUpdater.hx
================================================
package air.update;
extern class ApplicationUpdater // extends air.update.states.HSM {
{
var configurationFile:flash.filesystem.File;
var currentState(default, never):String;
var currentVersion(default, never):String;
var delay:Float;
var isFirstRun(default, never):Bool;
var isNewerVersionFunction:Dynamic;
var previousApplicationStorageDirectory(default, never):flash.filesystem.File;
var previousVersion(default, never):String;
var updateDescriptor(default, never):flash.xml.XML;
var updateURL:String;
var wasPendingUpdate(default, never):Bool;
function new():Void;
function cancelUpdate():Void;
function checkForUpdate():Void;
function checkNow():Void;
function downloadUpdate():Void;
function initialize():Void;
function installFromAIRFile(file:flash.filesystem.File):Void;
function installUpdate():Void;
private var configuration:Dynamic; // air.update.core.UpdaterConfiguration;
private var state:Dynamic; // air.update.core.UpdaterState;
private var updaterHSM:Dynamic; // air.update.core.UpdaterHSM;
private function dispatchProxy(event:flash.events.Event):Void;
private function handleFirstRun():Bool;
private function handlePeriodicalCheck():Void;
private function onDownloadComplete(event:air.update.events.UpdateEvent):Void;
private function onFileInstall():Void;
private function onFileStatus(event:air.update.events.StatusFileUpdateEvent):Void;
private function onInitializationComplete():Void;
private function onInitialize():Void;
private function onInstall():Void;
private function onStateClear(event:flash.events.Event):Void;
private function onTimer(event:flash.events.TimerEvent):Void;
private function stateCancelled(event:flash.events.Event):Void;
private function stateInitializing(event:flash.events.Event):Void;
private function stateReady(event:flash.events.Event):Void;
private function stateRunning(event:flash.events.Event):Void;
private function stateUninitialized(event:flash.events.Event):Void;
}
================================================
FILE: externs/air/air/update/ApplicationUpdaterUI.hx
================================================
package air.update;
extern class ApplicationUpdaterUI extends flash.events.EventDispatcher
{
var configurationFile:flash.filesystem.File;
var currentVersion(default, never):String;
var delay:Float;
var isCheckForUpdateVisible:Bool;
var isDownloadProgressVisible:Bool;
var isDownloadUpdateVisible:Bool;
var isFileUpdateVisible:Bool;
var isFirstRun(default, never):Bool;
var isInstallUpdateVisible:Bool;
var isNewerVersionFunction:Dynamic;
var isUnexpectedErrorVisible:Bool;
var isUpdateInProgress(default, never):Bool;
var localeChain:Array;
var previousApplicationStorageDirectory(default, never):flash.filesystem.File;
var previousVersion(default, never):String;
var updateDescriptor(default, never):flash.xml.XML;
var updateURL:String;
var wasPendingUpdate(default, never):Bool;
function new():Void;
function addResources(lang:String, res:Dynamic):Void;
function cancelUpdate():Void;
function checkNow():Void;
function initialize():Void;
function installFromAIRFile(file:flash.filesystem.File):Void;
private function dispatchError(event:flash.events.ErrorEvent):Void;
private function dispatchProxy(event:flash.events.Event):Void;
}
================================================
FILE: externs/air/air/update/events/DownloadErrorEvent.hx
================================================
package air.update.events;
extern class DownloadErrorEvent extends flash.events.ErrorEvent
{
var subErrorID:Int;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, text:String = "", id:Int = 0, subErrorID:Int = 0):Void;
static var DOWNLOAD_ERROR(default, never):String;
}
================================================
FILE: externs/air/air/update/events/StatusFileUpdateErrorEvent.hx
================================================
package air.update.events;
extern class StatusFileUpdateErrorEvent extends flash.events.ErrorEvent
{
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, text:String = "", id:Int = 0):Void;
static var FILE_UPDATE_ERROR(default, never):String;
}
================================================
FILE: externs/air/air/update/events/StatusFileUpdateEvent.hx
================================================
package air.update.events;
extern class StatusFileUpdateEvent extends UpdateEvent
{
var available:Bool;
var path:String;
var version:String;
var versionLabel:String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, available:Bool = false, version:String = "", path:String = "",
versionLabel:String = ""):Void;
static var FILE_UPDATE_STATUS(default, never):String;
}
================================================
FILE: externs/air/air/update/events/StatusUpdateErrorEvent.hx
================================================
package air.update.events;
extern class StatusUpdateErrorEvent extends flash.events.ErrorEvent
{
var subErrorID:Int;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, text:String = "", id:Int = 0, subErrorID:Int = 0):Void;
static var UPDATE_ERROR(default, never):String;
}
================================================
FILE: externs/air/air/update/events/StatusUpdateEvent.hx
================================================
package air.update.events;
extern class StatusUpdateEvent extends UpdateEvent
{
var available:Bool;
var details:Array;
var version:String;
var versionLabel:String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, available:Bool = false, version:String = "", ?details:Array,
versionLabel:String = ""):Void;
static var UPDATE_STATUS(default, never):String;
}
================================================
FILE: externs/air/air/update/events/UpdateEvent.hx
================================================
package air.update.events;
extern class UpdateEvent extends flash.events.Event
{
function new(type:String, bubbles:Bool = false, cancelable:Bool = false):Void;
static var BEFORE_INSTALL(default, never):String;
static var CHECK_FOR_UPDATE(default, never):String;
static var DOWNLOAD_COMPLETE(default, never):String;
static var DOWNLOAD_START(default, never):String;
static var INITIALIZED(default, never):String;
}
================================================
FILE: externs/air/flash/data/EncryptedLocalStore.hx
================================================
package flash.data;
extern class EncryptedLocalStore
{
static var isSupported(default, never):Bool;
static function getItem(name:String):flash.utils.ByteArray;
static function removeItem(name:String):Void;
static function reset():Void;
static function setItem(name:String, data:flash.utils.ByteArray, stronglyBound:Bool = false):Void;
}
================================================
FILE: externs/air/flash/data/SQLCollationType.hx
================================================
package flash.data;
@:native("flash.data.SQLCollationType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SQLCollationType(String)
{
var BINARY = "binary";
var NO_CASE = "noCase";
}
================================================
FILE: externs/air/flash/data/SQLColumnNameStyle.hx
================================================
package flash.data;
@:native("flash.data.SQLColumnNameStyle")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SQLColumnNameStyle(String)
{
var DEFAULT = "default";
var LONG = "long";
var SHORT = "short";
}
================================================
FILE: externs/air/flash/data/SQLColumnSchema.hx
================================================
package flash.data;
extern class SQLColumnSchema
{
var allowNull(default, never):Bool;
var autoIncrement(default, never):Bool;
var dataType(default, never):String;
var defaultCollationType(default, never):SQLCollationType;
var name(default, never):String;
var primaryKey(default, never):Bool;
function new(name:String, primaryKey:Bool, allowNull:Bool, autoIncrement:Bool, dataType:String, defaultCollationType:SQLCollationType):Void;
}
================================================
FILE: externs/air/flash/data/SQLConnection.hx
================================================
package flash.data;
extern class SQLConnection extends flash.events.EventDispatcher
{
var autoCompact(default, never):Bool;
var cacheSize:UInt; // default 2000
var columnNameStyle:SQLColumnNameStyle;
var connected(default, never):Bool;
var inTransaction(default, never):Bool;
var lastInsertRowID(default, never):Float;
var pageSize(default, never):UInt;
var totalChanges(default, never):Float;
function new():Void;
function analyze(?resourceName:String, ?responder:flash.net.Responder):Void;
function attach(name:String, ?reference:Dynamic, ?responder:flash.net.Responder, ?encryptionKey:flash.utils.ByteArray):Void;
function begin(?option:String, ?responder:flash.net.Responder):Void;
function cancel(?responder:flash.net.Responder):Void;
function close(?responder:flash.net.Responder):Void;
function commit(?responder:flash.net.Responder):Void;
function compact(?responder:flash.net.Responder):Void;
function deanalyze(?responder:flash.net.Responder):Void;
function detach(name:String, ?responder:flash.net.Responder):Void;
function getSchemaResult():SQLSchemaResult;
function loadSchema(?type:Class, ?name:String, ?database:String = "main", ?includeColumnSchema:Bool = true, ?responder:flash.net.Responder):Void;
function open(?reference:Dynamic, ?openMode:SQLMode = SQLMode.CREATE, ?autoCompact:Bool = false, ?pageSize:Int = 1024,
?encryptionKey:flash.utils.ByteArray):Void;
function openAsync(?reference:Dynamic, ?openMode:SQLMode = SQLMode.CREATE, ?responder:flash.net.Responder, ?autoCompact:Bool = false,
?pageSize:Int = 1024, ?encryptionKey:flash.utils.ByteArray):Void;
function reencrypt(newEncryptionKey:flash.utils.ByteArray, ?responder:flash.net.Responder):Void;
function releaseSavepoint(?name:String, ?responder:flash.net.Responder):Void;
function rollback(?responder:flash.net.Responder):Void;
function rollbackToSavepoint(?name:String, ?responder:flash.net.Responder):Void;
function setSavepoint(?name:String, ?responder:flash.net.Responder):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/data/SQLIndexSchema.hx
================================================
package flash.data;
extern class SQLIndexSchema extends SQLSchema
{
var table(default, never):String;
function new(database:String, name:String, sql:String, table:String):Void;
}
================================================
FILE: externs/air/flash/data/SQLMode.hx
================================================
package flash.data;
@:native("flash.data.SQLMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SQLMode(String)
{
var CREATE = "create";
var READ = "read";
var UPDATE = "update";
}
================================================
FILE: externs/air/flash/data/SQLResult.hx
================================================
package flash.data;
extern class SQLResult
{
var complete(default, never):Bool;
var data(default, never):Array;
var lastInsertRowID(default, never):Float;
var rowsAffected(default, never):Float;
function new(?data:Array, ?rowsAffected:Float = 0.0, ?complete:Bool = true, ?rowID:Float = 0.0):Void;
}
================================================
FILE: externs/air/flash/data/SQLSchema.hx
================================================
package flash.data;
extern class SQLSchema
{
var database(default, never):String;
var name(default, never):String;
var sql(default, never):String;
function new(database:String, name:String, sql:String):Void;
}
================================================
FILE: externs/air/flash/data/SQLSchemaResult.hx
================================================
package flash.data;
extern class SQLSchemaResult
{
var indices(default, never):Array;
var tables(default, never):Array;
var triggers(default, never):Array;
var views(default, never):Array;
function new(tables:Array, views:Array, indices:Array, triggers:Array):Void;
}
================================================
FILE: externs/air/flash/data/SQLStatement.hx
================================================
package flash.data;
extern class SQLStatement extends flash.events.EventDispatcher
{
var executing(default, never):Bool;
var itemClass:Class;
var parameters(default, never):Dynamic;
var sqlConnection:SQLConnection;
var text:String;
function new():Void;
function cancel():Void;
function clearParameters():Void;
function execute(?prefetch:Int = -1, ?responder:flash.net.Responder):Void;
function getResult():SQLResult;
function next(?prefetch:Int = -1, ?responder:flash.net.Responder):Void;
}
================================================
FILE: externs/air/flash/data/SQLTableSchema.hx
================================================
package flash.data;
extern class SQLTableSchema extends SQLSchema
{
var columns(default, never):Array;
function new(database:String, name:String, sql:String, columns:Array):Void;
}
================================================
FILE: externs/air/flash/data/SQLTransactionLockType.hx
================================================
package flash.data;
@:native("flash.data.SQLTransactionLockType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SQLTransactionLockType(String)
{
var DEFERRED = "deferred";
var EXCLUSIVE = "exclusive";
var IMMEDIATE = "immediate";
}
================================================
FILE: externs/air/flash/data/SQLTriggerSchema.hx
================================================
package flash.data;
extern class SQLTriggerSchema extends SQLSchema
{
var table(default, never):String;
function new(database:String, name:String, sql:String, table:String):Void;
}
================================================
FILE: externs/air/flash/data/SQLViewSchema.hx
================================================
package flash.data;
extern class SQLViewSchema extends SQLTableSchema
{
function new(database:String, name:String, sql:String, columns:Array):Void;
}
================================================
FILE: externs/air/flash/desktop/Clipboard.hx
================================================
package flash.desktop;
@:require(flash10) extern class Clipboard
{
var formats(default, never):Array;
#if air
var supportsFilePromise(default, never):Bool;
#end
function clear():Void;
function clearData(format:ClipboardFormats):Void;
function getData(format:ClipboardFormats, ?transferMode:ClipboardTransferMode):flash.utils.Object;
function hasFormat(format:ClipboardFormats):Bool;
function setData(format:ClipboardFormats, data:flash.utils.Object, serializable:Bool = true):Bool;
function setDataHandler(format:ClipboardFormats, handler:flash.utils.Function, serializable:Bool = true):Bool;
static var generalClipboard(default, never):Clipboard;
}
================================================
FILE: externs/air/flash/desktop/DockIcon.hx
================================================
package flash.desktop;
extern class DockIcon extends InteractiveIcon
{
var menu:flash.display.NativeMenu;
function new():Void;
function bounce(?priority:NotificationType = NotificationType.INFORMATIONAL):Void;
}
================================================
FILE: externs/air/flash/desktop/FilePromiseManager.hx
================================================
package flash.desktop;
extern class FilePromiseManager extends flash.events.EventDispatcher
{
function new():Void;
function addPromises(clipboard:Clipboard, dropDirectoryPath:String):Bool;
static var ASYNC_FILE_PROMISE_DONE_EVENT(default, never):String;
static var DATA_EVENT_TIMEOUT(default, never):Int;
static var FILE_PROMISE_ERR_CLOSE(default, never):Int;
static var FILE_PROMISE_ERR_OPEN(default, never):Int;
static var FILE_PROMISE_ERR_TIMEOUT(default, never):Int;
static function newFilePromiseErrorEvent(code:Int):flash.events.Event;
}
================================================
FILE: externs/air/flash/desktop/FilePromiseWrapper.hx
================================================
package flash.desktop;
extern class FilePromiseWrapper
{
var filePromise(default, never):IFilePromise;
function new(fp:IFilePromise):Void;
}
================================================
FILE: externs/air/flash/desktop/IFilePromise.hx
================================================
package flash.desktop;
extern interface IFilePromise
{
var isAsync(default, never):Bool;
var relativePath(default, never):String;
function close():Void;
function open():flash.utils.IDataInput;
function reportError(e:flash.events.ErrorEvent):Void;
}
================================================
FILE: externs/air/flash/desktop/Icon.hx
================================================
package flash.desktop;
extern class Icon extends flash.events.EventDispatcher
{
var bitmaps:Array;
function new():Void;
}
================================================
FILE: externs/air/flash/desktop/InteractiveIcon.hx
================================================
package flash.desktop;
extern class InteractiveIcon extends Icon
{
var height(default, never):Int;
var width(default, never):Int;
function new():Void;
}
================================================
FILE: externs/air/flash/desktop/InvokeEventReason.hx
================================================
package flash.desktop;
@:native("flash.desktop.InvokeEventReason")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract InvokeEventReason(String)
{
var LOGIN = "login";
var NOTIFICATION = "notification";
var OPEN_URL = "openUrl";
var STANDARD = "standard";
}
================================================
FILE: externs/air/flash/desktop/JSClipboard.hx
================================================
package flash.desktop;
extern class JSClipboard
{
var clipboard(default, never):Clipboard;
var dragOptions:NativeDragOptions;
var dropEffect:String;
var effectAllowed:String;
var propagationStopped:Bool;
var types(default, never):Array;
function new(writable:Bool, forDragging:Bool, ?clipboard:Clipboard, ?dragOptions:NativeDragOptions):Void;
function clearAllData():Void;
function clearData(mimeType:String):Void;
function getData(mimeType:String):Dynamic;
function setData(mimeType:String, data:Dynamic):Bool;
static function urisFromURIList(uriList:String):Array;
}
================================================
FILE: externs/air/flash/desktop/MacFilePromiseWrapper.hx
================================================
package flash.desktop;
extern class MacFilePromiseWrapper extends flash.events.EventDispatcher
{
function new(promise:IFilePromise, dropDirectory:flash.filesystem.File):Void;
function open():Bool;
}
================================================
FILE: externs/air/flash/desktop/NativeApplication.hx
================================================
package flash.desktop;
extern class NativeApplication extends flash.events.EventDispatcher
{
var activeWindow(default, never):flash.display.NativeWindow;
var applicationDescriptor(default, never):flash.xml.XML;
var applicationID(default, never):String;
var autoExit:Bool;
var executeInBackground:Bool;
var icon(default, never):InteractiveIcon;
var idleThreshold:Int;
var isCompiledAOT(default, never):Bool;
var menu:flash.display.NativeMenu;
var openedWindows(default, never):Array;
var publisherID(default, never):String;
var runtimePatchLevel(default, never):UInt;
var runtimeVersion(default, never):String;
var startAtLogin:Bool;
var systemIdleMode:SystemIdleMode;
var timeSinceLastUserInput(default, never):Int;
function new():Void;
function activate(?window:flash.display.NativeWindow):Void;
function clear():Bool;
function copy():Bool;
function cut():Bool;
function exit(?errorCode:Int):Void;
function getDefaultApplication(extension:String):String;
function isSetAsDefaultApplication(extension:String):Bool;
function paste():Bool;
function removeAsDefaultApplication(extension:String):Void;
function selectAll():Bool;
function setAsDefaultApplication(extension:String):Void;
static var nativeApplication(default, never):NativeApplication;
static var supportsDefaultApplication(default, never):Bool;
static var supportsDockIcon(default, never):Bool;
static var supportsMenu(default, never):Bool;
static var supportsStartAtLogin(default, never):Bool;
static var supportsSystemTrayIcon(default, never):Bool;
}
================================================
FILE: externs/air/flash/desktop/NativeDragActions.hx
================================================
package flash.desktop;
@:native("flash.desktop.NativeDragActions")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeDragActions(String)
{
var COPY = "copy";
var LINK = "link";
var MOVE = "move";
var NONE = "none";
}
================================================
FILE: externs/air/flash/desktop/NativeDragManager.hx
================================================
package flash.desktop;
extern class NativeDragManager
{
static var dragInitiator(default, never):flash.display.InteractiveObject;
static var dropAction:NativeDragActions;
static var isDragging(default, never):Bool;
static var isSupported(default, never):Bool;
static function acceptDragDrop(target:flash.display.InteractiveObject):Void;
static function doDrag(dragInitiator:flash.display.InteractiveObject, clipboard:Clipboard, ?dragImage:flash.display.BitmapData, ?offset:flash.geom.Point,
?allowedActions:NativeDragOptions):Void;
}
================================================
FILE: externs/air/flash/desktop/NativeDragOptions.hx
================================================
package flash.desktop;
extern class NativeDragOptions
{
var allowCopy:Bool;
var allowLink:Bool;
var allowMove:Bool;
function new():Void;
function toString():String;
}
================================================
FILE: externs/air/flash/desktop/NativeProcess.hx
================================================
package flash.desktop;
extern class NativeProcess extends flash.events.EventDispatcher
{
var running(default, never):Bool;
var standardError(default, never):flash.utils.IDataInput;
var standardInput(default, never):flash.utils.IDataOutput;
var standardOutput(default, never):flash.utils.IDataInput;
function new():Void;
function closeInput():Void;
function exit(force:Bool = false):Void;
function start(info:NativeProcessStartupInfo):Void;
static var isSupported(default, never):Bool;
static function isValidExecutable(f:flash.filesystem.File):Bool;
}
================================================
FILE: externs/air/flash/desktop/NativeProcessStartupInfo.hx
================================================
package flash.desktop;
extern class NativeProcessStartupInfo
{
var arguments:flash.Vector;
var executable:flash.filesystem.File;
var workingDirectory:flash.filesystem.File;
function new():Void;
}
================================================
FILE: externs/air/flash/desktop/NativeWindowIcon.hx
================================================
package flash.desktop;
extern class NativeWindowIcon extends InteractiveIcon
{
function new():Void;
}
================================================
FILE: externs/air/flash/desktop/NotificationType.hx
================================================
package flash.desktop;
@:native("flash.desktop.NotificationType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NotificationType(String)
{
var CRITICAL = "critical";
var INFORMATIONAL = "informational";
}
================================================
FILE: externs/air/flash/desktop/SystemIdleMode.hx
================================================
package flash.desktop;
@:native("flash.desktop.SystemIdleMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SystemIdleMode(String)
{
var KEEP_AWAKE = "keepAwake";
var NORMAL = "normal";
}
================================================
FILE: externs/air/flash/desktop/SystemTrayIcon.hx
================================================
package flash.desktop;
extern class SystemTrayIcon extends InteractiveIcon
{
var menu:flash.display.NativeMenu;
var tooltip:String;
function new():Void;
static var MAX_TIP_LENGTH(default, never):Float;
}
================================================
FILE: externs/air/flash/desktop/Updater.hx
================================================
package flash.desktop;
extern class Updater
{
function new():Void;
function update(airFile:flash.filesystem.File, version:String):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/display/DisplayObject.hx
================================================
package flash.display;
extern class DisplayObject extends flash.events.EventDispatcher implements IBitmapDrawable
{
#if (haxe_ver < 4.3)
var accessibilityProperties:flash.accessibility.AccessibilityProperties;
var alpha:Float;
var blendMode:BlendMode;
@:require(flash10) var blendShader(never, default):Shader;
var cacheAsBitmap:Bool;
#if air
var cacheAsBitmapMatrix:flash.geom.Matrix;
#end
var filters:Array;
var height:Float;
var loaderInfo(default, never):LoaderInfo;
var mask:DisplayObject;
var mouseX(default, never):Float;
var mouseY(default, never):Float;
var name:String;
var opaqueBackground:Null;
var parent(default, never):DisplayObjectContainer;
var root(default, never):DisplayObject;
var rotation:Float;
@:require(flash10) var rotationX:Float;
@:require(flash10) var rotationY:Float;
@:require(flash10) var rotationZ:Float;
var scale9Grid:flash.geom.Rectangle;
var scaleX:Float;
var scaleY:Float;
@:require(flash10) var scaleZ:Float;
var scrollRect:flash.geom.Rectangle;
var stage(default, never):Stage;
var transform:flash.geom.Transform;
var visible:Bool;
var width:Float;
var x:Float;
var y:Float;
@:require(flash10) var z:Float;
#else
@:flash.property var accessibilityProperties:flash.accessibility.AccessibilityProperties;
@:flash.property var alpha:Float;
@:flash.property var blendMode:BlendMode;
@:flash.property @:require(flash10) var blendShader(never, default):Shader;
@:flash.property var cacheAsBitmap:Bool;
#if air
@:flash.property var cacheAsBitmapMatrix:flash.geom.Matrix;
#end
@:flash.property var filters(get, set):Array;
@:flash.property var height(get, set):Float;
@:flash.property var loaderInfo(get, never):LoaderInfo;
@:flash.property var mask(get, set):DisplayObject;
@:flash.property var mouseX(get, never):Float;
@:flash.property var mouseY(get, never):Float;
@:flash.property var name(get, set):String;
@:flash.property var opaqueBackground(get, set):Null;
@:flash.property var parent(get, never):DisplayObjectContainer;
@:flash.property var root(get, never):DisplayObject;
@:flash.property var rotation(get, set):Float;
@:flash.property @:require(flash10) var rotationX(get, set):Float;
@:flash.property @:require(flash10) var rotationY(get, set):Float;
@:flash.property @:require(flash10) var rotationZ(get, set):Float;
@:flash.property var scale9Grid(get, set):flash.geom.Rectangle;
@:flash.property var scaleX(get, set):Float;
@:flash.property var scaleY(get, set):Float;
@:flash.property @:require(flash10) var scaleZ(get, set):Float;
@:flash.property var scrollRect(get, set):flash.geom.Rectangle;
@:flash.property var stage(get, never):Stage;
@:flash.property var transform(get, set):flash.geom.Transform;
@:flash.property var visible(get, set):Bool;
@:flash.property var width(get, set):Float;
@:flash.property var x(get, set):Float;
@:flash.property var y(get, set):Float;
@:flash.property @:require(flash10) var z(get, set):Float;
#end
function getBounds(targetCoordinateSpace:DisplayObject):flash.geom.Rectangle;
function getRect(targetCoordinateSpace:DisplayObject):flash.geom.Rectangle;
function globalToLocal(point:flash.geom.Point):flash.geom.Point;
@:require(flash10) function globalToLocal3D(point:flash.geom.Point):flash.geom.Vector3D;
function hitTestObject(obj:DisplayObject):Bool;
function hitTestPoint(x:Float, y:Float, shapeFlag:Bool = false):Bool;
@:require(flash10) function local3DToGlobal(point3d:flash.geom.Vector3D):flash.geom.Point;
function localToGlobal(point:flash.geom.Point):flash.geom.Point;
#if (haxe_ver >= 4.3)
private function get_accessibilityProperties():flash.accessibility.AccessibilityProperties;
private function get_alpha():Float;
private function get_blendMode():BlendMode;
private function get_cacheAsBitmap():Bool;
private function get_filters():Array;
private function get_height():Float;
private function get_loaderInfo():LoaderInfo;
private function get_mask():DisplayObject;
private function get_metaData():Dynamic;
private function get_mouseX():Float;
private function get_mouseY():Float;
private function get_name():String;
private function get_opaqueBackground():Null;
private function get_parent():DisplayObjectContainer;
private function get_root():DisplayObject;
private function get_rotation():Float;
private function get_rotationX():Float;
private function get_rotationY():Float;
private function get_rotationZ():Float;
private function get_scale9Grid():flash.geom.Rectangle;
private function get_scaleX():Float;
private function get_scaleY():Float;
private function get_scaleZ():Float;
private function get_scrollRect():flash.geom.Rectangle;
private function get_stage():Stage;
private function get_transform():flash.geom.Transform;
private function get_visible():Bool;
private function get_width():Float;
private function get_x():Float;
private function get_y():Float;
private function get_z():Float;
#if air
private function get_cacheAsBitmapMatrix():flash.geom.Matrix;
#end
private function set_accessibilityProperties(value:flash.accessibility.AccessibilityProperties):flash.accessibility.AccessibilityProperties;
private function set_alpha(value:Float):Float;
private function set_blendMode(value:BlendMode):BlendMode;
private function set_blendShader(value:Shader):Shader;
private function set_cacheAsBitmap(value:Bool):Bool;
private function set_filters(value:Array):Array;
private function set_height(value:Float):Float;
private function set_mask(value:DisplayObject):DisplayObject;
private function set_metaData(value:Dynamic):Dynamic;
private function set_name(value:String):String;
private function set_opaqueBackground(value:Null):Null;
private function set_rotation(value:Float):Float;
private function set_rotationX(value:Float):Float;
private function set_rotationY(value:Float):Float;
private function set_rotationZ(value:Float):Float;
private function set_scale9Grid(value:flash.geom.Rectangle):flash.geom.Rectangle;
private function set_scaleX(value:Float):Float;
private function set_scaleY(value:Float):Float;
private function set_scaleZ(value:Float):Float;
private function set_scrollRect(value:flash.geom.Rectangle):flash.geom.Rectangle;
private function set_transform(value:flash.geom.Transform):flash.geom.Transform;
private function set_visible(value:Bool):Bool;
private function set_width(value:Float):Float;
private function set_x(value:Float):Float;
private function set_y(value:Float):Float;
private function set_z(value:Float):Float;
#if air
private function set_cacheAsBitmapMatrix(value:flash.geom.Matrix):flash.geom.Matrix;
#end
#end
}
================================================
FILE: externs/air/flash/display/InteractiveObject.hx
================================================
package flash.display;
extern class InteractiveObject extends DisplayObject
{
#if (haxe_ver < 4.3)
var accessibilityImplementation:flash.accessibility.AccessibilityImplementation;
// var contextMenu : #if air flash.display.NativeMenu #else flash.ui.ContextMenu #end;
var contextMenu:NativeMenu;
var doubleClickEnabled:Bool;
var focusRect:Dynamic;
var mouseEnabled:Bool;
@:require(flash11) var needsSoftKeyboard:Bool;
@:require(flash11) var softKeyboardInputAreaOfInterest:flash.geom.Rectangle;
var tabEnabled:Bool;
var tabIndex:Int;
#else
@:flash.property var accessibilityImplementation(get, set):flash.accessibility.AccessibilityImplementation;
// @:flash.property var contextMenu : #if air flash.display.NativeMenu #else flash.ui.ContextMenu #end;
@:flash.property var contextMenu(get, set):NativeMenu;
@:flash.property var doubleClickEnabled(get, set):Bool;
@:flash.property var focusRect(get, set):Dynamic;
@:flash.property var mouseEnabled(get, set):Bool;
@:flash.property @:require(flash11) var needsSoftKeyboard(get, set):Bool;
@:flash.property @:require(flash11) var softKeyboardInputAreaOfInterest(get, set):flash.geom.Rectangle;
@:flash.property var tabEnabled(get, set):Bool;
@:flash.property var tabIndex(get, set):Int;
#end
function new():Void;
@:require(flash11) function requestSoftKeyboard():Bool;
#if (haxe_ver >= 4.3)
private function get_accessibilityImplementation():flash.accessibility.AccessibilityImplementation;
private function get_contextMenu():#if air flash.display.NativeMenu #else flash.ui.ContextMenu #end;
private function get_doubleClickEnabled():Bool;
private function get_focusRect():Dynamic;
private function get_mouseEnabled():Bool;
private function get_needsSoftKeyboard():Bool;
private function get_softKeyboardInputAreaOfInterest():flash.geom.Rectangle;
private function get_tabEnabled():Bool;
private function get_tabIndex():Int;
private function set_accessibilityImplementation(value:flash.accessibility.AccessibilityImplementation):flash.accessibility.AccessibilityImplementation;
private function set_contextMenu(value:#if air flash.display.NativeMenu #else flash.ui.ContextMenu #end):#if air flash.display.NativeMenu #else flash.ui.ContextMenu #end;
private function set_doubleClickEnabled(value:Bool):Bool;
private function set_focusRect(value:Dynamic):Dynamic;
private function set_mouseEnabled(value:Bool):Bool;
private function set_needsSoftKeyboard(value:Bool):Bool;
private function set_softKeyboardInputAreaOfInterest(value:flash.geom.Rectangle):flash.geom.Rectangle;
private function set_tabEnabled(value:Bool):Bool;
private function set_tabIndex(value:Int):Int;
#end
}
================================================
FILE: externs/air/flash/display/Loader.hx
================================================
package flash.display;
extern class Loader extends DisplayObjectContainer
{
#if (haxe_ver < 4.3)
var content(default, never):DisplayObject;
var contentLoaderInfo(default, never):LoaderInfo;
@:require(flash10_1) var uncaughtErrorEvents(default, never):flash.events.UncaughtErrorEvents;
#else
@:flash.property var content(get, never):DisplayObject;
@:flash.property var contentLoaderInfo(get, never):LoaderInfo;
@:flash.property @:require(flash10_1) var uncaughtErrorEvents(get, never):flash.events.UncaughtErrorEvents;
#end
function new():Void;
function close():Void;
function load(request:flash.net.URLRequest, ?context:flash.system.LoaderContext):Void;
function loadBytes(bytes:flash.utils.ByteArray, ?context:flash.system.LoaderContext):Void;
#if air
function loadFilePromise(promise:flash.desktop.IFilePromise, ?context:flash.system.LoaderContext):Void;
#end
function unload():Void;
@:require(flash10) function unloadAndStop(gc:Bool = true):Void;
#if (haxe_ver >= 4.3)
private function get_content():DisplayObject;
private function get_contentLoaderInfo():LoaderInfo;
private function get_uncaughtErrorEvents():flash.events.UncaughtErrorEvents;
#end
}
================================================
FILE: externs/air/flash/display/NativeMenu.hx
================================================
package flash.display;
@:require(flash10_1) extern class NativeMenu extends flash.events.EventDispatcher
{
#if (haxe_ver < 4.3)
#if air
var items:Array;
var numItems(default, never):Int;
var parent(default, never):NativeMenu;
static var isSupported(default, never):Bool;
#end
#else
#if air
@:flash.property var items(get, set):Array;
@:flash.property var numItems(get, never):Int;
@:flash.property var parent(get, never):NativeMenu;
@:flash.property static var isSupported(get, never):Bool;
#end
#end
function new():Void;
#if air
function addItem(item:NativeMenuItem):NativeMenuItem;
function addItemAt(item:NativeMenuItem, index:Int):NativeMenuItem;
function addSubmenu(submenu:NativeMenu, label:String):NativeMenuItem;
function addSubmenuAt(submenu:NativeMenu, index:Int, label:String):NativeMenuItem;
function clone():NativeMenu;
function containsItem(item:NativeMenuItem):Bool;
function dispatchContextMenuSelect(event:flash.events.MouseEvent):Dynamic;
function display(stage:Stage, stageX:Float, stageY:Float):Void;
function getItemAt(index:Int):NativeMenuItem;
function getItemByName(name:String):NativeMenuItem;
function getItemIndex(item:NativeMenuItem):Int;
function removeAllItems():Void;
function removeItem(item:NativeMenuItem):NativeMenuItem;
function removeItemAt(index:Int):NativeMenuItem;
function setItemIndex(item:NativeMenuItem, index:Int):Void;
#end
#if (haxe_ver >= 4.3)
#if air
private function get_items():Array;
private function get_numItems():Int;
private function get_parent():NativeMenu;
private function set_items(value:Array):Array;
private static function get_isSupported():Bool;
#end
#end
}
================================================
FILE: externs/air/flash/display/NativeMenuItem.hx
================================================
package flash.display;
@:require(flash10_1) extern class NativeMenuItem extends flash.events.EventDispatcher
{
#if (haxe_ver < 4.3)
var checked:Bool;
var data:Dynamic;
var enabled:Bool;
var isSeparator(default, never):Bool;
var keyEquivalent:String;
var keyEquivalentModifiers:Array;
var label:String;
var menu(default, never):NativeMenu;
var mnemonicIndex:Int;
var name:String;
var submenu:NativeMenu;
#else
@:flash.property var checked(get, set):Bool;
@:flash.property var data(get, set):Dynamic;
@:flash.property var enabled(get, set):Bool;
@:flash.property var isSeparator(get, never):Bool;
@:flash.property var keyEquivalent(get, set):String;
@:flash.property var keyEquivalentModifiers(get, set):Array;
@:flash.property var label(get, set):String;
@:flash.property var menu(get, never):NativeMenu;
@:flash.property var mnemonicIndex(get, set):Int;
@:flash.property var name(get, set):String;
@:flash.property var submenu(get, set):NativeMenu;
#end
function new(?label:String = "", ?isSeparator:Bool = false):Void;
function clone():NativeMenuItem;
override function toString():String;
#if (haxe_ver >= 4.3)
private function get_checked():Bool;
private function get_data():Dynamic;
private function get_enabled():Bool;
private function get_isSeparator():Bool;
private function get_keyEquivalent():String;
private function get_keyEquivalentModifiers():Array;
private function get_label():String;
private function get_menu():NativeMenu;
private function get_mnemonicIndex():Int;
private function get_name():String;
private function get_submenu():NativeMenu;
private function set_checked(value:Bool):Bool;
private function set_data(value:Dynamic):Dynamic;
private function set_enabled(value:Bool):Bool;
private function set_keyEquivalent(value:String):String;
private function set_keyEquivalentModifiers(value:Array):Array;
private function set_label(value:String):String;
private function set_mnemonicIndex(value:Int):Int;
private function set_name(value:String):String;
private function set_submenu(value:NativeMenu):NativeMenu;
#end
}
================================================
FILE: externs/air/flash/display/NativeWindow.hx
================================================
package flash.display;
extern class NativeWindow extends flash.events.EventDispatcher
{
#if (haxe_ver < 4.3)
var active(default, never):Bool;
var alwaysInFront:Bool;
var bounds:flash.geom.Rectangle;
var closed(default, never):Bool;
var displayState(default, never):NativeWindowDisplayState;
var height:Float;
var maxSize:flash.geom.Point;
var maximizable(default, never):Bool;
var menu:NativeMenu;
var minSize:flash.geom.Point;
var minimizable(default, never):Bool;
var owner(default, never):NativeWindow;
var renderMode(default, never):NativeWindowRenderMode;
var resizable(default, never):Bool;
var stage(default, never):Stage;
var systemChrome(default, never):NativeWindowSystemChrome;
var title:String;
var transparent(default, never):Bool;
var type(default, never):NativeWindowType;
var visible:Bool;
var width:Float;
var x:Float;
var y:Float;
static var isSupported(default, never):Bool;
static var supportsMenu(default, never):Bool;
static var supportsNotification(default, never):Bool;
static var supportsTransparency(default, never):Bool;
static var systemMaxSize(default, never):flash.geom.Point;
static var systemMinSize(default, never):flash.geom.Point;
#else
@:flash.property var active(get, never):Bool;
@:flash.property var alwaysInFront(get, set):Bool;
@:flash.property var bounds(get, set):flash.geom.Rectangle;
@:flash.property var closed(get, never):Bool;
@:flash.property var displayState(get, never):NativeWindowDisplayState;
@:flash.property var height(get, set):Float;
@:flash.property var maxSize(get, set):flash.geom.Point;
@:flash.property var maximizable(get, never):Bool;
@:flash.property var menu(get, set):NativeMenu;
@:flash.property var minSize(get, set):flash.geom.Point;
@:flash.property var minimizable(get, never):Bool;
@:flash.property var owner(get, never):NativeWindow;
@:flash.property var renderMode(get, never):NativeWindowRenderMode;
@:flash.property var resizable(get, never):Bool;
@:flash.property var stage(get, never):Stage;
@:flash.property var systemChrome(get, never):NativeWindowSystemChrome;
@:flash.property var title(get, set):String;
@:flash.property var transparent(get, never):Bool;
@:flash.property var type(get, never):NativeWindowType;
@:flash.property var visible(get, set):Bool;
@:flash.property var width(get, set):Float;
@:flash.property var x(get, set):Float;
@:flash.property var y(get, set):Float;
@:flash.property static var isSupported(get, never):Bool;
@:flash.property static var supportsMenu(get, never):Bool;
@:flash.property static var supportsNotification(get, never):Bool;
@:flash.property static var supportsTransparency(get, never):Bool;
@:flash.property static var systemMaxSize(get, never):flash.geom.Point;
@:flash.property static var systemMinSize(get, never):flash.geom.Point;
#end
function new(initOptions:NativeWindowInitOptions):Void;
function activate():Void;
function close():Void;
function globalToScreen(globalPoint:flash.geom.Point):flash.geom.Point;
function listOwnedWindows():flash.Vector;
function maximize():Void;
function minimize():Void;
function notifyUser(type:flash.desktop.NotificationType):Void;
function orderInBackOf(window:NativeWindow):Bool;
function orderInFrontOf(window:NativeWindow):Bool;
function orderToBack():Bool;
function orderToFront():Bool;
function restore():Void;
function startMove():Bool;
function startResize(?edgeOrCorner:NativeWindowResize = NativeWindowResize.BOTTOM_RIGHT):Bool;
#if (haxe_ver >= 4.3)
private function get_active():Bool;
private function get_alwaysInFront():Bool;
private function get_bounds():flash.geom.Rectangle;
private function get_closed():Bool;
private function get_displayState():NativeWindowDisplayState;
private function get_height():Float;
private function get_maxSize():flash.geom.Point;
private function get_maximizable():Bool;
private function get_menu():NativeMenu;
private function get_minSize():flash.geom.Point;
private function get_minimizable():Bool;
private function get_owner():NativeWindow;
private function get_renderMode():NativeWindowRenderMode;
private function get_resizable():Bool;
private function get_stage():Stage;
private function get_systemChrome():NativeWindowSystemChrome;
private function get_title():String;
private function get_transparent():Bool;
private function get_type():NativeWindowType;
private function get_visible():Bool;
private function get_width():Float;
private function get_x():Float;
private function get_y():Float;
private function set_alwaysInFront(value:Bool):Bool;
private function set_bounds(value:flash.geom.Rectangle):flash.geom.Rectangle;
private function set_height(value:Float):Float;
private function set_maxSize(value:flash.geom.Point):flash.geom.Point;
private function set_maximizable(value:Bool):Bool;
private function set_menu(value:NativeMenu):NativeMenu;
private function set_minSize(value:flash.geom.Point):flash.geom.Point;
private function set_minimizable(value:Bool):Bool;
private function set_title(value:String):String;
private function set_visible(value:Bool):Bool;
private function set_width(value:Float):Float;
private function set_x(value:Float):Float;
private function set_y(value:Float):Float;
private static function get_isSupported():Bool;
private static function get_supportsMenu():Bool;
private static function get_supportsNotification():Bool;
private static function get_supportsTransparency():Bool;
private static function get_systemMaxSize():flash.geom.Point;
private static function get_systemMinSize():flash.geom.Point;
#end
}
================================================
FILE: externs/air/flash/display/NativeWindowDisplayState.hx
================================================
package flash.display;
@:native("flash.display.NativeWindowDisplayState")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeWindowDisplayState(String)
{
var MAXIMIZED = "maximized";
var MINIMIZED = "minimized";
var NORMAL = "normal";
}
================================================
FILE: externs/air/flash/display/NativeWindowInitOptions.hx
================================================
package flash.display;
extern class NativeWindowInitOptions
{
#if (haxe_ver < 4.3)
var maximizable:Bool;
var minimizable:Bool;
var owner:NativeWindow;
var renderMode:NativeWindowRenderMode;
var resizable:Bool;
var systemChrome:NativeWindowSystemChrome;
var transparent:Bool;
var type:NativeWindowType;
#else
@:flash.property var maximizable(get, set):Bool;
@:flash.property var minimizable(get, set):Bool;
@:flash.property var owner(get, set):NativeWindow;
@:flash.property var renderMode(get, set):NativeWindowRenderMode;
@:flash.property var resizable(get, set):Bool;
@:flash.property var systemChrome(get, set):NativeWindowSystemChrome;
@:flash.property var transparent(get, set):Bool;
@:flash.property var type(get, set):NativeWindowType;
#end
function new():Void;
#if (haxe_ver >= 4.3)
private function get_maximizable():Bool;
private function get_minimizable():Bool;
private function get_owner():NativeWindow;
private function get_renderMode():NativeWindowRenderMode;
private function get_resizable():Bool;
private function get_systemChrome():NativeWindowSystemChrome;
private function get_transparent():Bool;
private function get_type():NativeWindowType;
private function set_maximizable(value:Bool):Bool;
private function set_minimizable(value:Bool):Bool;
private function set_owner(value:NativeWindow):NativeWindow;
private function set_renderMode(value:NativeWindowRenderMode):NativeWindowRenderMode;
private function set_resizable(value:Bool):Bool;
private function set_systemChrome(value:NativeWindowSystemChrome):NativeWindowSystemChrome;
private function set_transparent(value:Bool):Bool;
private function set_type(value:NativeWindowType):NativeWindowType;
#end
}
================================================
FILE: externs/air/flash/display/NativeWindowRenderMode.hx
================================================
package flash.display;
@:native("flash.display.NativeWindowRenderMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeWindowRenderMode(String)
{
var AUTO = "auto";
var CPU = "cpu";
var DIRECT = "direct";
var GPU = "gpu";
}
================================================
FILE: externs/air/flash/display/NativeWindowResize.hx
================================================
package flash.display;
@:native("flash.display.NativeWindowResize")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeWindowResize(String)
{
var BOTTOM = "bottom";
var BOTTOM_LEFT = "bottomLeft";
var BOTTOM_RIGHT = "bottomRight";
var LEFT = "left";
var NONE = "none";
var RIGHT = "right";
var TOP = "top";
var TOP_LEFT = "topLeft";
var TOP_RIGHT = "topRight";
}
================================================
FILE: externs/air/flash/display/NativeWindowSystemChrome.hx
================================================
package flash.display;
@:native("flash.display.NativeWindowSystemChrome")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeWindowSystemChrome(String)
{
var ALTERNATE = "alternate";
var NONE = "none";
var STANDARD = "standard";
}
================================================
FILE: externs/air/flash/display/NativeWindowType.hx
================================================
package flash.display;
@:native("flash.display.NativeWindowType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NativeWindowType(String)
{
var LIGHTWEIGHT = "lightweight";
var NORMAL = "normal";
var UTILITY = "utility";
}
================================================
FILE: externs/air/flash/display/Screen.hx
================================================
package flash.display;
extern class Screen extends flash.events.EventDispatcher
{
#if (haxe_ver < 4.3)
var bounds(default, never):flash.geom.Rectangle;
var colorDepth(default, never):Int;
var visibleBounds(default, never):flash.geom.Rectangle;
static var mainScreen(default, never):Screen;
static var screens(default, never):Array;
#else
@:flash.property var bounds(get, never):flash.geom.Rectangle;
@:flash.property var colorDepth(get, never):Int;
@:flash.property var visibleBounds(get, never):flash.geom.Rectangle;
@:flash.property static var mainScreen(get, never):Screen;
@:flash.property static var screens(get, never):Array;
#end
function new():Void;
static function getScreensForRectangle(rect:flash.geom.Rectangle):Array;
#if (haxe_ver >= 4.3)
private function get_bounds():flash.geom.Rectangle;
private function get_colorDepth():Int;
private function get_visibleBounds():flash.geom.Rectangle;
private static function get_mainScreen():Screen;
private static function get_screens():Array;
#end
}
================================================
FILE: externs/air/flash/display/Stage.hx
================================================
package flash.display;
extern class Stage extends DisplayObjectContainer
{
#if (haxe_ver < 4.3)
var align:StageAlign;
var allowsFullScreen(default, never):Bool;
@:require(flash11_3) var allowsFullScreenInteractive(default, never):Bool;
#if air
var autoOrients:Bool;
#end
var browserZoomFactor(default, never):Float;
@:require(flash10_2) var color:UInt;
@:require(flash10) var colorCorrection:ColorCorrection;
@:require(flash10) var colorCorrectionSupport(default, never):ColorCorrectionSupport;
@:require(flash11_4) var contentsScaleFactor(default, never):Float;
#if air
var deviceOrientation(default, never):StageOrientation;
#end
@:require(flash11) var displayContextInfo(default, never):String;
// var constructor : Dynamic;
var displayState:StageDisplayState;
var focus:InteractiveObject;
var frameRate:Float;
var fullScreenHeight(default, never):UInt;
var fullScreenSourceRect:flash.geom.Rectangle;
var fullScreenWidth(default, never):UInt;
@:require(flash11_2) var mouseLock:Bool;
#if air
var nativeWindow(default, never):NativeWindow;
var orientation(default, never):StageOrientation;
#end
var quality:StageQuality;
var scaleMode:StageScaleMode;
var showDefaultContextMenu:Bool;
@:require(flash11) var softKeyboardRect(default, never):flash.geom.Rectangle;
@:require(flash11) var stage3Ds(default, never):flash.Vector;
var stageFocusRect:Bool;
var stageHeight:Int;
@:require(flash10_2) var stageVideos(default, never):flash.Vector;
var stageWidth:Int;
#if air
var supportedOrientations(default, never):flash.Vector;
#end
@:require(flash10_1) var wmodeGPU(default, never):Bool;
static var supportsOrientationChange(default, never):Bool;
#else
@:flash.property var align(get, set):StageAlign;
@:flash.property var allowsFullScreen(get, never):Bool;
@:flash.property @:require(flash11_3) var allowsFullScreenInteractive(get, never):Bool;
#if air
@:flash.property var autoOrients(get, set):Bool;
#end
@:flash.property var browserZoomFactor(get, never):Float;
@:flash.property @:require(flash10_2) var color(get, set):UInt;
@:flash.property @:require(flash10) var colorCorrection(get, set):ColorCorrection;
@:flash.property @:require(flash10) var colorCorrectionSupport(get, never):ColorCorrectionSupport;
@:flash.property @:require(flash11_4) var contentsScaleFactor(get, never):Float;
#if air
@:flash.property var deviceOrientation(get, never):StageOrientation;
#end
@:flash.property @:require(flash11) var displayContextInfo(get, never):String;
@:flash.property var displayState(get, set):StageDisplayState;
@:flash.property var focus(get, set):InteractiveObject;
@:flash.property var frameRate(get, set):Float;
@:flash.property var fullScreenHeight(get, never):UInt;
@:flash.property var fullScreenSourceRect(get, set):flash.geom.Rectangle;
@:flash.property var fullScreenWidth(get, never):UInt;
@:flash.property @:require(flash11_2) var mouseLock(get, set):Bool;
#if air
@:flash.property var nativeWindow(get, never):NativeWindow;
@:flash.property var orientation(get, never):StageOrientation;
#end
@:flash.property var quality(get, set):StageQuality;
@:flash.property var scaleMode(get, set):StageScaleMode;
@:flash.property var showDefaultContextMenu(get, set):Bool;
@:flash.property @:require(flash11) var softKeyboardRect(get, never):flash.geom.Rectangle;
@:flash.property @:require(flash11) var stage3Ds(get, never):flash.Vector;
@:flash.property var stageFocusRect(get, set):Bool;
@:flash.property var stageHeight(get, set):Int;
@:flash.property @:require(flash10_2) var stageVideos(get, never):flash.Vector;
@:flash.property var stageWidth(get, set):Int;
#if air
@:flash.property var supportedOrientations(get, never):flash.Vector;
#end
@:flash.property @:require(flash10_1) var wmodeGPU(get, never):Bool;
@:flash.property static var supportsOrientationChange(get, never):Bool;
#end
#if air
function assignFocus(objectToFocus:InteractiveObject, direction:FocusDirection):Void;
#end
function invalidate():Void;
function isFocusInaccessible():Bool;
#if air
function setAspectRatio(newAspectRatio:StageAspectRatio):Void;
function setOrientation(newOrientation:StageOrientation):Void;
#end
#if (haxe_ver >= 4.3)
private function get_align():StageAlign;
private function get_allowsFullScreen():Bool;
private function get_allowsFullScreenInteractive():Bool;
private function get_browserZoomFactor():Float;
private function get_color():UInt;
private function get_colorCorrection():ColorCorrection;
private function get_colorCorrectionSupport():ColorCorrectionSupport;
private function get_constructor():Dynamic;
private function get_contentsScaleFactor():Float;
private function get_displayContextInfo():String;
private function get_displayState():StageDisplayState;
private function get_focus():InteractiveObject;
private function get_frameRate():Float;
private function get_fullScreenHeight():UInt;
private function get_fullScreenSourceRect():flash.geom.Rectangle;
private function get_fullScreenWidth():UInt;
private function get_mouseLock():Bool;
private function get_quality():StageQuality;
private function get_scaleMode():StageScaleMode;
private function get_showDefaultContextMenu():Bool;
private function get_softKeyboardRect():flash.geom.Rectangle;
private function get_stage3Ds():Vector;
private function get_stageFocusRect():Bool;
private function get_stageHeight():Int;
private function get_stageVideos():Vector;
private function get_stageWidth():Int;
private function get_wmodeGPU():Bool;
private function set_align(value:StageAlign):StageAlign;
private function set_color(value:UInt):UInt;
private function set_colorCorrection(value:ColorCorrection):ColorCorrection;
private function set_constructor(value:Dynamic):Dynamic;
private function set_displayState(value:StageDisplayState):StageDisplayState;
private function set_focus(value:InteractiveObject):InteractiveObject;
private function set_frameRate(value:Float):Float;
private function set_fullScreenSourceRect(value:flash.geom.Rectangle):flash.geom.Rectangle;
private function set_mouseLock(value:Bool):Bool;
private function set_quality(value:StageQuality):StageQuality;
private function set_scaleMode(value:StageScaleMode):StageScaleMode;
private function set_showDefaultContextMenu(value:Bool):Bool;
private function set_stageFocusRect(value:Bool):Bool;
private function set_stageHeight(value:Int):Int;
private function set_stageWidth(value:Int):Int;
#if air
private static function get_supportsOrientationChange():Bool;
private function get_autoOrients():Bool;
private function get_deviceOrientation():StageOrientation;
private function get_nativeWindow():NativeWindow;
private function get_orientation():StageOrientation;
private function get_supportedOrientations():Vector;
private function get_vsyncEnabled():Bool;
private function set_autoOrients(value:Bool):Bool;
private function set_vsyncEnabled(value:Bool):Bool;
#end
#end
}
================================================
FILE: externs/air/flash/display/StageAspectRatio.hx
================================================
package flash.display;
@:native("flash.display.StageAspectRatio")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract StageAspectRatio(String)
{
var ANY = "any";
var LANDSCAPE = "landscape";
var PORTRAIT = "portrait";
}
================================================
FILE: externs/air/flash/display/StageOrientation.hx
================================================
package flash.display;
@:native("flash.display.StageOrientation")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract StageOrientation(String)
{
var DEFAULT = "default";
var ROTATED_LEFT = "rotatedLeft";
var ROTATED_RIGHT = "rotatedRight";
var UNKNOWN = "unknown";
var UPSIDE_DOWN = "upsideDown";
}
================================================
FILE: externs/air/flash/display3D/Context3DProfile.hx
================================================
package flash.display3D;
@:native("flash.display3D.Context3DProfile")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract Context3DProfile(String)
{
var BASELINE = "baseline";
var BASELINE_CONSTRAINED = "baselineConstrained";
var BASELINE_EXTENDED = "baselineExtended";
var STANDARD = "standard";
var STANDARD_CONSTRAINED = "standardConstrained";
var STANDARD_EXTENDED = "standardExtended";
#if air
var ENHANCED = "enhanced";
#end
}
================================================
FILE: externs/air/flash/errors/PermissionError.hx
================================================
package flash.errors;
extern class PermissionError extends Error
{
function new(message:String, id:Int):Void;
function toString():String;
}
================================================
FILE: externs/air/flash/errors/SQLError.hx
================================================
package flash.errors;
extern class SQLError extends flash.errors.Error
{
var detailArguments(default, never):Array;
var detailID(default, never):Int;
var details(default, never):String;
var operation(default, never):SQLErrorOperation;
function new(operation:SQLErrorOperation, ?details:String = "", ?message:String = "", ?id:Int = 0, ?detailID:Int = -1, ?detailArgs:Array):Void;
function toString():String;
}
================================================
FILE: externs/air/flash/errors/SQLErrorOperation.hx
================================================
package flash.errors;
@:native("flash.errors.SQLErrorOperation")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SQLErrorOperation(String)
{
var ANALYZE = "analyze";
var ATTACH = "attach";
var BEGIN = "begin";
var CLOSE = "close";
var COMMIT = "commit";
var COMPACT = "compact";
var DEANALYZE = "deanalyze";
var DETACH = "detach";
var EXECUTE = "execute";
var OPEN = "open";
var REENCRYPT = "reencrypt";
var RELEASE_SAVEPOINT = "releaseSavepoint";
var ROLLBACK = "rollback";
var ROLLBACK_TO_SAVEPOINT = "rollbackToSavepoint";
var SCHEMA = "schema";
var SET_SAVEPOINT = "setSavepoint";
}
================================================
FILE: externs/air/flash/events/BrowserInvokeEvent.hx
================================================
package flash.events;
extern class BrowserInvokeEvent extends Event
{
var arguments(default, never):Array;
var isHTTPS(default, never):Bool;
var isUserEvent(default, never):Bool;
var sandboxType(default, never):String;
var securityDomain(default, never):String;
function new(type:String, bubbles:Bool, cancelable:Bool, arguments:Array, sandboxType:String, securityDomain:String, isHTTPS:Bool,
isUserEvent:Bool):Void;
static var BROWSER_INVOKE(default, never):String;
}
================================================
FILE: externs/air/flash/events/DNSResolverEvent.hx
================================================
package flash.events;
extern class DNSResolverEvent extends Event
{
var host:String;
var resourceRecords:Array;
function new(type:String, bubbles:Bool = "false", cancelable:Bool = false, host:String = "", ?resourceRecords:Array):Void;
static var LOOKUP(default, never):String;
}
================================================
FILE: externs/air/flash/events/DRMStatusEvent.hx
================================================
package flash.events;
@:require(flash10_1) extern class DRMStatusEvent extends Event
{
var contentData:flash.net.drm.DRMContentData;
#if air
var detail(default, never):String;
var isAnonymous(default, never):Bool;
var isAvailableOffline(default, never):Bool;
#end
var isLocal:Bool;
#if air
var offlineLeasePeriod(default, never):UInt;
var policies(default, never):flash.utils.Object;
#end
var voucher:flash.net.drm.DRMVoucher;
#if air
var voucherEndDate(default, never):Date;
#end
function new(?type:String, bubbles:Bool = false, cancelable:Bool = false, ?inMetadata:flash.net.drm.DRMContentData, ?inVoucher:flash.net.drm.DRMVoucher,
inLocal:Bool = false):Void;
static var DRM_STATUS(default, never):String;
}
================================================
FILE: externs/air/flash/events/DatagramSocketDataEvent.hx
================================================
package flash.events;
extern class DatagramSocketDataEvent extends Event
{
var data:flash.utils.ByteArray;
var dstAddress:String;
var dstPort:Int;
var srcAddress:String;
var srcPort:Int;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, srcAddress:String = "", srcPort:Int = 0, dstAddress:String = "", dstPort:Int = 0,
?data:flash.utils.ByteArray):Void;
static var DATA(default, never):String;
}
================================================
FILE: externs/air/flash/events/DeviceRotationEvent.hx
================================================
package flash.events;
extern class DeviceRotationEvent extends Event
{
var pitch:Float;
var quaternion:Array;
var roll:Float;
var timestamp:Float;
var yaw:Float;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, timestamp:Float = 0, roll:Float = 0, pitch:Float = 0, yaw:Float = 0,
?quaternion:Array):Void;
static var UPDATE(default, never):String;
}
================================================
FILE: externs/air/flash/events/Event.hx
================================================
package flash.events;
extern class Event
{
var bubbles(default, never):Bool;
var cancelable(default, never):Bool;
var currentTarget(default, never):Dynamic;
var eventPhase(default, never):EventPhase;
var target(default, never):Dynamic;
var type(default, never):String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false):Void;
function clone():Event;
function formatToString(className:String, ?p1:Dynamic, ?p2:Dynamic, ?p3:Dynamic, ?p4:Dynamic, ?p5:Dynamic):String;
function isDefaultPrevented():Bool;
function preventDefault():Void;
function stopImmediatePropagation():Void;
function stopPropagation():Void;
function toString():String;
static var ACTIVATE(default, never):String;
static var ADDED(default, never):String;
static var ADDED_TO_STAGE(default, never):String;
static var BROWSER_ZOOM_CHANGE(default, never):String;
static var CANCEL(default, never):String;
static var CHANGE(default, never):String;
static var CHANNEL_MESSAGE(default, never):String;
static var CHANNEL_STATE(default, never):String;
@:require(flash10) static var CLEAR(default, never):String;
static var CLOSE(default, never):String;
#if air
static var CLOSING(default, never):String;
#end
static var COMPLETE(default, never):String;
static var CONNECT(default, never):String;
@:require(flash11) static var CONTEXT3D_CREATE(default, never):String;
@:require(flash10) static var COPY(default, never):String;
@:require(flash10) static var CUT(default, never):String;
static var DEACTIVATE(default, never):String;
#if air
static var DISPLAYING(default, never):String;
#end
static var ENTER_FRAME(default, never):String;
#if air
static var EXITING(default, never):String;
#end
@:require(flash10) static var EXIT_FRAME(default, never):String;
@:require(flash10) static var FRAME_CONSTRUCTED(default, never):String;
@:require(flash11_3) static var FRAME_LABEL(default, never):String;
static var FULLSCREEN(default, never):String;
#if air
static var HTML_BOUNDS_CHANGE(default, never):String;
static var HTML_DOM_INITIALIZE(default, never):String;
static var HTML_RENDER(default, never):String;
#end
static var ID3(default, never):String;
static var INIT(default, never):String;
#if air
static var LOCATION_CHANGE(default, never):String;
#end
static var MOUSE_LEAVE(default, never):String;
#if air
static var NETWORK_CHANGE(default, never):String;
#end
static var OPEN(default, never):String;
@:require(flash10) static var PASTE(default, never):String;
#if air
static var PREPARING(default, never):String;
#end
static var REMOVED(default, never):String;
static var REMOVED_FROM_STAGE(default, never):String;
static var RENDER(default, never):String;
static var RESIZE(default, never):String;
static var SCROLL(default, never):String;
static var SELECT(default, never):String;
@:require(flash10) static var SELECT_ALL(default, never):String;
static var SOUND_COMPLETE(default, never):String;
#if air
static var STANDARD_ERROR_CLOSE(default, never):String;
static var STANDARD_INPUT_CLOSE(default, never):String;
static var STANDARD_OUTPUT_CLOSE(default, never):String;
#end
@:require(flash11_3) static var SUSPEND(default, never):String;
static var TAB_CHILDREN_CHANGE(default, never):String;
static var TAB_ENABLED_CHANGE(default, never):String;
static var TAB_INDEX_CHANGE(default, never):String;
@:require(flash11_3) static var TEXTURE_READY(default, never):String;
@:require(flash11) static var TEXT_INTERACTION_MODE_CHANGE(default, never):String;
static var UNLOAD(default, never):String;
#if air
static var USER_IDLE(default, never):String;
static var USER_PRESENT(default, never):String;
#end
static var VIDEO_FRAME(default, never):String;
static var WORKER_STATE(default, never):String;
}
================================================
FILE: externs/air/flash/events/FileListEvent.hx
================================================
package flash.events;
extern class FileListEvent extends Event
{
var files:Array;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?files:Array):Void;
static var DIRECTORY_LISTING(default, never):String;
static var SELECT_MULTIPLE(default, never):String;
}
================================================
FILE: externs/air/flash/events/FocusEvent.hx
================================================
package flash.events;
extern class FocusEvent extends Event
{
#if air
var direction:flash.display.FocusDirection;
#end
@:require(flash10) var isRelatedObjectInaccessible:Bool;
var keyCode:UInt;
var relatedObject:flash.display.InteractiveObject;
var shiftKey:Bool;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, ?relatedObject:flash.display.InteractiveObject, shiftKey:Bool = false,
keyCode:UInt = 0):Void;
static var FOCUS_IN(default, never):String;
static var FOCUS_OUT(default, never):String;
static var KEY_FOCUS_CHANGE(default, never):String;
static var MOUSE_FOCUS_CHANGE(default, never):String;
}
================================================
FILE: externs/air/flash/events/GestureEvent.hx
================================================
package flash.events;
@:require(flash10_1) extern class GestureEvent extends Event
{
var altKey:Bool;
#if air
var commandKey:Bool;
#end
var controlKey:Bool;
var ctrlKey:Bool;
var localX:Float;
var localY:Float;
var phase:String;
var shiftKey:Bool;
var stageX(default, never):Float;
var stageY(default, never):Float;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, ?phase:String, localX:Float = 0, localY:Float = 0, ctrlKey:Bool = false,
altKey:Bool = false, shiftKey:Bool = false):Void;
function updateAfterEvent():Void;
static var GESTURE_TWO_FINGER_TAP(default, never):String;
}
================================================
FILE: externs/air/flash/events/HTMLUncaughtScriptExceptionEvent.hx
================================================
package flash.events;
extern class HTMLUncaughtScriptExceptionEvent extends Event
{
var exceptionValue:Dynamic;
var stackTrace:Array<{sourceURL:String, line:Float, functionName:String}>;
function new(exceptionValue:Dynamic):Void;
static var UNCAUGHT_SCRIPT_EXCEPTION(default, never):String;
}
================================================
FILE: externs/air/flash/events/IOErrorEvent.hx
================================================
package flash.events;
extern class IOErrorEvent extends ErrorEvent
{
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?text:String, id:Int = 0):Void;
static var DISK_ERROR(default, never):String;
static var IO_ERROR(default, never):String;
static var NETWORK_ERROR(default, never):String;
#if air
static var STANDARD_ERROR_IO_ERROR(default, never):String;
static var STANDARD_INPUT_IO_ERROR(default, never):String;
static var STANDARD_OUTPUT_IO_ERROR(default, never):String;
#end
static var VERIFY_ERROR(default, never):String;
}
================================================
FILE: externs/air/flash/events/InvokeEvent.hx
================================================
package flash.events;
extern class InvokeEvent extends Event
{
var arguments(default, never):Array;
var currentDirectory(default, never):flash.filesystem.File;
var reason(default, never):flash.desktop.InvokeEventReason;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?dir:flash.filesystem.File, ?argv:Array,
reason:flash.desktop.InvokeEventReason = flash.desktop.InvokeEventReason.STANDARD):Void;
static var INVOKE(default, never):String;
}
================================================
FILE: externs/air/flash/events/KeyboardEvent.hx
================================================
package flash.events;
extern class KeyboardEvent extends Event
{
var altKey:Bool;
var charCode:UInt;
#if air
var commandKey:Bool;
#end
var controlKey:Bool;
var ctrlKey:Bool;
var keyCode:UInt;
var keyLocation:flash.ui.KeyLocation;
var shiftKey:Bool;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, charCodeValue:UInt = 0, keyCodeValue:UInt = 0,
keyLocationValue:flash.ui.KeyLocation = STANDARD, ctrlKeyValue:Bool = false, altKeyValue:Bool = false, shiftKeyValue:Bool = false):Void;
function updateAfterEvent():Void;
static var KEY_DOWN(default, never):String;
static var KEY_UP(default, never):String;
}
================================================
FILE: externs/air/flash/events/LocationChangeEvent.hx
================================================
package flash.events;
extern class LocationChangeEvent extends Event
{
var location:String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?location:String):Void;
static var LOCATION_CHANGE(default, never):String;
static var LOCATION_CHANGING(default, never):String;
}
================================================
FILE: externs/air/flash/events/MediaEvent.hx
================================================
package flash.events;
extern class MediaEvent extends Event
{
var data(default, never):flash.media.MediaPromise;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?data:flash.media.MediaPromise):Void;
static var COMPLETE(default, never):String;
static var SELECT(default, never):String;
}
================================================
FILE: externs/air/flash/events/MouseEvent.hx
================================================
package flash.events;
extern class MouseEvent extends Event
{
var altKey:Bool;
var buttonDown:Bool;
#if air
var clickCount(default, never):Int;
var commandKey:Bool;
var controlKey:Bool;
#end
var ctrlKey:Bool;
var delta:Int;
@:require(flash10) var isRelatedObjectInaccessible:Bool;
var localX:Float;
var localY:Float;
@:require(flash11_2) var movementX:Float;
@:require(flash11_2) var movementY:Float;
var relatedObject:flash.display.InteractiveObject;
var shiftKey:Bool;
var stageX(default, never):Float;
var stageY(default, never):Float;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, localX:Null = 0, localY:Null = 0,
?relatedObject:flash.display.InteractiveObject, ctrlKey:Bool = false, altKey:Bool = false, shiftKey:Bool = false, buttonDown:Bool = false,
delta:Int = 0):Void;
function updateAfterEvent():Void;
static var CLICK(default, never):String;
@:require(flash11_2) static var CONTEXT_MENU(default, never):String;
static var DOUBLE_CLICK(default, never):String;
@:require(flash11_2) static var MIDDLE_CLICK(default, never):String;
@:require(flash11_2) static var MIDDLE_MOUSE_DOWN(default, never):String;
@:require(flash11_2) static var MIDDLE_MOUSE_UP(default, never):String;
static var MOUSE_DOWN(default, never):String;
static var MOUSE_MOVE(default, never):String;
static var MOUSE_OUT(default, never):String;
static var MOUSE_OVER(default, never):String;
static var MOUSE_UP(default, never):String;
static var MOUSE_WHEEL(default, never):String;
@:require(flash11_3) static var RELEASE_OUTSIDE(default, never):String;
@:require(flash11_2) static var RIGHT_CLICK(default, never):String;
@:require(flash11_2) static var RIGHT_MOUSE_DOWN(default, never):String;
@:require(flash11_2) static var RIGHT_MOUSE_UP(default, never):String;
static var ROLL_OUT(default, never):String;
static var ROLL_OVER(default, never):String;
}
================================================
FILE: externs/air/flash/events/NativeDragEvent.hx
================================================
package flash.events;
extern class NativeDragEvent extends MouseEvent
{
var allowedActions:flash.desktop.NativeDragOptions;
var clipboard:flash.desktop.Clipboard;
var dropAction:String;
function new(type:String, ?bubbles:Bool = false, ?cancelable:Bool = true, ?localX:Float, ?localY:Float, ?relatedObject:flash.display.InteractiveObject,
?clipboard:flash.desktop.Clipboard, ?allowedActions:flash.desktop.NativeDragOptions, ?dropAction:String, controlKey:Bool = false, altKey:Bool = false,
shiftKey:Bool = false, commandKey:Bool = false):Void;
static var NATIVE_DRAG_COMPLETE(default, never):String;
static var NATIVE_DRAG_DROP(default, never):String;
static var NATIVE_DRAG_ENTER(default, never):String;
static var NATIVE_DRAG_EXIT(default, never):String;
static var NATIVE_DRAG_OVER(default, never):String;
static var NATIVE_DRAG_START(default, never):String;
static var NATIVE_DRAG_UPDATE(default, never):String;
}
================================================
FILE: externs/air/flash/events/NativeProcessExitEvent.hx
================================================
package flash.events;
extern class NativeProcessExitEvent extends Event
{
var exitCode:Float;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?exitCode:Float):Void;
static var EXIT(default, never):String;
}
================================================
FILE: externs/air/flash/events/NativeWindowBoundsEvent.hx
================================================
package flash.events;
extern class NativeWindowBoundsEvent extends Event
{
var afterBounds(default, never):flash.geom.Rectangle;
var beforeBounds(default, never):flash.geom.Rectangle;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?beforeBounds:flash.geom.Rectangle, ?afterBounds:flash.geom.Rectangle):Void;
static var MOVE(default, never):String;
static var MOVING(default, never):String;
static var RESIZE(default, never):String;
static var RESIZING(default, never):String;
}
================================================
FILE: externs/air/flash/events/NativeWindowDisplayStateEvent.hx
================================================
package flash.events;
extern class NativeWindowDisplayStateEvent extends Event
{
var afterDisplayState(default, never):String;
var beforeDisplayState(default, never):String;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, beforeDisplayState:String = "", afterDisplayState:String = ""):Void;
static var DISPLAY_STATE_CHANGE(default, never):String;
static var DISPLAY_STATE_CHANGING(default, never):String;
}
================================================
FILE: externs/air/flash/events/PermissionEvent.hx
================================================
package flash.events;
@:final extern class PermissionEvent extends Event
{
var status(default, never):String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?status:String):Void;
static var PERMISSION_STATUS(default, never):String;
}
================================================
FILE: externs/air/flash/events/ProgressEvent.hx
================================================
package flash.events;
extern class ProgressEvent extends Event
{
var bytesLoaded:Float;
var bytesTotal:Float;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, bytesLoaded:Float = 0, bytesTotal:Float = 0):Void;
static var PROGRESS(default, never):String;
static var SOCKET_DATA(default, never):String;
#if air
static var STANDARD_ERROR_DATA(default, never):String;
static var STANDARD_INPUT_PROGRESS(default, never):String;
static var STANDARD_OUTPUT_DATA(default, never):String;
#end
}
================================================
FILE: externs/air/flash/events/RemoteNotificationEvent.hx
================================================
package flash.events;
@:final extern class RemoteNotificationEvent extends Event
{
var data(default, never):Dynamic;
var tokenId(default, never):String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?data:Dynamic, ?tokenId:String):Void;
static var NOTIFICATION(default, never):String;
static var TOKEN(default, never):String;
}
================================================
FILE: externs/air/flash/events/SQLErrorEvent.hx
================================================
package flash.events;
extern class SQLErrorEvent extends ErrorEvent
{
var error(default, never):flash.errors.SQLError;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?error:flash.errors.SQLError):Void;
static var ERROR(default, never):String;
}
================================================
FILE: externs/air/flash/events/SQLEvent.hx
================================================
package flash.events;
extern class SQLEvent extends Event
{
function new(type:String, bubbles:Bool = false, cancelable:Bool = false):Void;
static var ANALYZE(default, never):String;
static var ATTACH(default, never):String;
static var BEGIN(default, never):String;
static var CANCEL(default, never):String;
static var CLOSE(default, never):String;
static var COMMIT(default, never):String;
static var COMPACT(default, never):String;
static var DEANALYZE(default, never):String;
static var DETACH(default, never):String;
static var OPEN(default, never):String;
static var REENCRYPT(default, never):String;
static var RELEASE_SAVEPOINT(default, never):String;
static var RESULT(default, never):String;
static var ROLLBACK(default, never):String;
static var ROLLBACK_TO_SAVEPOINT(default, never):String;
static var SCHEMA(default, never):String;
static var SET_SAVEPOINT(default, never):String;
}
================================================
FILE: externs/air/flash/events/SQLUpdateEvent.hx
================================================
package flash.events;
extern class SQLUpdateEvent extends Event
{
var rowID(default, never):Float;
var table(default, never):String;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?table:String, rowID:Float = 0.0):Void;
static var DELETE(default, never):String;
static var INSERT(default, never):String;
static var UPDATE(default, never):String;
}
================================================
FILE: externs/air/flash/events/ScreenMouseEvent.hx
================================================
package flash.events;
extern class ScreenMouseEvent extends MouseEvent
{
var screenX(default, never):Float;
var screenY(default, never):Float;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, screenX:Float, screenY:Float, ctrlKey:Bool, altKey:Bool = false,
shiftKey:Bool = false, buttonDown:Bool = false, commandKey:Bool = false, controlKey:Bool = false):Void;
static var CLICK(default, never):String;
static var MOUSE_DOWN(default, never):String;
static var MOUSE_UP(default, never):String;
static var RIGHT_CLICK(default, never):String;
static var RIGHT_MOUSE_DOWN(default, never):String;
static var RIGHT_MOUSE_UP(default, never):String;
}
================================================
FILE: externs/air/flash/events/ServerSocketConnectEvent.hx
================================================
package flash.events;
extern class ServerSocketConnectEvent extends Event
{
var socket:flash.net.Socket;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?socket:flash.net.Socket):Void;
static var CONNECT(default, never):String;
}
================================================
FILE: externs/air/flash/events/StageOrientationEvent.hx
================================================
package flash.events;
extern class StageOrientationEvent extends Event
{
var afterOrientation(default, never):flash.display.StageOrientation;
var beforeOrientation(default, never):flash.display.StageOrientation;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?beforeOrientation:flash.display.StageOrientation,
?afterOrientation:flash.display.StageOrientation):Void;
static var ORIENTATION_CHANGE(default, never):String;
static var ORIENTATION_CHANGING(default, never):String;
}
================================================
FILE: externs/air/flash/events/StorageVolumeChangeEvent.hx
================================================
package flash.events;
extern class StorageVolumeChangeEvent extends Event
{
var _rootDirectory:flash.filesystem.File;
var _volume:flash.filesystem.StorageVolume;
var rootDirectory(default, never):flash.filesystem.File;
var storageVolume(default, never):flash.filesystem.StorageVolume;
function new(type:String, bubbles:Bool = false, cancelable:Bool = false, ?path:flash.filesystem.File, ?volume:flash.filesystem.StorageVolume):Void;
static var STORAGE_VOLUME_MOUNT(default, never):String;
static var STORAGE_VOLUME_UNMOUNT(default, never):String;
}
================================================
FILE: externs/air/flash/events/TouchEvent.hx
================================================
package flash.events;
@:require(flash10_1) extern class TouchEvent extends Event
{
var altKey:Bool;
#if air
var commandKey:Bool;
#end
var controlKey:Bool;
var ctrlKey:Bool;
var isPrimaryTouchPoint:Bool;
var isRelatedObjectInaccessible:Bool;
#if air
var isTouchPointCanceled:Bool;
#end
var localX:Float;
var localY:Float;
var pressure:Float;
var relatedObject:flash.display.InteractiveObject;
var shiftKey:Bool;
var sizeX:Float;
var sizeY:Float;
var stageX(default, never):Float;
var stageY(default, never):Float;
#if air
var timestamp:Float;
var touchIntent:TouchEventIntent;
#end
var touchPointID:Int;
function new(type:String, bubbles:Bool = true, cancelable:Bool = false, touchPointID:Int = 0, isPrimaryTouchPoint:Bool = false, localX:Float = 0. /*NaN*/,
localY:Float = 0. /*NaN*/, sizeX:Float = 0. /*NaN*/, sizeY:Float = 0. /*NaN*/, pressure:Float = 0. /*NaN*/,
?relatedObject:flash.display.InteractiveObject, ctrlKey:Bool = false, altKey:Bool = false, shiftKey:Bool = false
#if air, commandKey:Bool = false, controlKey:Bool = false, ?timestamp:Float, ?touchIntent:TouchEventIntent, ?samples:flash.utils.ByteArray,
isTouchPointCanceled:Bool = false #end):Void;
#if air
function getSamples(buffer:flash.utils.ByteArray, append:Bool = false):UInt;
function isToolButtonDown(index:Int):Bool;
#end
function updateAfterEvent():Void;
static var PROXIMITY_BEGIN(default, never):String;
static var PROXIMITY_END(default, never):String;
static var PROXIMITY_MOVE(default, never):String;
static var PROXIMITY_OUT(default, never):String;
static var PROXIMITY_OVER(default, never):String;
static var PROXIMITY_ROLL_OUT(default, never):String;
static var PROXIMITY_ROLL_OVER(default, never):String;
static var TOUCH_BEGIN(default, never):String;
static var TOUCH_END(default, never):String;
static var TOUCH_MOVE(default, never):String;
static var TOUCH_OUT(default, never):String;
static var TOUCH_OVER(default, never):String;
static var TOUCH_ROLL_OUT(default, never):String;
static var TOUCH_ROLL_OVER(default, never):String;
static var TOUCH_TAP(default, never):String;
}
================================================
FILE: externs/air/flash/events/TouchEventIntent.hx
================================================
package flash.events;
@:native("flash.events.TouchEventIntent")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract TouchEventIntent(String)
{
var ERASER = "eraser";
var PEN = "pen";
var UNKNOWN = "unknown";
}
================================================
FILE: externs/air/flash/external/ExtensionContext.hx
================================================
package flash.external;
@:final extern class ExtensionContext extends flash.events.EventDispatcher
{
var actionScriptData:flash.utils.Object;
function new():Void;
// function _disposed() : Bool;
function call(functionName:String, ?p1:Dynamic, ?p2:Dynamic, ?p3:Dynamic, ?p4:Dynamic, ?p5:Dynamic):Dynamic;
function dispose():Void;
// function getActionScriptData() : flash.utils.Object;
// function setActionScriptData(p1 : flash.utils.Object) : Void;
static function createExtensionContext(extensionID:String, contextType:String):ExtensionContext;
static function getExtensionDirectory(extensionID:String):flash.filesystem.File;
}
================================================
FILE: externs/air/flash/filesystem/File.hx
================================================
package flash.filesystem;
extern class File extends flash.net.FileReference
{
var downloaded:Bool;
var exists(default, never):Bool;
var icon(default, never):flash.desktop.Icon;
var isDirectory(default, never):Bool;
var isHidden(default, never):Bool;
var isPackage(default, never):Bool;
var isSymbolicLink(default, never):Bool;
var nativePath:String;
var parent(default, never):File;
var preventBackup:Bool;
var spaceAvailable(default, never):Float;
var url:String;
function new(?path:String):Void;
function browseForDirectory(title:String):Void;
function browseForOpen(title:String, ?typeFilter:Array):Void;
function browseForOpenMultiple(title:String, ?typeFilter:Array):Void;
function browseForSave(title:String):Void;
function canonicalize():Void;
function clone():File;
function copyTo(newLocation:flash.net.FileReference, overwrite:Bool = false):Void;
function copyToAsync(newLocation:flash.net.FileReference, overwrite:Bool = false):Void;
function createDirectory():Void;
function deleteDirectory(deleteDirectoryContents:Bool = false):Void;
function deleteDirectoryAsync(deleteDirectoryContents:Bool = false):Void;
function deleteFile():Void;
function deleteFileAsync():Void;
function getDirectoryListing():Array;
function getDirectoryListingAsync():Void;
function getRelativePath(ref:flash.net.FileReference, useDotDot:Bool = false):String;
function moveTo(newLocation:flash.net.FileReference, overwrite:Bool = false):Void;
function moveToAsync(newLocation:flash.net.FileReference, overwrite:Bool = false):Void;
function moveToTrash():Void;
function moveToTrashAsync():Void;
function openWithDefaultApplication():Void;
function resolvePath(path:String):File;
static var applicationDirectory(default, never):File;
static var applicationStorageDirectory(default, never):File;
static var cacheDirectory(default, never):File;
static var desktopDirectory(default, never):File;
static var documentsDirectory(default, never):File;
static var lineEnding(default, never):String;
static var permissionStatus(default, never):String;
static var separator(default, never):String;
static var systemCharset(default, never):String;
static var userDirectory(default, never):File;
static function createTempDirectory():File;
static function createTempFile():File;
static function getRootDirectories():Array;
}
================================================
FILE: externs/air/flash/filesystem/FileMode.hx
================================================
package flash.filesystem;
@:native("flash.filesystem.FileMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract FileMode(String)
{
var APPEND = "append";
var READ = "read";
var UPDATE = "update";
var WRITE = "write";
}
================================================
FILE: externs/air/flash/filesystem/FileStream.hx
================================================
package flash.filesystem;
extern class FileStream extends flash.events.EventDispatcher implements flash.utils.IDataInput implements flash.utils.IDataOutput
{
#if (haxe_ver < 4.3)
var bytesAvailable(default, never):UInt;
var endian:flash.utils.Endian;
var objectEncoding:#if openfl openfl.net.ObjectEncoding #else UInt #end;
#else
@:flash.property var bytesAvailable(get, never):UInt;
@:flash.property var endian(get, set):flash.utils.Endian;
@:flash.property var objectEncoding(get, set):#if openfl openfl.net.ObjectEncoding #else UInt #end;
#end
var position:Float;
var readAhead:Float;
function new():Void;
function close():Void;
function open(file:File, fileMode:FileMode):Void;
function openAsync(file:File, fileMode:FileMode):Void;
function readBoolean():Bool;
function readByte():Int;
function readBytes(bytes:flash.utils.ByteArray, offset:UInt = 0, length:UInt = 0):Void;
function readDouble():Float;
function readFloat():Float;
function readInt():Int;
function readMultiByte(length:UInt, charSet:String):String;
function readObject():Dynamic;
function readShort():Int;
function readUTF():String;
function readUTFBytes(length:UInt):String;
function readUnsignedByte():UInt;
function readUnsignedInt():UInt;
function readUnsignedShort():UInt;
function truncate():Void;
function writeBoolean(value:Bool):Void;
function writeByte(value:Int):Void;
function writeBytes(bytes:flash.utils.ByteArray, offset:UInt = 0, length:UInt = 0):Void;
function writeDouble(value:Float):Void;
function writeFloat(value:Float):Void;
function writeInt(value:Int):Void;
function writeMultiByte(value:String, charSet:String):Void;
function writeObject(object:Dynamic):Void;
function writeShort(value:Int):Void;
function writeUTF(value:String):Void;
function writeUTFBytes(value:String):Void;
function writeUnsignedInt(value:UInt):Void;
#if (haxe_ver >= 4.3)
private function get_bytesAvailable():UInt;
private function get_endian():flash.utils.Endian;
private function get_objectEncoding():#if openfl openfl.net.ObjectEncoding #else UInt #end;
private function set_endian(value:flash.utils.Endian):flash.utils.Endian;
private function set_objectEncoding(value:#if openfl openfl.net.ObjectEncoding #else UInt #end):#if openfl openfl.net.ObjectEncoding #else UInt #end;
#end
}
================================================
FILE: externs/air/flash/filesystem/StorageVolume.hx
================================================
package flash.filesystem;
extern class StorageVolume
{
var drive(default, never):String;
var fileSystemType(default, never):String;
var isRemovable(default, never):Bool;
var isWritable(default, never):Bool;
var name(default, never):String;
var rootDirectory(default, never):File;
function new(rootDirPath:File, name:String, writable:Bool, removable:Bool, fileSysType:String, drive:String):Void;
}
================================================
FILE: externs/air/flash/filesystem/StorageVolumeInfo.hx
================================================
package flash.filesystem;
@:final extern class StorageVolumeInfo extends flash.events.EventDispatcher
{
function new():Void;
function getStorageVolumes():flash.Vector;
static var isSupported(default, never):Bool;
static var storageVolumeInfo(default, never):StorageVolumeInfo;
}
================================================
FILE: externs/air/flash/html/ControlInitializationError.hx
================================================
package flash.html;
extern class ControlInitializationError extends flash.errors.Error
{
function new():Void;
}
================================================
FILE: externs/air/flash/html/HTMLBitmap.hx
================================================
package flash.html;
extern class HTMLBitmap
{
function new(bitmap:flash.display.BitmapData):Void;
}
================================================
FILE: externs/air/flash/html/HTMLHistoryItem.hx
================================================
package flash.html;
extern class HTMLHistoryItem
{
var isPost(default, never):Bool;
var originalUrl(default, never):String;
var title(default, never):String;
var url(default, never):String;
function new(url:String, originalUrl:String, isPost:Bool, title:String):Void;
}
================================================
FILE: externs/air/flash/html/HTMLHost.hx
================================================
package flash.html;
extern class HTMLHost
{
var htmlLoader(default, never):HTMLLoader;
var windowRect:flash.geom.Rectangle;
function new(defaultBehaviors:Bool = true):Void;
function createWindow(windowCreateOptions:HTMLWindowCreateOptions):HTMLLoader;
// function setHTMLControl(loader : HTMLLoader) : Void;
function updateLocation(locationURL:String):Void;
function updateStatus(status:String):Void;
function updateTitle(title:String):Void;
function windowBlur():Void;
function windowClose():Void;
function windowFocus():Void;
}
================================================
FILE: externs/air/flash/html/HTMLLoader.hx
================================================
package flash.html;
extern class HTMLLoader extends flash.display.Sprite
{
var authenticate:Bool;
var cacheResponse:Bool;
var contentHeight(default, never):Float;
var contentWidth(default, never):Float;
var hasFocusableContent(default, never):Bool;
var historyLength(default, never):UInt;
var historyPosition:UInt;
var htmlHost:HTMLHost;
var idleTimeout:Float;
var loaded(default, never):Bool;
var location(default, never):String;
var manageCookies:Bool;
var navigateInSystemBrowser:Bool;
var pageApplicationDomain(default, never):flash.system.ApplicationDomain;
var paintsDefaultBackground:Bool;
var placeLoadStringContentInApplicationSandbox:Bool;
var runtimeApplicationDomain:flash.system.ApplicationDomain;
var scrollH:Float;
var scrollV:Float;
var textEncodingFallback:String;
var textEncodingOverride:String;
var useCache:Bool;
var userAgent:String;
var window(default, never):Dynamic;
function new():Void;
function cancelLoad():Void;
function getHistoryAt(position:UInt):HTMLHistoryItem;
function historyBack():Void;
function historyForward():Void;
function historyGo(steps:Int):Void;
function load(urlRequestToLoad:flash.net.URLRequest):Void;
function loadString(htmlContent:String):Void;
function reload():Void;
static var isSupported(default, never):Bool;
static var pdfCapability(default, never):Int;
static var swfCapability(default, never):Int;
static function createRootWindow(visible:Bool = true, ?windowInitOptions:flash.display.NativeWindowInitOptions, scrollBarsVisible:Bool = true,
?bounds:flash.geom.Rectangle):HTMLLoader;
}
================================================
FILE: externs/air/flash/html/HTMLPDFCapability.hx
================================================
package flash.html;
extern class HTMLPDFCapability
{
static var ERROR_CANNOT_LOAD_READER(default, never):Int;
static var ERROR_INSTALLED_READER_NOT_FOUND(default, never):Int;
static var ERROR_INSTALLED_READER_TOO_OLD(default, never):Int;
static var ERROR_PREFERRED_READER_TOO_OLD(default, never):Int;
static var STATUS_OK(default, never):Int;
}
================================================
FILE: externs/air/flash/html/HTMLPopupWindow.hx
================================================
package flash.html;
@:final extern class HTMLPopupWindow
{
function new(owner:HTMLLoader, closePopupWindowIfNeededClosure:Dynamic, setDeactivateClosure:Dynamic, computedFontSize:Float):Void;
function close():Void;
function isActive():Bool;
}
================================================
FILE: externs/air/flash/html/HTMLSWFCapability.hx
================================================
package flash.html;
extern class HTMLSWFCapability
{
static var ERROR_INSTALLED_PLAYER_NOT_FOUND(default, never):Int;
static var ERROR_INSTALLED_PLAYER_TOO_OLD(default, never):Int;
static var STATUS_OK(default, never):Int;
}
================================================
FILE: externs/air/flash/html/HTMLWindowCreateOptions.hx
================================================
package flash.html;
extern class HTMLWindowCreateOptions
{
var fullscreen:Bool;
var height:Float;
var locationBarVisible:Bool;
var menuBarVisible:Bool;
var resizable:Bool;
var scrollBarsVisible:Bool;
var statusBarVisible:Bool;
var toolBarVisible:Bool;
var width:Float;
var x:Float;
var y:Float;
function new():Void;
}
================================================
FILE: externs/air/flash/html/ResourceLoader.hx
================================================
package flash.html;
extern class ResourceLoader
{
function new(urlReq:flash.net.URLRequest, htmlControl:HTMLLoader, ?isStageWebViewRequest:Bool):Void;
function cancel():Void;
// static var s_AboutURLScheme(default,never) : String;
// static var s_AppStorageURLScheme(default,never) : String;
// static var s_AppURLScheme(default,never) : String;
// static var s_DataURLScheme(default,never) : String;
// static var s_FileURLScheme(default,never) : String;
// static var s_FtpURLScheme(default,never) : String;
// static var s_HttpURLScheme(default,never) : String;
// static var s_HttpsURLScheme(default,never) : String;
// static var s_MailToURLScheme(default,never) : String;
}
================================================
FILE: externs/air/flash/html/__HTMLScriptArray.hx
================================================
package flash.html;
extern class __HTMLScriptArray extends Array implements Dynamic
{
function new():Void;
}
================================================
FILE: externs/air/flash/html/__HTMLScriptFunction.hx
================================================
package flash.html;
extern class __HTMLScriptFunction implements Dynamic
{
function new():Void;
}
================================================
FILE: externs/air/flash/html/__HTMLScriptObject.hx
================================================
package flash.html;
extern class __HTMLScriptObject implements Dynamic
{
function new():Void;
}
================================================
FILE: externs/air/flash/html/script/Package.hx
================================================
package flash.html.script;
extern class Package extends flash.utils.Proxy
{
function new(parent:Package, packageName:String, appDomain:flash.system.ApplicationDomain):Void;
}
================================================
FILE: externs/air/flash/html/script/PropertyEnumHelper.hx
================================================
package flash.html.script;
extern class PropertyEnumHelper
{
function new(enumPropertiesClosure:Dynamic, getPropertyClosure:Dynamic):Void;
function nextName(index:Int):String;
function nextNameIndex(lastIndex:Int):Int;
function nextValue(index:Int):Dynamic;
}
================================================
FILE: externs/air/flash/media/AudioPlaybackMode.hx
================================================
package flash.media;
@:native("flash.media.AudioPlaybackMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract AudioPlaybackMode(String)
{
var AMBIENT = "ambient";
var MEDIA = "media";
var VOICE = "voice";
}
================================================
FILE: externs/air/flash/media/CameraPosition.hx
================================================
package flash.media;
@:native("flash.media.CameraPosition")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract CameraPosition(String)
{
var BACK = "back";
var FRONT = "front";
var UNKNOWN = "unknown";
}
================================================
FILE: externs/air/flash/media/CameraRoll.hx
================================================
package flash.media;
extern class CameraRoll extends flash.events.EventDispatcher
{
function new():Void;
function addBitmapData(bitmapData:flash.display.BitmapData):Void;
function browseForImage(?value:CameraRollBrowseOptions):Void;
function requestPermission():Void;
static var permissionStatus(default, never):String;
static var supportsAddBitmapData(default, never):Bool;
static var supportsBrowseForImage(default, never):Bool;
}
================================================
FILE: externs/air/flash/media/CameraRollBrowseOptions.hx
================================================
package flash.media;
extern class CameraRollBrowseOptions
{
var height:Float;
var origin:flash.geom.Rectangle;
var width:Float;
function new():Void;
}
================================================
FILE: externs/air/flash/media/CameraUI.hx
================================================
package flash.media;
extern class CameraUI extends flash.events.EventDispatcher
{
function new():Void;
function launch(requestedMediaType:String):Void;
function requestPermission():Void;
static var isSupported(default, never):Bool;
static var permissionStatus(default, never):String;
}
================================================
FILE: externs/air/flash/media/IFilePromise.hx
================================================
package flash.media;
extern interface IFilePromise
{
// var file(default,never) : flash.filesystem.File;
var isAsync(default, never):Bool;
// var mediaType(default,never) : String;
var relativePath(default, never):String;
// function new() : Void;
function close():Void;
function open():flash.utils.IDataInput;
function reportError(e:flash.events.ErrorEvent):Void;
}
================================================
FILE: externs/air/flash/media/InputMediaStream.hx
================================================
package flash.media;
extern class InputMediaStream extends flash.events.EventDispatcher implements flash.utils.IDataInput
{
var bytesAvailable(default, never):UInt;
var endian:flash.utils.Endian;
var objectEncoding:#if openfl openfl.net.ObjectEncoding #else UInt #end;
// function new() : Void;
function close():Dynamic;
function open():Dynamic;
function readBoolean():Bool;
function readByte():Int;
function readBytes(bytes:flash.utils.ByteArray, ?offset:UInt, ?length:UInt):Void;
function readDouble():Float;
function readFloat():Float;
function readInt():Int;
function readMultiByte(length:UInt, charSet:String):String;
function readObject():Dynamic;
function readShort():Int;
function readUTF():String;
function readUTFBytes(length:UInt):String;
function readUnsignedByte():UInt;
function readUnsignedInt():UInt;
function readUnsignedShort():UInt;
}
================================================
FILE: externs/air/flash/media/MediaPromise.hx
================================================
package flash.media;
extern class MediaPromise extends flash.events.EventDispatcher implements flash.desktop.IFilePromise
{
var file(default, never):flash.filesystem.File;
var isAsync(default, never):Bool;
var mediaType(default, never):String;
var relativePath(default, never):String;
function new():Void;
function close():Void;
function open():flash.utils.IDataInput;
function reportError(e:flash.events.ErrorEvent):Void;
}
================================================
FILE: externs/air/flash/media/MediaType.hx
================================================
package flash.media;
@:native("flash.media.MediaType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract MediaType(String)
{
var IMAGE = "image";
var VIDEO = "video";
}
================================================
FILE: externs/air/flash/media/StageWebView.hx
================================================
package flash.media;
@:final extern class StageWebView extends flash.events.EventDispatcher
{
var isHistoryBackEnabled(default, never):Bool;
var isHistoryForwardEnabled(default, never):Bool;
var location(default, never):String;
var mediaPlaybackRequiresUserAction:Bool;
var stage:flash.display.Stage;
var title(default, never):String;
var viewPort:flash.geom.Rectangle;
function new():Void;
function assignFocus(direction:flash.display.FocusDirection = flash.display.FocusDirection.NONE):Void;
function dispose():Void;
function drawViewPortToBitmapData(bitmap:flash.display.BitmapData):Void;
function historyBack():Void;
function historyForward():Void;
function loadString(text:String, ?mimeType:String):Void;
function loadURL(url:String):Void;
function reload():Void;
function stop():Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/media/StageWebViewImpl.hx
================================================
package flash.media;
extern class StageWebViewImpl extends flash.display.Sprite
{
function new():Void;
}
================================================
FILE: externs/air/flash/net/DatagramSocket.hx
================================================
package flash.net;
extern class DatagramSocket extends flash.events.EventDispatcher
{
var bound(default, never):Bool;
var connected(default, never):Bool;
var localAddress(default, never):String;
var localPort(default, never):Int;
var remoteAddress(default, never):String;
var remotePort(default, never):Int;
function new():Void;
function bind(localPort:Int = 0, localAddress:String = "0.0.0.0"):Void;
function close():Void;
function connect(remoteAddress:String, remotePort:Int):Void;
function receive():Void;
function send(bytes:flash.utils.ByteArray, offset:UInt = 0, length:UInt = 0, ?address:String, port:Int = 0):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/net/FileReference.hx
================================================
package flash.net;
extern class FileReference extends flash.events.EventDispatcher
{
var creationDate(default, never):Date;
var creator(default, never):String;
@:require(flash10) var data(default, never):flash.utils.ByteArray;
#if air
var extension(default, never):String;
#end
var modificationDate(default, never):Date;
var name(default, never):String;
var size(default, never):Float;
var type(default, never):String;
function new():Void;
function browse(?typeFilter:Array):Bool;
function cancel():Void;
function download(request:URLRequest, ?defaultFileName:String):Void;
@:require(flash10) function load():Void;
@:require(flash10) function save(data:Dynamic, ?defaultFileName:String):Void;
function upload(request:URLRequest, ?uploadDataFieldName:String, testUpload:Bool = false):Void;
#if air
function uploadUnencoded(request:URLRequest):Void;
#end
}
================================================
FILE: externs/air/flash/net/IPVersion.hx
================================================
package flash.net;
@:native("flash.net.IPVersion")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract IPVersion(String)
{
var IPV4 = "ipv4";
var IPV6 = "ipv6";
}
================================================
FILE: externs/air/flash/net/InterfaceAddress.hx
================================================
package flash.net;
extern class InterfaceAddress
{
var address:String;
var broadcast:String;
var ipVersion:String;
var prefixLength:Int;
function new():Void;
}
================================================
FILE: externs/air/flash/net/NetworkInfo.hx
================================================
package flash.net;
extern class NetworkInfo extends flash.events.EventDispatcher
{
function new():Void;
function findInterfaces():flash.Vector;
static var isSupported(default, never):Bool;
static var networkInfo(default, never):NetworkInfo;
}
================================================
FILE: externs/air/flash/net/NetworkInterface.hx
================================================
package flash.net;
extern class NetworkInterface
{
var active:Bool;
var addresses:flash.Vector;
var displayName:String;
var hardwareAddress:String;
var mtu:Int;
var name:String;
var parent:NetworkInterface;
var subInterfaces:flash.Vector;
function new():Void;
}
================================================
FILE: externs/air/flash/net/ServerSocket.hx
================================================
package flash.net;
extern class ServerSocket extends flash.events.EventDispatcher
{
var bound(default, never):Bool;
var listening(default, never):Bool;
var localAddress(default, never):String;
var localPort(default, never):Int;
function new():Void;
function bind(localPort:Int = 0, localAddress:String = "0.0.0.0"):Void;
function close():Void;
function listen(backlog:Int = 0):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/net/Socket.hx
================================================
package flash.net;
extern class Socket extends flash.events.EventDispatcher implements flash.utils.IDataOutput implements flash.utils.IDataInput
{
#if (haxe_ver < 4.3)
var bytesAvailable(default, never):UInt;
@:require(flash11) var bytesPending(default, never):UInt;
var connected(default, never):Bool;
var endian:flash.utils.Endian;
var objectEncoding:#if openfl openfl.net.ObjectEncoding #else UInt #end;
@:require(flash10) var timeout:UInt;
#if air
var localAddress(default, never):String;
var localPort(default, never):Int;
var remoteAddress(default, never):String;
var remotePort(default, never):Int;
#end
#else
@:flash.property var bytesAvailable(get, never):UInt;
@:flash.property @:require(flash11) var bytesPending(get, never):UInt;
@:flash.property var connected(get, never):Bool;
@:flash.property var endian(get, set):flash.utils.Endian;
@:flash.property var objectEncoding(get, set):#if openfl openfl.net.ObjectEncoding #else UInt #end;
@:flash.property @:require(flash10) var timeout(get, set):UInt;
#if air
@:flash.property var localAddress(get, never):String;
@:flash.property var localPort(get, never):Int;
@:flash.property var remoteAddress(get, never):String;
@:flash.property var remotePort(get, never):Int;
#end
#end
function new(?host:String, port:Int = 0):Void;
function close():Void;
function connect(host:String, port:Int):Void;
function flush():Void;
function readBoolean():Bool;
function readByte():Int;
function readBytes(bytes:flash.utils.ByteArray, offset:UInt = 0, length:UInt = 0):Void;
function readDouble():Float;
function readFloat():Float;
function readInt():Int;
function readMultiByte(length:UInt, charSet:String):String;
function readObject():Dynamic;
function readShort():Int;
function readUTF():String;
function readUTFBytes(length:UInt):String;
function readUnsignedByte():UInt;
function readUnsignedInt():UInt;
function readUnsignedShort():UInt;
function writeBoolean(value:Bool):Void;
function writeByte(value:Int):Void;
function writeBytes(bytes:flash.utils.ByteArray, offset:UInt = 0, length:UInt = 0):Void;
function writeDouble(value:Float):Void;
function writeFloat(value:Float):Void;
function writeInt(value:Int):Void;
function writeMultiByte(value:String, charSet:String):Void;
function writeObject(object:Dynamic):Void;
function writeShort(value:Int):Void;
function writeUTF(value:String):Void;
function writeUTFBytes(value:String):Void;
function writeUnsignedInt(value:UInt):Void;
#if (haxe_ver >= 4.3)
private function get_bytesAvailable():UInt;
private function get_bytesPending():UInt;
private function get_connected():Bool;
private function get_endian():flash.utils.Endian;
private function get_objectEncoding():#if openfl openfl.net.ObjectEncoding #else UInt #end;
private function get_timeout():UInt;
#if air
private function get_localAddress():String;
private function get_localPort():Int;
private function get_remoteAddress():String;
private function get_remotePort():Int;
#end
private function set_endian(value:flash.utils.Endian):flash.utils.Endian;
private function set_objectEncoding(value:#if openfl openfl.net.ObjectEncoding #else UInt #end):#if openfl openfl.net.ObjectEncoding #else UInt #end;
private function set_timeout(value:UInt):UInt;
#end
}
================================================
FILE: externs/air/flash/net/URLRequest.hx
================================================
package flash.net;
@:final extern class URLRequest
{
#if air
var authenticate:Bool;
var cacheResponse:Bool;
#end
var contentType:String;
var data:Dynamic;
var digest:String;
#if air
var followRedirects:Bool;
var idleTimeout:Float;
var manageCookies:Bool;
#end
var method:String;
var requestHeaders:Array;
var url:String;
#if air
var useCache:Bool;
var userAgent:String;
#end
function new(?url:String):Void;
function useRedirectedURL(sourceRequest:URLRequest, wholeURL:Bool = false, ?pattern:Dynamic, ?replace:String):Void;
}
================================================
FILE: externs/air/flash/net/URLRequestDefaults.hx
================================================
package flash.net;
extern class URLRequestDefaults
{
static var authenticate:Bool;
static var cacheResponse:Bool;
static var followRedirects:Bool;
static var idleTimeout:Float;
static var manageCookies:Bool;
static var useCache:Bool;
static var userAgent:String;
static function setLoginCredentialsForHost(hostname:String, user:String, password:String):Dynamic;
}
================================================
FILE: externs/air/flash/net/dns/AAAARecord.hx
================================================
package flash.net.dns;
extern class AAAARecord extends ResourceRecord
{
var address:String;
function new():Void;
}
================================================
FILE: externs/air/flash/net/dns/ARecord.hx
================================================
package flash.net.dns;
extern class ARecord extends ResourceRecord
{
var address:String;
function new():Void;
}
================================================
FILE: externs/air/flash/net/dns/DNSResolver.hx
================================================
package flash.net.dns;
extern class DNSResolver extends flash.events.EventDispatcher
{
function new():Void;
function lookup(host:String, recordType:Class):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/net/dns/MXRecord.hx
================================================
package flash.net.dns;
extern class MXRecord extends ResourceRecord
{
var exchange:String;
var preference:Int;
function new():Void;
}
================================================
FILE: externs/air/flash/net/dns/PTRRecord.hx
================================================
package flash.net.dns;
extern class PTRRecord extends ResourceRecord
{
var ptrdName:String;
function new():Void;
}
================================================
FILE: externs/air/flash/net/dns/ResourceRecord.hx
================================================
package flash.net.dns;
extern class ResourceRecord
{
var name:String;
var ttl:Int;
function new():Void;
}
================================================
FILE: externs/air/flash/net/dns/SRVRecord.hx
================================================
package flash.net.dns;
extern class SRVRecord extends ResourceRecord
{
var port:Int;
var priority:Int;
var target:String;
var weight:Int;
function new():Void;
}
================================================
FILE: externs/air/flash/net/drm/DRMAddToDeviceGroupContext.hx
================================================
package flash.net.drm;
extern class DRMAddToDeviceGroupContext extends DRMManagerSession
{
function new():Void;
function addToDeviceGroup(deviceGroup:DRMDeviceGroup, forceRefresh:Bool):Void;
}
================================================
FILE: externs/air/flash/net/drm/DRMManager.hx
================================================
package flash.net.drm;
extern class DRMManager extends flash.events.EventDispatcher
{
function new():Void;
function addToDeviceGroup(deviceGroup:DRMDeviceGroup, forceRefresh:Bool = false):Void;
function authenticate(serverURL:String, domain:String, username:String, password:String):Void;
function loadPreviewVoucher(contentData:DRMContentData):Void;
function loadVoucher(contentData:DRMContentData, setting:String):Void;
function removeFromDeviceGroup(deviceGroup:DRMDeviceGroup):Void;
function resetDRMVouchers():Void;
function resetDRMVouchersInternal(isAutoReset:Bool):Void;
function returnVoucher(inServerURL:String, immediateCommit:Bool, licenseID:String, policyID:String):Void;
function setAuthenticationToken(serverUrl:String, domain:String, token:flash.utils.ByteArray):Void;
function storeVoucher(voucher:flash.utils.ByteArray):Void;
static var isSupported(default, never):Bool;
static var networkIdleTimeout:Float;
static function getDRMManager():DRMManager;
static function getDRMManagerInternal():DRMManager;
}
================================================
FILE: externs/air/flash/net/drm/DRMRemoveFromDeviceGroupContext.hx
================================================
package flash.net.drm;
extern class DRMRemoveFromDeviceGroupContext extends DRMManagerSession
{
function new():Void;
function removeFromDeviceGroup(deviceGroup:DRMDeviceGroup):Void;
}
================================================
FILE: externs/air/flash/net/drm/VoucherAccessInfo.hx
================================================
package flash.net.drm;
@:final extern class VoucherAccessInfo
{
var authenticationMethod(default, never):String;
var deviceGroup(default, never):DRMDeviceGroup;
var displayName(default, never):String;
var domain(default, never):String;
var policyID(default, never):String;
function new():Void;
}
================================================
FILE: externs/air/flash/notifications/NotificationStyle.hx
================================================
package flash.notifications;
@:native("flash.notifications.NotificationStyle")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract NotificationStyle(String)
{
var ALERT = "alert";
var BADGE = "badge";
var SOUND = "sound";
}
================================================
FILE: externs/air/flash/notifications/RemoteNotifier.hx
================================================
package flash.notifications;
extern class RemoteNotifier extends flash.events.EventDispatcher
{
function new():Void;
function subscribe(?options:RemoteNotifierSubscribeOptions):Void;
function unsubscribe():Void;
static var supportedNotificationStyles(default, never):flash.Vector;
}
================================================
FILE: externs/air/flash/notifications/RemoteNotifierSubscribeOptions.hx
================================================
package flash.notifications;
@:final extern class RemoteNotifierSubscribeOptions
{
var notificationStyles:flash.Vector;
function new():Void;
}
================================================
FILE: externs/air/flash/permissions/PermissionStatus.hx
================================================
package flash.permissions;
extern class PermissionStatus
{
function new():Void;
static var DENIED(default, never):String;
static var GRANTED(default, never):String;
static var UNKNOWN(default, never):String;
}
================================================
FILE: externs/air/flash/printing/PaperSize.hx
================================================
package flash.printing;
@:native("flash.printing.PaperSize")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract PaperSize(String)
{
var A4 = "a4";
var A5 = "a5";
var A6 = "a6";
var CHOUKEI3GOU = "choukei3gou";
var CHOUKEI4GOU = "choukei4gou";
var ENV_10 = "env_10";
var ENV_B5 = "env_b5";
var ENV_C5 = "env_c5";
var ENV_DL = "env_dl";
var ENV_MONARCH = "env_monarch";
var ENV_PERSONAL = "env_personal";
var EXECUTIVE = "executive";
var FOLIO = "folio";
var JIS_B5 = "jis_b5";
var LEGAL = "legal";
var LETTER = "letter";
var STATEMENT = "statement";
}
================================================
FILE: externs/air/flash/printing/PrintJob.hx
================================================
package flash.printing;
extern class PrintJob extends flash.events.EventDispatcher
{
#if air
var copies:Int;
var firstPage(default, never):Int;
var isColor(default, never):Bool;
var jobName:String;
var lastPage(default, never):Int;
var maxPixelsPerInch(default, never):Float;
#end
var orientation(default, never):PrintJobOrientation;
var pageHeight(default, never):Int;
var pageWidth(default, never):Int;
#if air
var paperArea(default, never):flash.geom.Rectangle;
#end
var paperHeight(default, never):Int;
var paperWidth(default, never):Int;
#if air
var printableArea(default, never):flash.geom.Rectangle;
var printer:String;
#end
function new():Void;
function addPage(sprite:flash.display.Sprite, ?printArea:flash.geom.Rectangle, ?options:PrintJobOptions, frameNum:Int = 0):Void;
#if air
function selectPaperSize(paperSize:PaperSize):Void;
#end
function send():Void;
#if air
function showPageSetupDialog():Bool;
#end
function start():Bool;
#if air
function start2(?uiOptions:PrintUIOptions, showPrintDialog:Bool = true):Bool;
function terminate():Void;
static var active(default, never):Bool;
#end
@:require(flash10_1) static var isSupported(default, never):Bool;
#if air
static var printers(default, never):flash.Vector;
static var supportsPageSetupDialog(default, never):Bool;
#end
}
================================================
FILE: externs/air/flash/printing/PrintJobOptions.hx
================================================
package flash.printing;
extern class PrintJobOptions
{
#if air
var pixelsPerInch:Float;
#end
var printAsBitmap:Bool;
#if air
var printMethod:PrintMethod;
#end
function new(printAsBitmap:Bool = false):Void;
}
================================================
FILE: externs/air/flash/printing/PrintMethod.hx
================================================
package flash.printing;
@:native("flash.printing.PrintMethod")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract PrintMethod(String)
{
var AUTO = "auto";
var BITMAP = "bitmap";
var VECTOR = "vector";
}
================================================
FILE: externs/air/flash/printing/PrintUIOptions.hx
================================================
package flash.printing;
@:final extern class PrintUIOptions
{
var disablePageRange:Bool;
var maxPage:UInt;
var minPage:UInt;
function new():Void;
}
================================================
FILE: externs/air/flash/sampler/ScriptMember.hx
================================================
package flash.sampler;
@:final extern class ScriptMember
{
var id(default, never):Float;
var propertyName(default, never):String;
function new():Void;
}
================================================
FILE: externs/air/flash/sampler/ScriptSampler.hx
================================================
package flash.sampler;
extern class ScriptSampler
{
function new():Void;
static function getFilename(p1:Float):String;
static function getInvocationCount(p1:Float):Float;
static function getMembers(p1:Float):flash.Vector;
static function getName(p1:Float):String;
static function getSize(p1:Float):Float;
static function getType(p1:Float):String;
}
================================================
FILE: externs/air/flash/security/AVMPlusDigest.hx
================================================
package flash.security;
extern class AVMPlusDigest
{
function new():Void;
function FinishDigest(inDigestToCompare:String):UInt;
function Init(algorithm:UInt):Void;
function Update(data:flash.utils.IDataInput):UInt;
function UpdateWithString(data:String):UInt;
static var DIGESTMETHOD_SHA256(default, never):UInt;
}
================================================
FILE: externs/air/flash/security/CryptContext.hx
================================================
package flash.security;
extern class CryptContext extends flash.events.EventDispatcher
{
var signerCN(default, never):String;
var signerDN(default, never):String;
var signerValidEnd(default, never):UInt;
var verificationTime(default, never):UInt;
function new():Void;
function HasValidVerifySession():Bool;
function VerifySigASync(sig:String, data:String, ignoreCertTime:Bool):Void;
function VerifySigSync(sig:String, data:String, ignoreCertTime:Bool):Void;
function addCRLRevEvidenceBase64(crl:String):Void;
function addCRLRevEvidenceRaw(crl:flash.utils.ByteArray):Void;
function addChainBuildingCertBase64(cert:String, trusted:Bool):Void;
function addChainBuildingCertRaw(cert:flash.utils.ByteArray, trusted:Bool):Void;
function addTimestampingRootRaw(cert:flash.utils.ByteArray):Void;
function getDataTBVStatus():UInt;
function getIDStatus():UInt;
function getIDSummaryFromSigChain(version:UInt):String;
function getOverallStatus():UInt;
function getPublicKey(cert:String):flash.utils.ByteArray;
function getRevCheckSetting():String;
function getSignerExtendedKeyUsages():Array;
function getSignerIDSummary(version:UInt):String;
function getSignerTrustFlags():UInt;
function getSignerTrustSettings():Array;
function getTimestampRevCheckSetting():String;
function getUseSystemTrustStore():Bool;
function setRevCheckSetting(setting:String):Void;
function setSignerCert(cert:String):Dynamic;
function setSignerCertDN(dn:String):Dynamic;
function setTimestampRevCheckSetting(setting:String):Void;
function useCodeSigningValidationRules():Void;
function useSystemTrustStore(trusted:Bool):Void;
function verifyTimestamp(tsp:String, data:String, ignoreCertTime:Bool):Void;
static var REVCHECK_ALWAYSREQUIRED(default, never):UInt;
static var REVCHECK_BEST_EFFORT(default, never):UInt;
static var REVCHECK_NEVER(default, never):UInt;
static var REVCHECK_REQUIRED_IF_AVAILABLE(default, never):UInt;
static var STATUS_INVALID(default, never):UInt;
static var STATUS_TROUBLE(default, never):UInt;
static var STATUS_UNKNOWN(default, never):UInt;
static var STATUS_VALID(default, never):UInt;
static var TRUSTFLAG_CODESIGNING(default, never):UInt;
static var TRUSTFLAG_PLAYLISTSIGNING(default, never):UInt;
static var TRUSTFLAG_SIGNING(default, never):UInt;
}
================================================
FILE: externs/air/flash/security/IURIDereferencer.hx
================================================
package flash.security;
extern interface IURIDereferencer
{
function dereference(uri:String):flash.utils.IDataInput;
}
================================================
FILE: externs/air/flash/security/ReferencesValidationSetting.hx
================================================
package flash.security;
@:native("flash.security.ReferencesValidationSetting")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract ReferencesValidationSetting(String)
{
var NEVER = "never";
var VALID_IDENTITY = "validIdentity";
var VALID_OR_UNKNOWN_IDENTITY = "validOrUnknownIdentity";
}
================================================
FILE: externs/air/flash/security/RevocationCheckSettings.hx
================================================
package flash.security;
@:native("flash.security.RevocationCheckSettings")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract RevocationCheckSettings(String)
{
var ALWAYS_REQUIRED = "alwaysRequired";
var BEST_EFFORT = "bestEffort";
var NEVER = "never";
var REQUIRED_IF_AVAILABLE = "requiredIfAvailable";
}
================================================
FILE: externs/air/flash/security/SignatureStatus.hx
================================================
package flash.security;
@:native("flash.security.SignatureStatus")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SignatureStatus(String)
{
var INVALID = "invalid";
var UNKNOWN = "unknown";
var VALID = "valid";
}
================================================
FILE: externs/air/flash/security/SignerTrustSettings.hx
================================================
package flash.security;
@:native("flash.security.SignerTrustSettings")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SignerTrustSettings(String)
{
var CODE_SIGNING = "codeSigning";
var PLAYLIST_SIGNING = "playlistSigning";
var SIGNING = "signing";
}
================================================
FILE: externs/air/flash/security/XMLCanonicalizer.hx
================================================
package flash.security;
extern class XMLCanonicalizer
{
function new():Void;
function CanonicalizeXML(xml:flash.xml.XML):String;
function CanonicalizeXMLList(xmlList:flash.xml.XMLList):String;
}
================================================
FILE: externs/air/flash/security/XMLSignatureEnvelopedTransformer.hx
================================================
package flash.security;
extern class XMLSignatureEnvelopedTransformer
{
function new():Void;
function transform(sig:flash.xml.XML, doc:flash.xml.XML):flash.xml.XML;
}
================================================
FILE: externs/air/flash/security/XMLSignatureValidator.hx
================================================
package flash.security;
extern class XMLSignatureValidator extends flash.events.EventDispatcher
{
var digestStatus(default, never):String;
var identityStatus(default, never):String;
var referencesStatus(default, never):String;
var referencesValidationSetting:ReferencesValidationSetting;
var revocationCheckSetting:RevocationCheckSettings;
var signerCN(default, never):String;
var signerDN(default, never):String;
var signerExtendedKeyUsages(default, never):Array;
var signerTrustSettings(default, never):Array;
var uriDereferencer:IURIDereferencer;
var useSystemTrustStore:Bool;
var validityStatus(default, never):String;
function new():Void;
function addCertificate(cert:flash.utils.ByteArray, trusted:Bool):Dynamic;
function verify(signature:flash.xml.XML):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/sensors/DeviceRotation.hx
================================================
package flash.sensors;
extern class DeviceRotation extends flash.events.EventDispatcher
{
var muted(default, never):Bool;
function new():Void;
function setRequestedUpdateInterval(interval:Float):Void;
static var isSupported(default, never):Bool;
}
================================================
FILE: externs/air/flash/system/Capabilities.hx
================================================
package flash.system;
extern class Capabilities
{
static var _internal(default, never):UInt;
static var avHardwareDisable(default, never):Bool;
@:require(flash10_1) static var cpuArchitecture(default, never):String;
static var hasAccessibility(default, never):Bool;
static var hasAudio(default, never):Bool;
static var hasAudioEncoder(default, never):Bool;
static var hasEmbeddedVideo(default, never):Bool;
static var hasIME(default, never):Bool;
static var hasMP3(default, never):Bool;
static var hasPrinting(default, never):Bool;
static var hasScreenBroadcast(default, never):Bool;
static var hasScreenPlayback(default, never):Bool;
static var hasStreamingAudio(default, never):Bool;
static var hasStreamingVideo(default, never):Bool;
static var hasTLS(default, never):Bool;
static var hasVideoEncoder(default, never):Bool;
static var isDebugger(default, never):Bool;
@:require(flash10) static var isEmbeddedInAcrobat(default, never):Bool;
static var language(default, never):String;
#if air
static var languages(default, never):Array;
#end
static var localFileReadDisable(default, never):Bool;
static var manufacturer(default, never):String;
@:require(flash10) static var maxLevelIDC(default, never):String;
static var os(default, never):String;
static var pixelAspectRatio(default, never):Float;
static var playerType(default, never):String;
static var screenColor(default, never):String;
static var screenDPI(default, never):Float;
static var screenResolutionX(default, never):Float;
static var screenResolutionY(default, never):Float;
static var serverString(default, never):String;
@:require(flash10_1) static var supports32BitProcesses(default, never):Bool;
@:require(flash10_1) static var supports64BitProcesses(default, never):Bool;
@:require(flash10_1) static var touchscreenType(default, never):TouchscreenType;
static var version(default, never):String;
@:require(flash11) static function hasMultiChannelAudio(type:String):Bool;
}
================================================
FILE: externs/air/flash/system/SecurityPrivilege.hx
================================================
package flash.system;
extern class SecurityPrivilege
{
function new():Void;
static var FILE(default, never):Dynamic;
static var FILE_APPSTORE(default, never):Dynamic;
static var FILE_PATHACCESS(default, never):Dynamic;
static var FILE_READ(default, never):Dynamic;
static var FILE_TEMP(default, never):Dynamic;
static var FILE_WRITE(default, never):Dynamic;
static var FILE_WRITE_RESOURCE(default, never):Dynamic;
static var HTML(default, never):Dynamic;
static var HTTP_ALL(default, never):Dynamic;
static var SCREEN(default, never):Dynamic;
static var WINDOW(default, never):Dynamic;
}
================================================
FILE: externs/air/flash/text/AutoCapitalize.hx
================================================
package flash.text;
@:native("flash.text.AutoCapitalize")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract AutoCapitalize(String)
{
var ALL = "all";
var NONE = "none";
var SENTENCE = "sentence";
var WORD = "word";
}
================================================
FILE: externs/air/flash/text/ReturnKeyLabel.hx
================================================
package flash.text;
@:native("flash.text.ReturnKeyLabel")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract ReturnKeyLabel(String)
{
var DEFAULT = "default";
var DONE = "done";
var GO = "go";
var NEXT = "next";
var SEARCH = "search";
}
================================================
FILE: externs/air/flash/text/SoftKeyboardType.hx
================================================
package flash.text;
@:native("flash.text.SoftKeyboardType")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract SoftKeyboardType(String)
{
var CONTACT = "contact";
var DEFAULT = "default";
var EMAIL = "email";
var NUMBER = "number";
var PUNCTUATION = "punctuation";
var URL = "url";
}
================================================
FILE: externs/air/flash/text/StageText.hx
================================================
package flash.text;
@:final extern class StageText extends flash.events.EventDispatcher
{
var autoCapitalize:AutoCapitalize;
var autoCorrect:Bool;
var clearButtonMode(never, default):StageTextClearButtonMode;
var color:UInt;
var displayAsPassword:Bool;
var editable:Bool;
var fontFamily:String;
var fontPosture:flash.text.engine.FontPosture;
var fontSize:Int;
var fontWeight:flash.text.engine.FontWeight;
var locale:String;
var maxChars:Int;
var multiline(default, never):Bool;
var restrict:String;
var returnKeyLabel:ReturnKeyLabel;
var selectionActiveIndex(default, never):Int;
var selectionAnchorIndex(default, never):Int;
var softKeyboardType:SoftKeyboardType;
var stage:flash.display.Stage;
var text:String;
var textAlign:flash.text.TextFormatAlign;
var viewPort:flash.geom.Rectangle;
var visible:Bool;
function new(?initOptions:StageTextInitOptions):Void;
function assignFocus():Void;
function dispose():Void;
function drawViewPortToBitmapData(bitmap:flash.display.BitmapData):Void;
function selectRange(anchorIndex:Int, activeIndex:Int):Void;
}
================================================
FILE: externs/air/flash/text/StageTextClearButtonMode.hx
================================================
package flash.text;
@:native("flash.text.StageTextClearButtonMode")
#if (haxe_ver >= 4.0) extern enum #else @:extern @:enum #end abstract StageTextClearButtonMode(String)
{
var ALWAYS = "always";
var NEVER = "never";
var UNLESS_EDITING = "unlessEditing";
var WHILE_EDITING = "whileEditing";
}
================================================
FILE: externs/air/flash/text/StageTextImpl.hx
================================================
package flash.text;
extern class StageTextImpl extends flash.display.Sprite
{
function new():Void;
}
================================================
FILE: externs/air/flash/text/StageTextInitOptions.hx
================================================
package flash.text;
extern class StageTextInitOptions
{
var multiline:Bool;
function new(multiline:Bool = false):Void;
}
================================================
FILE: externs/air/flash/ui/ContextMenu.hx
================================================
package flash.ui;
@:final extern class ContextMenu extends flash.display.NativeMenu
{
var builtInItems:ContextMenuBuiltInItems;
@:require(flash10) var clipboardItems:ContextMenuClipboardItems;
@:require(flash10) var clipboardMenu:Bool;
var customItems:Array;
@:require(flash10) var link:flash.net.URLRequest;
function new():Void;
// function clone() : ContextMenu;
function hideBuiltInItems():Void;
@:require(flash10_1) static var isSupported(default, never):Bool;
// override function clone() : flash.display.NativeMenu;
}
================================================
FILE: externs/air/flash/ui/ContextMenuItem.hx
================================================
package flash.ui;
@:final extern class ContextMenuItem #if air extends flash.display.NativeMenuItem #end
{
var caption:String;
var separatorBefore:Bool;
var visible:Bool;
function new(caption:String, separatorBefore:Bool = false, enabled:Bool = true, visible:Bool = true):Void;
#if !air
function clone():ContextMenuItem;
#end
}
================================================
FILE: externs/air/sys/FileSystem.hx
================================================
package sys;
import flash.filesystem.File in FlashFile;
import lime.utils.Log;
@:dce
@:coreApi
class FileSystem
{
public static function exists(path:String):Bool
{
return new FlashFile(path).exists;
}
public static function rename(path:String, newPath:String):Void
{
new FlashFile(path).moveTo(new FlashFile(newPath));
}
public static function stat(path:String):sys.FileStat
{
Log.warn("stat is not implemented");
return null;
}
public static function fullPath(relPath:String):String
{
var flashFile = new FlashFile(relPath);
flashFile.canonicalize();
return flashFile.nativePath;
}
public static function absolutePath(relPath:String):String
{
return new FlashFile(relPath).nativePath;
}
public static function isDirectory(path:String):Bool
{
return new FlashFile(path).isDirectory;
}
public static function createDirectory(path:String):Void
{
new FlashFile(path).createDirectory();
}
public static function deleteFile(path:String):Void
{
new FlashFile(path).deleteFile();
}
public static function deleteDirectory(path:String):Void
{
new FlashFile(path).deleteDirectory(false);
}
public static function readDirectory(path:String):Array
{
return new FlashFile(path).getDirectoryListing().map(function(f:FlashFile):String
{
return f.name;
});
}
}
================================================
FILE: externs/air/sys/io/File.hx
================================================
package sys.io;
import flash.utils.ByteArray;
import flash.filesystem.File in FlashFile;
import flash.filesystem.FileMode;
import flash.filesystem.FileStream;
import lime.utils.Log;
import haxe.io.Bytes;
@:dce
@:coreApi
class File
{
public static function getContent(path:String):String
{
var file:FlashFile = null;
if (Reflect.hasField(FlashFile, "workingDirectory"))
{
file = Reflect.field(FlashFile, "workingDirectory").resolvePath(path);
}
else
{
file = new FlashFile(path);
}
var stream = new FileStream();
stream.open(file, FileMode.READ);
var content = stream.readUTFBytes(stream.bytesAvailable);
stream.close();
return content;
}
public static function saveContent(path:String, content:String):Void
{
var file:FlashFile = null;
if (Reflect.hasField(FlashFile, "workingDirectory"))
{
file = Reflect.field(FlashFile, "workingDirectory").resolvePath(path);
}
else
{
file = new FlashFile(path);
}
var stream = new FileStream();
stream.open(file, FileMode.WRITE);
stream.writeUTFBytes(content);
stream.close();
}
public static function getBytes(path:String):haxe.io.Bytes
{
var file:FlashFile = null;
if (Reflect.hasField(FlashFile, "workingDirectory"))
{
file = Reflect.field(FlashFile, "workingDirectory").resolvePath(path);
}
else
{
file = new FlashFile(path);
}
var stream = new FileStream();
stream.open(file, FileMode.READ);
var byteArray = new ByteArray();
stream.readBytes(byteArray, 0, stream.bytesAvailable);
stream.close();
return Bytes.ofData(byteArray);
}
public static function saveBytes(path:String, bytes:haxe.io.Bytes):Void
{
var byteArray:ByteArray = bytes.getData();
var file:FlashFile = null;
if (Reflect.hasField(FlashFile, "workingDirectory"))
{
file = Reflect.field(FlashFile, "workingDirectory").resolvePath(path);
}
else
{
file = new FlashFile(path);
}
var stream = new FileStream();
stream.open(file, FileMode.WRITE);
stream.writeBytes(byteArray);
stream.close();
}
public static function read(path:String, binary:Bool = true):FileInput
{
Log.warn("read is not implemented");
return null;
}
public static function write(path:String, binary:Bool = true):FileOutput
{
Log.warn("write is not implemented");
return null;
}
public static function append(path:String, binary:Bool = true):FileOutput
{
Log.warn("append is not implemented");
return null;
}
public static function update(path:String, binary:Bool = true):FileOutput
{
Log.warn("update is not implemented");
return null;
}
public static function copy(srcPath:String, dstPath:String):Void
{
var srcFile:FlashFile = null;
var dstFile:FlashFile = null;
if (Reflect.hasField(FlashFile, "workingDirectory"))
{
srcFile = Reflect.field(FlashFile, "workingDirectory").resolvePath(srcPath);
dstFile = Reflect.field(FlashFile, "workingDirectory").resolvePath(dstPath);
}
else
{
srcFile = new FlashFile(srcPath);
dstFile = new FlashFile(dstPath);
}
srcFile.copyTo(dstFile);
}
}
================================================
FILE: externs/air/sys/io/FileInput.hx
================================================
package sys.io;
import haxe.io.Bytes;
import haxe.io.Eof;
import haxe.io.Error;
@:coreApi
class FileInput extends haxe.io.Input
{
private var fd:Int;
private var pos:Int;
@:allow(sys.io.File)
private function new(fd:Int)
{
this.fd = fd;
pos = 0;
}
override public function readByte():Int
{
return 0;
}
override public function readBytes(s:Bytes, pos:Int, len:Int):Int
{
return 0;
}
override public function close():Void {}
public function seek(p:Int, pos:FileSeek):Void
{
switch (pos)
{
case SeekBegin:
// this.pos = p;
case SeekEnd:
// this.pos = cast Fs.fstatSync(fd).size + p;
case SeekCur:
// this.pos += p;
}
}
public function tell():Int
{
return 0;
}
public function eof():Bool
{
return false;
}
}
================================================
FILE: externs/air/sys/io/FileOutput.hx
================================================
package sys.io;
import haxe.io.Bytes;
import haxe.io.Eof;
import haxe.io.Error;
@:coreApi
class FileOutput extends haxe.io.Output
{
private var fd:Int;
private var pos:Int;
@:allow(sys.io.File)
private function new(fd:Int)
{
this.fd = fd;
pos = 0;
}
override public function writeByte(b:Int):Void {}
override public function writeBytes(s:Bytes, pos:Int, len:Int):Int
{
return 0;
}
override public function close():Void {}
public function seek(p:Int, pos:FileSeek):Void
{
switch (pos)
{
case SeekBegin:
// this.pos = p;
case SeekEnd:
// this.pos = cast Fs.fstatSync(fd).size + p;
case SeekCur:
// this.pos += p;
}
}
public function tell():Int
{
return 0;
}
}
================================================
FILE: extraParams.hxml
================================================
--macro lime._internal.macros.DefineMacro.run()
--macro haxe.macro.Compiler.addMetadata("@:autoBuild(lime._internal.macros.AssetsMacro.embedBytes())", "haxe.io.Bytes")
================================================
FILE: haxelib.json
================================================
{
"name": "lime",
"url": "https://github.com/openfl/lime",
"license": "MIT",
"tags": [],
"description": "A foundational Haxe framework for cross-platform development",
"version": "8.3.1",
"releasenote": "Various bug fixes",
"contributors": [
"singmajesty",
"bowlerhat",
"Dimensionscape"
],
"classPath": "src"
}
================================================
FILE: haxelib.xml
================================================
================================================
FILE: hxformat.json
================================================
{
"lineEnds": {
"leftCurly": "both",
"rightCurly": "both"
},
"sameLine": {
"ifBody": "same",
"ifElse": "next",
"doWhile": "next",
"tryBody": "next",
"tryCatch": "next"
}
}
================================================
FILE: include.xml
================================================
================================================
FILE: ndll/Linux/.gitignore
================================================
================================================
FILE: ndll/Linux64/.gitignore
================================================
================================================
FILE: ndll/Mac/.gitignore
================================================
================================================
FILE: ndll/Mac64/.gitignore
================================================
================================================
FILE: ndll/MacArm64/.gitignore
================================================
================================================
FILE: ndll/Windows/.gitignore
================================================
================================================
FILE: package.json
================================================
{
"name": "lime",
"private": true
}
================================================
FILE: project/Build.xml
================================================
================================================
FILE: project/BuildHashlink.xml
================================================
================================================
FILE: project/README.md
================================================
# C++ backend project
Lime uses this C/C++ code to build reusable binaries for native targets, stored in the [ndll directory](https://github.com/openfl/lime/tree/develop/ndll). Binaries for common targets are included in the Haxelib download, so you won't need to build those yourself unless you make changes.
Tip: if you install Lime from Git, you can still copy the ndlls from Lime's latest Haxelib release.
## Project overview
This directory contains two categories of code.
- Lime-specific headers and source files can be found under [include](include) and [src](src), respectively. [`ExternalInterface`](src/ExternalInterface.cpp) serves as the entry point into this code.
- [Submodules](#submodule-projects) such as Cairo, SDL, and OpenAL can be found under [lib](lib).
### Prerequisites
- All platforms require [hxcpp](https://lib.haxe.org/p/hxcpp/).
- Windows requires [Visual Studio C++ components](https://visualstudio.microsoft.com/vs/features/cplusplus/).
- Mac requires [Xcode](https://developer.apple.com/xcode/).
- Linux requires several packages (names may vary per distro).
- Ubunutu requires the following packages.
```bash
sudo apt install libgl1-mesa-dev libglu1-mesa-dev g++ g++-multilib gcc-multilib libasound2-dev libx11-dev libxext-dev libxi-dev libxrandr-dev libxinerama-dev libpulse-dev
```
- While Raspberry Pi OS also uses `apt`, it requires a slightly different set of packages.
```bash
sudo apt install libgl1-mesa-dev libglu1-mesa-dev g++ libasound2-dev libx11-dev libxext-dev libxi-dev libxrandr-dev libxinerama-dev libpulse-dev libxcursor-dev libdbus-1-dev libdrm-dev libgbm-dev libudev-dev
```
- Fedora requires the following packages.
```bash
sudo dnf install g++ glibc-devel.x86_64 libstdc++-devel.x86_64 glibc-devel.i686 libstdc++-devel.i686 alsa-lib-devel pulseaudio-libs-devel libX11-devel libXi-devel libXrandr-devel libglvnd-devel
```
- Building HashLink requires [additional packages](https://github.com/HaxeFoundation/hashlink#readme).
### Rebuilding
Use `lime rebuild ` to build or rebuild a set of binaries. Once finished, you can find them in the [ndll directory](https://github.com/openfl/lime/tree/develop/ndll).
```bash
lime rebuild windows #Recompile the Windows binary (lime.ndll).
lime rebuild android -clean #Compile the Android binaries (liblime-##.so) from scratch, even if no changes are detected.
lime rebuild mac -64 #Recompile only the x86-64 binary (lime.ndll) for Mac.
lime rebuild hl #Recompile the HashLink binaries (lime.hdll and others).
```
See `lime help rebuild` for details and additional options.
> Note: even without an explicit `rebuild` command, running `lime` will automatically build lime.ndll for your machine. Even if you never target C++ or Neko, this binary will help with small tasks such as rendering icons.
### Build troubleshooting
If errors appeared after updating Lime, the update process may not be complete. Run these commands:
```bash
git submodule init
git submodule sync
git submodule update
lime rebuild tools
```
For errors that appeared after changing a source file, you may need to update the build configuration.
- Errors in the [src](src) and [include](include) directories usually require updating [Build.xml](Build.xml).
- Errors in the [lib](lib) directory usually require updating that submodule's xml file. So for instance, if the error message points to lib/cairo/src/cairo.c, you most likely need to edit [cairo-files.xml](lib/cairo-files.xml). If the error message points to lib/hashlink/src/main.c, look at [BuildHashlink.xml](BuildHashlink.xml). (Though libraries do reference one another sometimes, so this isn't a hard rule.)
Common errors and their solutions:
- `[header].h: No such file or directory`: Include the header if it exists. If not, run `git status` to confirm that your submodules are up to date.
```xml
```
- `undefined reference to [symbol]`: Locate the source file that defines the symbol, then add it.
```xml
```
- `'std::istringstream' has no member named 'swap'`: Your Android NDK is out of date; switch to version 20 or higher. (Version 21 recommended.)
See also [submodule troubleshooting](#submodule-troubleshooting).
## Submodule projects
Lime includes code from several other C/C++ libraries, each of which is treated as a [submodule](https://git-scm.com/book/en/v2/Git-Tools-Submodules). For more information on the individual libraries, see [lib/README.md](lib/README.md).
### Custom headers and source files
All submodules are used as-is, meaning Lime never modifies the contents of the submodule folder. When Lime needs to modify or add a file, the file goes in [lib/custom](lib/custom).
Caution: overriding a file requires extra maintenance. Always try to find a different solution first. lib/custom should contain as few files as possible.
### Updating a submodule
Submodules are Git repositories in their own right, and are typically kept in "detached HEAD" state. Lime never modifies its submodules directly, but instead changes which commit the HEAD points to.
To update to a more recent version of a submodule:
1. Open the project's primary repo or GitHub mirror.
2. Browse the tags until you find the version you wish to update to. (Or browse commits, but that's discouraged.)
3. Copy the commit ID for your chosen version.
4. Open your local submodule folder on the command line. (From here, any `git` commands will affect the submodule instead of Lime.)
5. Update the library:
```bash
$ git checkout [commit ID]
Previous HEAD position was [old commit ID] [old commit message]
HEAD is now at [commit ID] [commit message]
```
If you get a "reference is not a tree" error, run `git fetch --unshallow`, then try again. (Lime downloads submodules in "shallow" mode to save time and space, and not all commits are fetched until you explicitly fetch them.)
6. If you exit the submodule and run `git status`, you'll find an unstaged change representing the update. Once you [finish testing](#rebuilding), you can commit this change and submit it as a pull request.
### Submodule troubleshooting
Here are some submodule-specific problems you might run into while rebuilding.
- The project is missing a crucial header file, or has `[header].h.in` instead of the header you need:
1. Look for an `autogen.sh` file. If it exists, run it. (On Windows, you may need [WSL](https://docs.microsoft.com/en-us/windows/wsl/about), or you might be able to find a .bat file that does what you need.)
2. If step 1 fails, look for instructions on how to configure the project. This will often involving using `make`, `cmake`, and/or `./configure`. (Again, Windows users may need WSL.)
3. One of the above steps should hopefully generate the missing header. Place the generated file inside [the custom folder](#custom-headers-and-source-files).
- The compiler uses the submodule's original header instead of Lime's custom header:
1. Make sure the custom folder is included first.
```xml
```
2. If the header is in the same directory as the corresponding source files, you cannot override it. Try setting compiler flags to get the result you want, or look for a different file to override.
```xml
```
3. Approach the problem from a different angle. Upgrade or downgrade the submodule, or open an issue.
================================================
FILE: project/include/app/Application.h
================================================
#ifndef LIME_APP_APPLICATION_H
#define LIME_APP_APPLICATION_H
#include
namespace lime {
class Application {
public:
virtual ~Application () {};
static AutoGCRoot* callback;
virtual int Exec () = 0;
virtual void Init () = 0;
virtual int Quit () = 0;
virtual void SetFrameRate (double frameRate) = 0;
virtual bool Update () = 0;
};
Application* CreateApplication ();
}
#endif
================================================
FILE: project/include/app/ApplicationEvent.h
================================================
#ifndef LIME_APP_APPLICATION_EVENT_H
#define LIME_APP_APPLICATION_EVENT_H
#include
#include
namespace lime {
enum ApplicationEventType {
UPDATE,
EXIT
};
struct ApplicationEvent {
hl_type* t;
int deltaTime;
ApplicationEventType type;
static ValuePointer* callback;
static ValuePointer* eventObject;
ApplicationEvent ();
static void Dispatch (ApplicationEvent* event);
};
}
#endif
================================================
FILE: project/include/graphics/Image.h
================================================
#ifndef LIME_GRAPHICS_IMAGE_H
#define LIME_GRAPHICS_IMAGE_H
#include
#include