Bug 193095 - MarkerView doesn't use Util.getAdapter(*)
Summary: MarkerView doesn't use Util.getAdapter(*)
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.3   Edit
Hardware: PC All
: P3 normal (vote)
Target Milestone: 4.4 M7   Edit
Assignee: Paul Webster CLA
QA Contact:
URL:
Whiteboard:
Keywords: bugday
Depends on: 82973
Blocks:
  Show dependency tree
 
Reported: 2007-06-18 07:47 EDT by Paul Webster CLA
Modified: 2014-04-30 07:28 EDT (History)
9 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 2007-06-18 07:47:51 EDT
In at least focusSelectionChanged(*)
PW
Comment 1 Paul Webster CLA 2007-06-18 07:48:33 EDT
It looks like we overlooked this as part of bug 156581  I'd suggest looking at this for 3.3.1

PW
Comment 2 Kim Horne CLA 2007-08-31 09:43:34 EDT
Removing the 3.3.1 target
Comment 3 Srimanth CLA 2007-10-04 22:29:29 EDT
It would be helpful to have the MarkerView use the Platform.getAdapterManager() to find adapters instead of an instanceof check, as it forces us to put tooling specific interfaces into our model. Also portions of our model are read-only and cant be made to extend IAdaptable.

I think it should be mentioned in IAdaptable's interface that the preferred way to get an adaptable would be to ask the platform instead of doing an instanceof check.
Comment 4 Boris Bokowski CLA 2007-10-05 00:01:21 EDT
I'll have a look at this for 3.3.2. I agree that we should always use Util.getAdapter(), but we have to assess what the risk of a change like this is in a maintenance stream.
Comment 5 Boris Bokowski CLA 2008-01-16 12:44:43 EST
We should do this for 3.4, but not 3.3.2 - it is not a blocker kind of problem.
Comment 6 Boris Bokowski CLA 2008-05-02 14:56:43 EDT
Mass update - removing 3.4 target. This was one of the bugs I marked for investigation (and potential fixing) in 3.4 but I ran out of time. Please ping on the bug if fixing it would be really important for 3.4, and does not require API changes or feature work.
Comment 7 Remy Suen CLA 2009-11-29 09:42:01 EST
The views were rewritten in 3.4, is this still a problem?
Comment 8 Simon Scholz CLA 2014-03-28 15:39:00 EDT
Unfortunately the org.eclipse.ui.views.tasklist.ITaskListResourceAdapter is expecting an IAdaptable in its org.eclipse.ui.views.tasklist.ITaskListResourceAdapter.getAffectedResource(IAdaptable) method so that the instanceof check and the cast of the object cannot be avoided.

Furthermore the implementations of the ITaskListResourceAdapter are not using the Util.getAdapter(*) method either. Known implementations are org.eclipse.ui.views.markers.internal.DefaultMarkerResourceAdapter and org.eclipse.ui.views.tasklist.DefaultTaskListResourceAdapter
Those classes should also be modified so that they also use the Util.getAdapter() functionality.
Comment 9 Simon Scholz CLA 2014-03-28 15:54:31 EDT
Proposed Solution: https://git.eclipse.org/r/#/c/24101/
Comment 11 Paul Webster CLA 2014-04-30 07:28:05 EDT
In 4.4.0.I20140428-2000

PW