Home > Flex > Flex 4 Dropdownlist and Accessibility

Flex 4 Dropdownlist and Accessibility

Pressing up/down arrow keys when Flex 4 DropdownList has focus changes the selection. Sometimes the user would want to see the list before making the selection.This can be achieved by overriding the keydownHandler and changing the default behaviour to open the drop list if it is not already open.

override protected function keyDownHandler(event:KeyboardEvent):void
{
if(event.keyCode == Keyboard.DOWN && !isDropDownOpen)
openDropDown();
else
super.keyDownHandler(event);
}

Categories: Flex
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.