From 516b5fbbb6ee7c46b3a8ae99e1cef445f68e7835 Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Wed, 6 May 2009 18:54:59 +0000 Subject: [PATCH] On production, in an embed, I can't click the chat widget during the voting phase of LOLcaptions. Clicking a button and then the text field works, so it's some sort of funky focus issue. Try this. Unable to duplicate on my local server, so I'll just recheck to see if this works after the next release. git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@815 ed5b42cb-e716-0410-a449-f6a68f950b19 --- src/as/com/threerings/flex/ChatInput.as | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/as/com/threerings/flex/ChatInput.as b/src/as/com/threerings/flex/ChatInput.as index ff156a4d..4fa053eb 100644 --- a/src/as/com/threerings/flex/ChatInput.as +++ b/src/as/com/threerings/flex/ChatInput.as @@ -5,8 +5,12 @@ package com.threerings.flex { import flash.events.FocusEvent; +import flash.text.TextField; + import mx.controls.TextInput; +import com.threerings.flash.TextFieldUtil; + /** * The class name of an image to use as the input prompt. */ @@ -53,6 +57,13 @@ public class ChatInput extends TextInput setStyle("backgroundImage", (show && ("" == text)) ? getStyle("prompt") : undefined); } + override protected function createChildren () :void + { + super.createChildren(); + + TextFieldUtil.setFocusable(TextField(textField)); + } + override protected function focusInHandler (event :FocusEvent) :void { var oldValue :Boolean = textField.selectable;