From 8114a24402160f78ebd73d0910a40b898feeaa68 Mon Sep 17 00:00:00 2001 From: Vivian Kong Date: Thu, 12 Jul 2012 15:05:40 -0400 Subject: [PATCH] Bug 382426 - [Accessibility] Some UI elements do not provide a label --- .../ui/properties/BuildBehaviourTab.java | 9 ++++++++- .../cdt/internal/ui/filters/CustomFiltersDialog.java | 12 +++++++++++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildBehaviourTab.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildBehaviourTab.java index 46cf3e813f5..f7bc7f82ccf 100644 --- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildBehaviourTab.java +++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/ui/properties/BuildBehaviourTab.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2011 Intel Corporation and others. + * Copyright (c) 2007, 2012 Intel 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 @@ -163,6 +163,13 @@ public class BuildBehaviourTab extends AbstractCBuildPropertyTab { updateButtons(); } }); + s_parallelNumber.getAccessible().addAccessibleListener(new AccessibleAdapter() { + @Override + public void getName(AccessibleEvent e) { + e.result = Messages.BuilderSettingsTab_UseParallelJobs; + } + }); + s_parallelNumber.setToolTipText(Messages.BuilderSettingsTab_UseParallelJobs); b_parallelUnlimited= new Button(c3, SWT.RADIO); b_parallelUnlimited.setText(Messages.BuilderSettingsTab_UseUnlimitedJobs); diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/filters/CustomFiltersDialog.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/filters/CustomFiltersDialog.java index 2afb5902155..e83ea702b5b 100644 --- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/filters/CustomFiltersDialog.java +++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/filters/CustomFiltersDialog.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2009 IBM Corporation and others. + * Copyright (c) 2000, 2012 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 @@ -32,6 +32,8 @@ import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.jface.viewers.LabelProvider; import org.eclipse.jface.viewers.SelectionChangedEvent; import org.eclipse.swt.SWT; +import org.eclipse.swt.accessibility.AccessibleAdapter; +import org.eclipse.swt.accessibility.AccessibleEvent; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; @@ -183,6 +185,14 @@ public class CustomFiltersDialog extends SelectionDialog { List initialSelection= getInitialElementSelections(); if (initialSelection != null && !initialSelection.isEmpty()) checkInitialSelections(); + + fCheckBoxList.getTable().getAccessible().addAccessibleListener(new AccessibleAdapter() { + @Override + public void getName(AccessibleEvent e) { + e.result = FilterMessages.CustomFiltersDialog_filterList_label; + } + }); + fCheckBoxList.getTable().setToolTipText(FilterMessages.CustomFiltersDialog_filterList_label); // Description info= new Label(parent, SWT.LEFT);