diff --git a/content/chunk0/scaleform/001598DB8D4DC9DB.GFXF b/content/chunk0/scaleform/001598DB8D4DC9DB.GFXF index f017b7c..286a00b 100644 Binary files a/content/chunk0/scaleform/001598DB8D4DC9DB.GFXF and b/content/chunk0/scaleform/001598DB8D4DC9DB.GFXF differ diff --git a/source/bin/SimpleKeyEventHelper.swf b/source/bin/SimpleKeyEventHelper.swf index 380a035..114480a 100644 Binary files a/source/bin/SimpleKeyEventHelper.swf and b/source/bin/SimpleKeyEventHelper.swf differ diff --git a/source/src/simplekeyeventhelper/SimpleKeyEventHelper.as b/source/src/simplekeyeventhelper/SimpleKeyEventHelper.as index 71f96f6..1f72ad2 100644 --- a/source/src/simplekeyeventhelper/SimpleKeyEventHelper.as +++ b/source/src/simplekeyeventhelper/SimpleKeyEventHelper.as @@ -2,6 +2,7 @@ package simplekeyeventhelper { import common.BaseControl; import flash.events.Event; +import flash.events.FocusEvent; import flash.events.KeyboardEvent; import flash.ui.Keyboard; import flash.utils.describeType; @@ -17,7 +18,8 @@ public class SimpleKeyEventHelper extends BaseControl { public function SimpleKeyEventHelper() { addEventListener(Event.ADDED_TO_STAGE, onAdded); - addEventListener(Event.REMOVED_FROM_STAGE, onRemoved); + addEventListener(FocusEvent.FOCUS_IN, onFocusIn); + addEventListener(FocusEvent.FOCUS_OUT, onFocusOut); } public function onSetData(object:Object):void { @@ -32,11 +34,16 @@ public class SimpleKeyEventHelper extends BaseControl { private function onAdded(event:Event):void { if (m_enabled) { addKeyListeners(); + } + } + + private function onFocusIn(event:FocusEvent):void { + if (m_enabled) { Send_onFocusAdded(); } } - private function onRemoved(event:Event):void { + private function onFocusOut(event:FocusEvent):void { if (m_enabled) { Send_onFocusRemoved(); }