Skip to content

Instantly share code, notes, and snippets.

@mikecann
Created November 30, 2011 19:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mikecann/1410434 to your computer and use it in GitHub Desktop.
Save mikecann/1410434 to your computer and use it in GitHub Desktop.
Main
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<title>JeashExample</title>
<meta name="description" content="" />
</head>
<body>
<img src="lime-cat.jpg" />
<div id="haxe:jeash" style="top:0; left:0; right:0; bottom:0; z-index:1001;" />
<script src="JeashExample.js"></script>
</body>
</html>
class Main
{
static function main()
{
Firebug.redirectTraces();
Lib.current.stage.alpha = 0.5;
Lib.current.stage.addEventListener(Event.RESIZE, onResize);
}
static function onResize(e)
{
var s = Lib.current.stage;
trace("RESIZE "+s.stageWidth+", "+s.stageHeight);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment