Bug 156886 - EMFCompositeSourcePropertyDescriptor returns null in getProipertySource while it should do more testing
Summary: EMFCompositeSourcePropertyDescriptor returns null in getProipertySource while...
Status: RESOLVED FIXED
Alias: None
Product: GMF-Runtime
Classification: Modeling
Component: General (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 major
Target Milestone: 1.0.1   Edit
Assignee: Cherie Revells CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2006-09-11 11:38 EDT by Natalia Balaba CLA
Modified: 2010-07-19 21:55 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Natalia Balaba CLA 2006-09-11 11:38:36 EDT
The code in getPropertySource should test argument on being IItemPropertySource  (just look at the usage of the method, and it will become self evident as to why) like follows:


protected IItemPropertySource getPropertySource(Object value) {
       if(value instanceof IItemPropertySource)
            return (IItemPropertySource) value;

        TransactionalEditingDomain editingDomain = TransactionUtil
            .getEditingDomain(getObject());

        if (editingDomain instanceof AdapterFactoryEditingDomain) {
            return (IItemPropertySource) ((AdapterFactoryEditingDomain) editingDomain)
                .getAdapterFactory().adapt(value, IItemPropertySource.class);
        }
        return null;
    }
Comment 1 Anthony Hunter CLA 2006-09-11 13:28:07 EDT
Hi Natalia, given you set as major you likely have a fix in mind.

Could you attach a patch that resolves your issue? (Do you have one?)
Comment 2 Cherie Revells CLA 2006-09-12 14:26:36 EDT
Committed the patch.
Comment 3 Eclipse Webmaster CLA 2010-07-19 21:55:49 EDT
[GMF Restructure] Bug 319140 : product GMF and component
Runtime Common was the original product and component for this bug