 		/**
 		 * This function hides the prompt if it is shown, and selects all if autoSelect is true.
 		 */
-		protected function captureFocusIn(event:FocusEvent):void
-		{
-			_hasFocus = true;
-			hidePrompt();
-			
-			if (autoSelect)
-			{
-				selectionBeginIndex = 0;
-				selectionEndIndex = text.length;
-			}
-		}
+		override protected function focusInHandler(event:FocusEvent):void
+		{
+			if (!_hasFocus)
+			{
+				_hasFocus = true;
+				hidePrompt();
+
+				if (autoSelect)
+				{
+					selectionBeginIndex = 0;
+					selectionEndIndex = text.length;
+				}
+			}
+			
+			super.focusInHandler(event);
+		}
 		
 		/**
 		 * This function makes the prompt reappear if the text is empty.
 		 */
-		protected function captureFocusOut(event:FocusEvent):void
-		{
-			_hasFocus = false;
-			if (!text)
-				showPrompt();
+		override protected function focusOutHandler(event:FocusEvent):void
+		{
+			if (_hasFocus)
+			{
+				_hasFocus = false;
+				if (!text)
+					showPrompt();
+			}
+			
+			super.focusOutHandler(event);
 		}
 		
 		/**

				super.text = newText;
				
				updateTextColor();
			}
		}
		

*/
package weave.ui
{
	import flash.events.FocusEvent;
	
	import mx.controls.TextInput;
	import mx.core.mx_internal;
	import mx.utils.ObjectUtil;
	
	import weave.compiler.StandardLib;

	use namespace mx_internal;
