void endDispatching() { xembedLog.fine("End dispatching for " + Long.toHexString(xembed.handle)); XToolkit.awtLock(); try { XDropTargetRegistry.getRegistry().unregisterXEmbedClient(getWindow(), xembed.handle); // We can't deselect input since someone else might be interested in it XToolkit.removeEventDispatcher(xembed.handle, xembed); } finally { XToolkit.awtUnlock(); } }
public void dispatchEvent(XEvent ev) { if (ev.get_type() == XConstants.SelectionNotify) { final XSelectionEvent xse = ev.get_xselection(); XClipboard clipboard = null; synchronized (XClipboard.classLock) { if (targetsAtom2Clipboard != null && !targetsAtom2Clipboard.isEmpty()) { XToolkit.removeEventDispatcher(XWindow.getXAWTRootWindow().getWindow(), this); return; } final long propertyAtom = xse.get_property(); clipboard = targetsAtom2Clipboard.get(propertyAtom); } if (null != clipboard) { clipboard.checkChange(xse); } } }