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

Bug 403313

Summary: Clicking on a toolbar no longer activates the view
Product: [Eclipse Project] Platform Reporter: Paul Webster <pwebster>
Component: UIAssignee: Platform-UI-Inbox <Platform-UI-Inbox>
Status: CLOSED DUPLICATE QA Contact: Eric Moffatt <emoffatt>
Severity: major    
Priority: P3 CC: carolynmacleod4, daniel_megert, emoffatt, markus.kell.r
Version: 4.3   
Target Milestone: 4.3 M7   
Hardware: PC   
OS: Linux   
URL: http://download.eclipse.org/eclipse/downloads/drops4/I20130313-2000/testresults/html/org.eclipse.e4.ui.tests_linux.gtk.x86_6.0.html
Whiteboard:

Description Paul Webster CLA 2013-03-14 06:41:20 EDT
We still have a failure in our UIAllTest:
expected:<[]Part> but was:<[Other]Part>

junit.framework.ComparisonFailure: expected:<[]Part> but was:<[Other]Part>
at org.eclipse.e4.ui.tests.workbench.PartFocusTest.testNoFocusChangeOnExplicitWidgetSelection(PartFocusTest.java:165)
at org.eclipse.test.EclipseTestRunner.run(EclipseTestRunner.java:655)
at org.eclipse.test.EclipseTestRunner.run(EclipseTestRunner.java:310)
at org.eclipse.test.CoreTestApplication.runTests(CoreTestApplication.java:36)
at org.eclipse.test.CoreTestApplication.run(CoreTestApplication.java:32)
at org.eclipse.equinox.internal.app.EclipseAppContainer.callMethodWithException(EclipseAppContainer.java:587)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:198)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:354)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
at org.eclipse.equinox.launcher.Main.main(Main.java:1426)
at org.eclipse.core.launcher.Main.main(Main.java:34)
Comment 2 Eric Moffatt CLA 2013-03-14 13:38:50 EDT
Very easy to reproduce:

Have a Package Explorer open with something expanded in it
Activate a part in another stack
Click one of the buttons on the PE's toolbar...it doesn't activate

This is the result of the last fix for Bug 376011. This involved removing the SWT.Activate listener for the CTF in order to get the Tab traversal to be symmetric.

The largest negative effect of this defect is that if the operation chosen is to open a dialog it won't (many other operations work OK). I can work around this one by explicitly activating the part in the 'showMenu' handlers since we construct them in the StackRenderer. Fixing this for the Toolbar is somewhat more problematic in that we don't (directly) own the code that manages the toolbar items...

Paul and I have decided to live with this for M6 and start (immediately) to look for a proper solution which maintains the symmetry of the tabbing behavior but also activates the part whose TB was clicked.
Comment 3 Eric Moffatt CLA 2013-04-04 14:18:16 EDT
Car is looking into whether we can augment the SWT.Activate event with enough extra info to be able to determine whether the event occurred from a mouse click (where we want to activate the part) vs a KB event (where we don't).
Comment 4 Eric Moffatt CLA 2013-04-05 12:22:01 EDT
We're tracking the fix for this as part of bug 376011 so I'll mark this one as a dup of that one (the original 'fix' for that defect introduced this regression...).

*** This bug has been marked as a duplicate of bug 376011 ***
Comment 5 Dani Megert CLA 2013-04-10 04:26:02 EDT
Verified in I20130409-0900.