Reputation: 17762
The keyboard interaction on my list is causing it to jump between different list items. The list should only respond to mouse events so I'd like to turn off keyboard handling.
I found this method which overrides the List class but I'd like to know if there's another method.
Upvotes: 0
Views: 62
Reputation: 17762
Here's the extended class override:
import flash.events.KeyboardEvent;
import spark.components.List;
public class ListNoKeyboardHandling extends List
{
public function ListNoKeyboardHandling()
{
super();
}
override protected function keyDownHandler(event:KeyboardEvent):void {
// do nothing
}
}
Upvotes: 2