void (Window window, String operation, long type, long... params) { try { ComponentPeer peer = AWTAccessor.getComponentAccessor().getPeer(window); if (peer == null) throw new IllegalStateException(window + " has no peer"); long windowId = (Long)getWindow.invoke(peer); long screen = (Long)getScreenNumber.invoke(peer); long rootWindow = getRootWindow(screen); sendClientMessage(rootWindow, windowId, type, params); } catch (Throwable t) { LOG.info("cannot " + operation, t); } }