This commit is contained in:
2014-07-06 20:34:54 +04:00
parent 50c8500bba
commit 1d9a5f8f62
2 changed files with 8 additions and 0 deletions

View File

@@ -22,6 +22,8 @@ class FrameSwitcher extends GroupView implements IFrameSwitcher<Sprite> {
}
current = frames.get(id);
addView(current);
var onShowMethod:Dynamic = Reflect.field(current, "onShow");
if (onShowMethod != null) Reflect.callMethod(current, onShowMethod, []);
return current;
}

View File

@@ -1,7 +1,9 @@
package haxework.log;
#if flash
import flash.events.ErrorEvent;
import flash.errors.Error;
#end
import haxework.log.ILogger.LogLevel;
class BaseLogger implements ILogger {
@@ -17,6 +19,7 @@ class BaseLogger implements ILogger {
}
public static function error2strign(error:Dynamic):String {
#if flash
return if (Std.is(error, Error)) {
var stack:String = error.getStackTrace();
stack == null ? Std.string(error) : stack;
@@ -26,6 +29,9 @@ class BaseLogger implements ILogger {
} else {
Std.string(error);
}
#else
return Std.string(error);
#end
}
private function write(text:String, ?p:haxe.PosInfos):Void {}