Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 251588 Details for
Bug 462235
PropertySourceAdapterFactory is not null aware
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
NPE patch
PropertySourceAdapter-NPEpatch.txt (text/plain), 1.04 KB, created by
Reguel Wermelinger
on 2015-03-16 09:49:12 EDT
(
hide
)
Description:
NPE patch
Filename:
MIME Type:
Creator:
Reguel Wermelinger
Created:
2015-03-16 09:49:12 EDT
Size:
1.04 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.gef >Index: src/org/eclipse/gef/internal/PropertySourceAdapterFactory.java >=================================================================== >--- src/org/eclipse/gef/internal/PropertySourceAdapterFactory.java (revision 48138) >+++ src/org/eclipse/gef/internal/PropertySourceAdapterFactory.java (working copy) >@@ -23,12 +23,16 @@ > public Object getAdapter(Object adaptableObject, Class adapterType) { > AbstractEditPart part = (AbstractEditPart) adaptableObject; > Object model = part.getModel(); >+ // model can be null >+ if (model == null) >+ { >+ return null; >+ } > // check if model is already of the desired adapter type > if (adapterType.isInstance(model)) { > return model; > } >- // check if model is adaptable and does provide an adapter of the >- // desired type >+ // check if model is adaptable and does provide an adapter of the desired type > if (model instanceof IAdaptable) { > Object adapter = ((IAdaptable) model).getAdapter(adapterType); > if (adapter != null) {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
nyssen
:
iplog+
Actions:
View
Attachments on
bug 462235
: 251588