directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pierre-Arnaud Marcelot (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DIRSTUDIO-298) NullPointerException raised when drag'n'dropping a connection to a folder (on Mac OS X only)
Date Tue, 22 Jul 2008 11:20:31 GMT

    [ https://issues.apache.org/jira/browse/DIRSTUDIO-298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12615581#action_12615581
] 

Pierre-Arnaud Marcelot commented on DIRSTUDIO-298:
--------------------------------------------------

Stefan, I've found what the problem was.

The selection of the tree was set to null when I was passing in the "dragSetData( DragSourceEvent
event )" method of the "DragConnectionListener" (org.apache.directory.studio.connection.ui.dnd.DragConnectionListener)
class.

This only occurs on Mac OS X. On other platforms, the selection is correct.

So, I had to collect and save the selected (in a field) in the "dragStart( DragSourceEvent
event )" method of this same class, and then use this selection in the "dragSetData( DragSourceEvent
event )" method.

It's a little bit tricky but it's working great.

> NullPointerException raised when drag'n'dropping a connection to a folder (on Mac OS
X only)
> --------------------------------------------------------------------------------------------
>
>                 Key: DIRSTUDIO-298
>                 URL: https://issues.apache.org/jira/browse/DIRSTUDIO-298
>             Project: Directory Studio
>          Issue Type: Bug
>          Components: studio-connection
>    Affects Versions: 1.1.0
>            Reporter: Pierre-Arnaud Marcelot
>            Assignee: Pierre-Arnaud Marcelot
>            Priority: Blocker
>             Fix For: 1.2.0
>
>
> I got a NPE when drag'n'dropping a connection to a folder with the latest trunk version.
> Here's the log.
> java.lang.NullPointerException
> 	at org.apache.directory.studio.connection.ui.dnd.DropConnectionListener.drop(DropConnectionListener.java:209)
> 	at org.eclipse.swt.dnd.DNDListener.handleEvent(DNDListener.java:90)
> 	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1495)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1519)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1504)
> 	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1295)
> 	at org.eclipse.swt.dnd.DropTarget.dragReceiveHandler(DropTarget.java:408)
> 	at org.eclipse.swt.dnd.DropTarget.DragReceiveHandler(DropTarget.java:237)
> 	at org.eclipse.swt.internal.carbon.OS.TrackDrag(Native Method)
> 	at org.eclipse.swt.dnd.DragSource.drag(DragSource.java:347)
> 	at org.eclipse.swt.dnd.DragSource$1.handleEvent(DragSource.java:163)
> 	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1495)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1519)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1504)
> 	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1295)
> 	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3350)
> 	at org.eclipse.swt.widgets.Control.sendTrackEvents(Control.java:2839)
> 	at org.eclipse.swt.widgets.Control.kEventControlTrack(Control.java:1961)
> 	at org.eclipse.swt.widgets.Widget.controlProc(Widget.java:367)
> 	at org.eclipse.swt.widgets.Display.controlProc(Display.java:827)
> 	at org.eclipse.swt.internal.carbon.OS.CallNextEventHandler(Native Method)
> 	at org.eclipse.swt.widgets.Tree.kEventMouseDown(Tree.java:2363)
> 	at org.eclipse.swt.widgets.Widget.mouseProc(Widget.java:1262)
> 	at org.eclipse.swt.widgets.Display.mouseProc(Display.java:2815)
> 	at org.eclipse.swt.internal.carbon.OS.SendEventToEventTarget(Native Method)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2934)
> 	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389)
> 	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
> 	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219)
> 	at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
> 	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289)
> 	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461)
> 	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
> 	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106)
> 	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:169)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:585)
> 	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:508)
> 	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
> 	at org.eclipse.equinox.launcher.Main.run(Main.java:1173)
> 	at org.eclipse.equinox.launcher.Main.main(Main.java:1148)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message