Uploader and Flash accessibility research
Colin Clark
colin.clark at utoronto.ca
Tue Mar 17 21:37:33 UTC 2009
Hi everyone,
Late last week, Eli and I spent some time digging into some of the
a11y issues we've encountered with SWFUpload and Flash 10.
As you probably already know, a "security" change in Flash 10 requires
us to use a visible Flash movie for the Browse Files button in the
Uploader. While the rest of the UI is entirely HTML-based, this
requirement has resulted in a number of issues for keyboard navigation
and use of assistive technologies.
Firstly, we've found that no role is applied to the Flash object for
use by assistive technologies. In essence, the entire SWFUpload object
is a giant button, but it was not built using a real Flash Button
component. Flash 10 does indeed have support for MSAA roles, so it
should be quite possible for a "button" role to be exposed.
Digging into this, we found that Adobe's Flash 10 built-in component
accessibility feature has two annoying flaws:
1. It's turned off by default
2. It's not available in their open source Flex SDK. If you want to
author accessible widgets, you've got to pay.
There is a more primitive accessibility API provided in Flash 9 and
prior, which is available to in the open source Flex SDK. It's quite
terrible, but may do the trick. SWFUpload uses the open source Flex
SDK, so that's all we've got to work with.
SWFUpload's technique for rendering their own custom Flash button is
pretty awkward, and it forces another bug on us: as the browser's size
is zoomed up, the button doesn't scale correctly.
That said, there is an avenue for fixing both the role issue and the
scaling issue: modify SWFUpload to render a real Flash button, use
their old a11y API, and ensure that the button is scalable. This isn't
particularly difficult work for a Flash guru, but it does require more
chops than either Eli or I have currently. We're both eager to learn,
but we need a friend to help us out.
Another issue with a less clearly definite solution: Flash swallows
the Tab/Shift-Tab keys on Firefox. This is apparently a very long
standing issue:
https://bugzilla.mozilla.org/show_bug.cgi?id=93149
In short, Flash refuses to hand keyboard focus back to the browser.
I've come up with a scheme that may work for SWFUpload, but it'll
require some experimentation:
1. Add a keyboard listener to SWFUpload's stage, listening in
particular for the Tab and Shift-Tab key presses. If these are caught,
use Flash's ExternalInterface to call back to some code on the
JavaScript side of the world.
2. Write a tab focus manager for the Uploader that is capable of
focussing the element in the DOM immediately before or after the Flash
movie. This should be fairly straightforward with the new tabbable()
method in jQuery UI.
In the meantime, we've got some descriptive alt text on the Flash
movie, and we're playing around with adding some ARIA roles and
properties to improve the experience. I'd be curious to hear how the
experience is for AT users.
If there are any Flash wizards out there who want to help us to
improve accessibility of the Uploader, drop us a line.
Colin
---
Colin Clark
Technical Lead, Fluid Project
Adaptive Technology Resource Centre, University of Toronto
http://fluidproject.org