[Laszlo-checkins] r13131 - in openlaszlo/trunk: WEB-INF/lps/lfc/kernel/swf WEB-INF/lps/lfc/views lps/components/debugger
max@openlaszlo.org
max at openlaszlo.org
Mon Mar 2 19:07:12 PST 2009
Author: max
Date: 2009-03-02 19:07:09 -0800 (Mon, 02 Mar 2009)
New Revision: 13131
Modified:
openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf/LzSprite.as
openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs
openlaszlo/trunk/lps/components/debugger/debugger.lzx
Log:
Change 20090302-maxcarlson-l by maxcarlson at Bank.lan on 2009-03-02 06:09:18 PST
in /Users/maxcarlson/openlaszlo/trunk-clean
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Add sendAAEvent() API for accessibility
Bugs Fixed: LPP-7594 - IBM Jaws Accessibility support needed for Radioboxes and trees and Issues (partial)
Technical Reviewer: promanik
QA Reviewer: aalappat at laszlosystems.com
Details: LzSprite, LaszloView - Add implementation of sendAAEvent()
debugger - Hide debugger from screen readers
Tests: See accimpl2.lzx from LPP-7594
Modified: openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf/LzSprite.as
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf/LzSprite.as 2009-03-03 02:59:50 UTC (rev 13130)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf/LzSprite.as 2009-03-03 03:07:09 UTC (rev 13131)
@@ -149,7 +149,15 @@
mc.tabIndex = s;
}
+/**
+ * See view.sendAAEvent()
+ */
+LzSprite.prototype.sendAAEvent = function(childID, eventType, nonHTML){
+ var mc = this.getMCRef();
+ Accessibility.sendEvent(mc, childID, eventType, nonHTML);
+}
+
// FIRST_SUBVIEW_DEPTH: This is so that default objects (such as
// buttons, and in swf6 masks) can be attached above the view's
// subviews. 11 is an arbitrary number chosen by Adam
Modified: openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs 2009-03-03 02:59:50 UTC (rev 13130)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs 2009-03-03 03:07:09 UTC (rev 13131)
@@ -967,7 +967,20 @@
}
}
+/** Sends an event to the Microsoft Active Accessibility API. Microsoft Active Accessibility handles that event and sends the event to any active screen reader application, which in turn reports the change to the user. For example, when a user toggles a RadioButton instance, the RadioButton's Accessibility Implementation calls Accessibility.sendEvent() with the eventType EVENT_OBJECT_STATECHANGE/0x800a.
+ * @param number childID: The child id of the accessibility interface element to which the event applies (for example, an individual list item in a list box). Use 0 to indicate that the event applies to the DisplayObject supplied in the source parameter.
+ * @param number eventType: A constant indicating the event type. Event names and values are a subset of the MSAA event constants.
+ * @param boolean nonHTML: A Boolean indication of whether or not the event is one of the standard event types that can be generated from an HTML form. When set to true, this parameter helps prevent some problems that may occur with screen readers that interperet Flash content as part of the HTML page. The default value is false.
+ */
+function sendAAEvent(childID:Number, eventType:Number, nonHTML:Boolean = false) {
+ if (this.capabilities.accessibility) {
+ this.sprite.sendAAEvent(childID, eventType, nonHTML);
+ } else if ($debug) {
+ LzView.__warnCapability('view.sendAAEvent()', 'accessibility');
+ }
+}
+
LzView.__LZdelayedSetters.layout = "$lzc$set_layout";
LzView.earlySetters.clickregion = 7;
LzView.earlySetters.stretches = 8;
Modified: openlaszlo/trunk/lps/components/debugger/debugger.lzx
===================================================================
--- openlaszlo/trunk/lps/components/debugger/debugger.lzx 2009-03-03 02:59:50 UTC (rev 13130)
+++ openlaszlo/trunk/lps/components/debugger/debugger.lzx 2009-03-03 03:07:09 UTC (rev 13131)
@@ -103,6 +103,14 @@
font="monospace" fontsize="11" fontstyle="plain"
oninit="initEvalView()" pixellock="true">
+ <method name="init">
+ super.init();
+ // Hide from screen readers
+ if ($as2) {
+ var mc = this.getMCRef();
+ mc._accImpl = {stub: true};
+ }
+ </method>
<!-- Will be applied in construct if no width specified -->
<attribute name="default_width" value="false" />
<state applied="${parent.default_width}">
More information about the Laszlo-checkins
mailing list