Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 366541 - [Compatibility] ICommon is not being correctly adapted
Summary: [Compatibility] ICommon is not being correctly adapted
Status: CLOSED DUPLICATE of bug 485167
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.2   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 366520
  Show dependency tree
 
Reported: 2011-12-13 09:17 EST by Paul Webster CLA
Modified: 2019-05-29 11:34 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Webster CLA 2011-12-13 09:17:28 EST
org.eclipse.ui.tests.menus.ObjectContributionTest.testAdaptables() shows the test objects are not being adapted to ICommon interface and so the ObjectContribution is not being honoured.

PW
Comment 1 Paul Webster CLA 2011-12-20 13:17:06 EST
One of our service plugins adds an adapter from Object to org.eclipse.e4.examples.services.snippets.adapter.ThingWithId

In 4.2 when we get into org.eclipse.ui.internal.ObjectContributorManager.getCommonClasses(List, List) and are at the "if (otherAdapters.isEmpty() && !adapters.isEmpty()) {...} else {...}" we take the *else*, and then we take the inner *else* and remove ICommon from *adapters*.

In 3.x we take the first if and do a "removeNonCommonAdapters(adapters, classesAndInterfaces);" which leaves the ICommon interface in the *adapters* list.

This problem has existed in the 3.x stream since at least 3.2


PW
Comment 2 Rolf Theunissen CLA 2019-05-26 12:23:00 EDT
Fixed in the context of Bug 485167. It is made sure that org.eclipse.e4.examples.* is no longer in the target platform when running the tests with the available launchers.
Comment 3 Dani Megert CLA 2019-05-29 11:34:51 EDT

*** This bug has been marked as a duplicate of bug 485167 ***