Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 105348 Details for
Bug 229494
[Forms] Accessibility: expandable section labels are not being read by screen readers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
patch for 3.4.1
patch229494-3.4.1.txt (text/plain), 4.45 KB, created by
Adam Archer
on 2008-06-18 17:11:24 EDT
(
hide
)
Description:
patch for 3.4.1
Filename:
MIME Type:
Creator:
Adam Archer
Created:
2008-06-18 17:11:24 EDT
Size:
4.45 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.ui.forms >Index: src/org/eclipse/ui/forms/widgets/AbstractHyperlink.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.ui.forms/src/org/eclipse/ui/forms/widgets/AbstractHyperlink.java,v >retrieving revision 1.19 >diff -u -r1.19 AbstractHyperlink.java >--- src/org/eclipse/ui/forms/widgets/AbstractHyperlink.java 16 Mar 2007 20:24:01 -0000 1.19 >+++ src/org/eclipse/ui/forms/widgets/AbstractHyperlink.java 18 Jun 2008 21:09:37 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2007 IBM Corporation and others. >+ * Copyright (c) 2000, 2008 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -215,7 +215,6 @@ > protected void handleActivate(Event e) { > // disarm link, back to normal state > armed = false; >- getAccessible().setFocus(ACC.CHILDID_SELF); > if (listeners == null) > return; > int size = listeners.size(); >@@ -229,6 +228,11 @@ > } > if (!isDisposed()) > setCursor(FormsResources.getHandCursor()); >+ triggerAccessible(); >+ } >+ >+ void triggerAccessible() { >+ getAccessible().setFocus(ACC.CHILDID_SELF); > } > > /** >Index: src/org/eclipse/ui/forms/widgets/ToggleHyperlink.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.ui.forms/src/org/eclipse/ui/forms/widgets/ToggleHyperlink.java,v >retrieving revision 1.16 >diff -u -r1.16 ToggleHyperlink.java >--- src/org/eclipse/ui/forms/widgets/ToggleHyperlink.java 16 Mar 2007 20:24:01 -0000 1.16 >+++ src/org/eclipse/ui/forms/widgets/ToggleHyperlink.java 18 Jun 2008 21:09:37 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2007 IBM Corporation and others. >+ * Copyright (c) 2000, 2008 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -156,7 +156,6 @@ > */ > public void setExpanded(boolean expanded) { > this.expanded = expanded; >- getAccessible().selectionChanged(); > redraw(); > } > private void initAccessible() { >@@ -165,15 +164,7 @@ > e.result = getToolTipText(); > } > public void getName(AccessibleEvent e) { >- String name=Messages.ToggleHyperlink_accessibleName; >- if (getParent() instanceof ExpandableComposite) { >- name += Messages.ToggleHyperlink_accessibleColumn+((ExpandableComposite)getParent()).getText(); >- int index = name.indexOf('&'); >- if (index != -1) { >- name = name.substring(0, index) + name.substring(index + 1); >- } >- } >- e.result = name; >+ e.result = Messages.ToggleHyperlink_accessibleName; > } > public void getDescription(AccessibleEvent e) { > getName(e); >@@ -211,16 +202,33 @@ > e.detail = ACC.ROLE_TREE; > } > public void getState(AccessibleControlEvent e) { >- int state = ACC.STATE_FOCUSABLE; >- if (ToggleHyperlink.this.getSelection()) >- state |= ACC.STATE_FOCUSED; >- state |= ToggleHyperlink.this.isExpanded() >+ e.detail = ToggleHyperlink.this.isExpanded() > ? ACC.STATE_EXPANDED > : ACC.STATE_COLLAPSED; >- e.detail = state; >+ } >+ public void getValue(AccessibleControlEvent e) { >+ if (e.childID == ACC.CHILDID_SELF) { >+ String name = Messages.ToggleHyperlink_accessibleName; >+ if (getParent() instanceof ExpandableComposite) { >+ name = Messages.ToggleHyperlink_accessibleColumn+((ExpandableComposite)getParent()).getText(); >+ int index = name.indexOf('&'); >+ if (index != -1) { >+ name = name.substring(0, index) + name.substring(index + 1); >+ } >+ } >+ e.result = name; >+ } > } > }); > } >+ // set bogus childIDs on link activation to ensure state is read on expand/collapse >+ void triggerAccessible() { >+ getAccessible().setFocus(getAccessibleChildID()); >+ } >+ private int getAccessibleChildID() { >+ return ToggleHyperlink.this.isExpanded() ? 1 : 2; >+ } >+ > private void onKeyDown(Event e) { > if (e.keyCode==SWT.ARROW_RIGHT) { > // expand if collapsed
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 229494
: 105348