Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 368150

Summary: Selection event fired too late by SWTBotTreeItem#clickXY
Product: [Technology] SWTBot Reporter: Tim Moore <tmm-bugs.eclipse>
Component: SWTBotAssignee: Project Inbox <swtbot-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:

Description Tim Moore CLA 2012-01-09 08:01:29 EST
Build Identifier: M20100909-0800

SWTBotTreeItem#clickXY fires events in the following order:

notifyTree(SWT.MouseEnter);
notifyTree(SWT.MouseMove);
notifyTree(SWT.Activate);
notifyTree(SWT.FocusIn);
notifyTree(SWT.MouseDown, createMouseEvent(x, y, 1, SWT.NONE, 1));
notifyTree(SWT.MouseUp, createMouseEvent(x, y, 1, SWT.BUTTON1, 1));
notifyTree(SWT.Selection, createSelectionEvent(SWT.BUTTON1));
notifyTree(SWT.MouseHover);
notifyTree(SWT.MouseMove);
notifyTree(SWT.MouseExit);
notifyTree(SWT.Deactivate);
notifyTree(SWT.FocusOut);

However, Selection should occur directly after MouseDown, not after MouseUp. In contrast, SWTBotTableItem fires the events in the correct order.

Reproducible: Always
Comment 1 Tim Moore CLA 2012-01-09 08:03:14 EST
Also, you need a 2.0.5 Version option :)