Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 311632 - AccessibleObject interfering with default accessibility of Text (with Orca)
Summary: AccessibleObject interfering with default accessibility of Text (with Orca)
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.6   Edit
Hardware: PC Linux-GTK
: P3 normal (vote)
Target Milestone: 3.6 RC1   Edit
Assignee: Silenio Quarti CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-04 16:54 EDT by Silenio Quarti CLA
Modified: 2010-05-05 10:11 EDT (History)
1 user (show)

See Also:
eclipse.felipe: review+


Attachments
fix (3.65 KB, patch)
2010-05-04 16:57 EDT, Silenio Quarti CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Silenio Quarti CLA 2010-05-04 16:54:45 EDT
SWT creates an AccessibleObject when the free Label relation is added. This causes a lot of code to start running in AccessibleObject even though there is no listener added to Accessible object associated to the text field in the sample below. For example, AcessibleObject.atkText_get_character_at_offset() is called as you type in the text field and the implementation gets the whole text of the widget and returns the character at the offset instead of calling the super optimized implementation. 

	public static void main(String[] args) {
//		Device.DEBUG = true;
		Display display = new Display();
		Shell shell = new Shell(display);
		shell.setLayout(new GridLayout(1, false));

		Label label = new Label(shell, SWT.NONE);
		label.setText("Hello");
		Text text = new Text(shell, SWT.SINGLE | SWT.BORDER);
		text.setText("Text");

		shell.pack();
		shell.open();
		while (!shell.isDisposed()) {
			if (!display.readAndDispatch())
				display.sleep();
		}
		display.dispose();
	}
Comment 1 Silenio Quarti CLA 2010-05-04 16:57:01 EDT
Created attachment 167047 [details]
fix
Comment 2 Silenio Quarti CLA 2010-05-05 10:11:11 EDT
Fixed > 20100505