src/macosx/classes/sun/lwawt/macosx/CDragSourceContextPeer.java

Print this page

        

@@ -108,10 +108,11 @@
         }
 
         //It sure will be LWComponentPeer instance as rootComponent is a Window
         PlatformWindow platformWindow = ((LWComponentPeer)rootComponent.getPeer()).getPlatformWindow();
         long nativeViewPtr = CPlatformWindow.getNativeViewPtr(platformWindow);
+        if (nativeViewPtr == 0L) return; // Unsupported
 
         // If there isn't any drag image make one of default appearance:
         if (fDragImage == null)
             this.setDefaultDragImage(component);