             textInput.restrict = restrict;
             textInput.focusEnabled = false;
             
-            textInput.textDisplay.batchTextInput = false;
+            if (textInput.textDisplay is RichEditableText)
+                RichEditableText(textInput.textDisplay).batchTextInput = false;
         }
     }
     

import adobe.utils.CustomActions;

import flash.display.DisplayObject;
import flash.events.Event;
import flash.events.FocusEvent;
import flash.events.KeyboardEvent;

    {
        if (stage && textInput)
        {            
            stage.focus = textInput.textDisplay as InteractiveObject;            
        }
    }
    
