瀏覽代碼

flash9 fixes

Nicolas Cannasse 19 年之前
父節點
當前提交
ac3b0d5590
共有 1 個文件被更改,包括 5 次插入3 次删除
  1. 5 3
      std/haxe/unit/TestRunner.hx

+ 5 - 3
std/haxe/unit/TestRunner.hx

@@ -29,15 +29,17 @@ class TestRunner {
 	var result : TestResult;
 	var result : TestResult;
 	var cases  : List<TestCase>;
 	var cases  : List<TestCase>;
 
 
-#if flash
-	static var tf = null;
+#if flash9
+	static var tf : flash.text.TextField = null;
+#else flash
+	static var tf : flash.TextField = null;
 #end
 #end
 
 
 	private static function print( v : Dynamic ){
 	private static function print( v : Dynamic ){
 		#if flash9
 		#if flash9
 		untyped {
 		untyped {
 			if( tf == null ) {
 			if( tf == null ) {
-				var tf = new flash.text.TextField();
+				tf = new flash.text.TextField();
 				tf.selectable = false;
 				tf.selectable = false;
 				tf.width = flash.Lib.current.stage.stageWidth;
 				tf.width = flash.Lib.current.stage.stageWidth;
 				tf.autoSize = flash.text.TextFieldAutoSize.LEFT;
 				tf.autoSize = flash.text.TextFieldAutoSize.LEFT;