/** * This implementation only calls clipboardCopy supposing that * copy to clipboard and copy by d'n'd are similar. * * @return transferable to represent this node during a drag * @exception IOException when the * cut cannot be performed */ public Transferable drag() throws IOException { return clipboardCopy(); }
/** * This implementation only calls clipboardCopy supposing that * copy to clipboard and copy by d'n'd are similar. * * @return transferable to represent this node during a drag * @exception IOException when the * cut cannot be performed */ public Transferable drag () throws IOException { return clipboardCopy (); }
/** * This implementation only calls clipboardCopy supposing that * copy to clipboard and copy by d'n'd are similar. * * @return transferable to represent this node during a drag * @exception IOException when the * cut cannot be performed */ public Transferable drag () throws IOException { return clipboardCopy (); }
@Override public Transferable clipboardCopy() throws IOException { Transferable deflt = super.clipboardCopy(); ExTransferable enriched = ExTransferable.create(deflt); ExTransferable.Single ex = new ExTransferable.Single(DataFlavor.stringFlavor) { @Override protected Object getData() { return "<dependency>\n" + //NOI18N " <groupId>" + record.getGroupId() + "</groupId>\n" + //NOI18N " <artifactId>" + record.getArtifactId() + "</artifactId>\n" + //NOI18N " <version>" + record.getVersion() + "</version>\n" + //NOI18N "</dependency>"; //NOI18N } }; enriched.put(ex); return enriched; }
/** Copy this node to the clipboard. * * @return {@link org.openide.util.datatransfer.ExTransferable.Single} with one copy flavor * @throws IOException if it could not copy * @see NodeTransfer */ public Transferable clipboardCopy () throws IOException { ExTransferable t = ExTransferable.create (super.clipboardCopy ()); t.put (LoaderTransfer.transferable ( getDataObject (), LoaderTransfer.CLIPBOARD_COPY) ); return t; }
public Transferable clipboardCopy() throws IOException { if (Util.isSpecialBean(liveBean)) { return null; } Transferable deflt = super.clipboardCopy(); ExTransferable enriched = ExTransferable.create(deflt); enriched.put((ExTransferable.Single)((LiveUnit)liveBean.getDesignContext()).copyBeans(new DesignBean[] {liveBean})); return enriched; }