mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 14:42:11 +02:00
- fixed NPE in prefernces page
This commit is contained in:
parent
80fa0c1930
commit
aae25439d2
1 changed files with 1 additions and 0 deletions
|
@ -120,6 +120,7 @@ public abstract class FieldEditorOverlayPage extends FieldEditorPreferencePage
|
|||
* @see org.eclipse.ui.IWorkbenchPropertyPage#getElement()
|
||||
*/
|
||||
public IAdaptable getElement() {
|
||||
if (element==null) return element;
|
||||
if (!(element instanceof IProject))
|
||||
return (IAdaptable) element.getAdapter(IProject.class);
|
||||
return element;
|
||||
|
|
Loading…
Add table
Reference in a new issue