Bug 24533 - Disabled feature shows included children's latest enable version
Summary: Disabled feature shows included children's latest enable version
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Update (deprecated - use Eclipse>Equinox>p2) (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 2.0.2   Edit
Assignee: Dejan Glozic CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 24658 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-10-08 14:48 EDT by Christophe Elek CLA
Modified: 2002-10-23 10:02 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christophe Elek CLA 2002-10-08 14:48:20 EDT
Install root 1.0.0
Install root 1.0.1
show disable

Disable root 1.0.0 has XYZ&Bogus 1.0.1 as children.
Disable feature should show 'real' children ????
Comment 1 Dejan Glozic CLA 2002-10-10 09:46:00 EDT
True, but that means that you (Core) should ignore 'match' for disabled 
children.
Comment 2 Dejan Glozic CLA 2002-10-10 17:49:24 EDT
*** Bug 24658 has been marked as a duplicate of this bug. ***
Comment 3 Dejan Glozic CLA 2002-10-10 18:13:55 EDT
Christophe, I am moving the defect to you for the following:

1) Modify included feature resolution to always assume match==perfect if
the parent is disabled.
2) See if there are no visual side-effects

My hunch is that 'best match' resolution for disabled feature also caused
other UI defects (in particular, comparing old->new feature trees). 
Comment 4 Dejan Glozic CLA 2002-10-11 16:20:29 EDT
Here is the spec:

IFeature getFeature() throws CoreException; // <-- currently available
IFeature getFeature(boolean exactMatch) throws CoreException; // <-- new API

Change the implementation of 'getFeature()' to be:

IFeature getFeature() throws CoreException {
	return getFeature(false);
}

IFeature getFeature(boolean exactMatch) throws CoreException {
	int match = exactMatch? <use match value> : PERFECT;
 	...
}

After 2.0.2, the new API will be moved to IIncludedFeatureReference
because it is not applicable to root-level IFeatureReference.
Comment 5 Christophe Elek CLA 2002-10-14 10:47:09 EDT
implemented:

FeatureReference now contains 2 methods to solve this issue: getFeature() and
getFeature(boolean perfectMatch)
The object caches and hydrates the 2 possibles instances of the Feature
(exactMatch and bestMatch)and returns it appropriatly.

Pass to UI for implementation.
Comment 6 Dejan Glozic CLA 2002-10-14 12:27:02 EDT
Fixed in the UI and verified.