Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 237764 - [spy] NPE when there is no (active) part
Summary: [spy] NPE when there is no (active) part
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.4   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 normal (vote)
Target Milestone: 3.6 M1   Edit
Assignee: Benjamin Cabé CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-19 06:45 EDT by Heiko Seeberger CLA
Modified: 2009-06-24 08:35 EDT (History)
2 users (show)

See Also:


Attachments
Patch (1.19 KB, patch)
2008-06-19 06:50 EDT, Heiko Seeberger CLA
contact: iplog+
Details | Diff
mylyn/context/zip (2.04 KB, application/octet-stream)
2009-06-24 08:13 EDT, Benjamin Cabé CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Heiko Seeberger CLA 2008-06-19 06:45:16 EDT
When I tried to integrate (the fantastic) Plug-in Spy into my own RCP application, I started with an empty one (Hello world) which of course has got no part. Pressing Alt+Shift+F1 resulted in nothing on the UI and a NPE logged:

!ENTRY org.eclipse.ui 4 0 2008-06-19 12:44:15.373
!MESSAGE Unhandled event loop exception
!STACK 0
java.lang.NullPointerException
	at org.eclipse.pde.internal.runtime.spy.sections.ActivePartSection.build(ActivePartSection.java:46)
	at org.eclipse.pde.internal.runtime.spy.dialogs.SpyDialog.createDialogArea(SpyDialog.java:101)
	at org.eclipse.pde.internal.runtime.spy.dialogs.SpyDialog.createContents(SpyDialog.java:71)
	at org.eclipse.jface.window.Window.create(Window.java:431)
...
Comment 1 Heiko Seeberger CLA 2008-06-19 06:50:12 EDT
Created attachment 105397 [details]
Patch
Comment 2 Heiko Seeberger CLA 2008-06-19 06:50:58 EDT
The bug was easy to track down. I fixed it and created a patch.
Comment 3 Benjamin Cabé CLA 2008-07-02 17:04:03 EDT
Looks good to me...
Comment 4 Benjamin Cabé CLA 2009-06-24 08:13:03 EDT
Released in HEAD 
>20090624

Thanks Heiko!
Comment 5 Benjamin Cabé CLA 2009-06-24 08:13:35 EDT
Created attachment 139976 [details]
mylyn/context/zip