NullPointerException with ScrollableThumbnail [message #141760] |
Tue, 06 July 2004 13:46  |
Eclipse User |
|
|
|
Originally posted by: nbeckman.NOSPAM.usc.edu
Hello everyone,
I have a GEF plugin running in RCP and it has a thumbnail view.
Unfortunately, every time that I open up a document with my editor, I get a
null pointer exception. Check it out:
java.lang.NullPointerException
at org.eclipse.draw2d.geometry.Point.getDifference(Point.java:1 11)
at
org.eclipse.draw2d.parts.ScrollableThumbnail$ScrollSynchroni zer.mouseDragged
(ScrollableThumbnail.java:159)
at org.eclipse.draw2d.Figure.handleMouseDragged(Figure.java:727 )
at
org.eclipse.draw2d.SWTEventDispatcher.dispatchMouseMoved(SWT EventDispatcher.
java:228)
(The most important lines.)
Now what is happening is that mouseDragged gets called immediately when the
file is opened and it calls getDifference on "private Point startLocation;"
But startLocation is null when the application is first launched. Anyone
have an idea why?
Thanks a lot,
Nels
|
|
|
Re: NullPointerException with ScrollableThumbnail [message #141848 is a reply to message #141760] |
Tue, 06 July 2004 19:56  |
Eclipse User |
|
|
|
Look into why mouseDragged is being invoked when the application is first
launched. Obviously, that should not be happening.
"Nels Beckman" <nbeckman@NOSPAM.usc.edu> wrote in message
news:cceosq$so$1@eclipse.org...
> Hello everyone,
> I have a GEF plugin running in RCP and it has a thumbnail view.
> Unfortunately, every time that I open up a document with my editor, I get
a
> null pointer exception. Check it out:
>
> java.lang.NullPointerException
> at org.eclipse.draw2d.geometry.Point.getDifference(Point.java:1 11)
> at
>
org.eclipse.draw2d.parts.ScrollableThumbnail$ScrollSynchroni zer.mouseDragged
> (ScrollableThumbnail.java:159)
> at org.eclipse.draw2d.Figure.handleMouseDragged(Figure.java:727 )
> at
>
org.eclipse.draw2d.SWTEventDispatcher.dispatchMouseMoved(SWT EventDispatcher.
> java:228)
> (The most important lines.)
>
> Now what is happening is that mouseDragged gets called immediately when
the
> file is opened and it calls getDifference on "private Point
startLocation;"
> But startLocation is null when the application is first launched. Anyone
> have an idea why?
> Thanks a lot,
> Nels
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.05671 seconds