use of org.openide.util.datatransfer.ExClipboard in project netbeans-mmd-plugin by raydac.
the class MMDGraphEditor method registerAsClipboardListener.
private void registerAsClipboardListener() {
final Clipboard clipboard = NbUtils.findClipboard();
if (clipboard instanceof ExClipboard) {
((ExClipboard) clipboard).addClipboardListener(this);
} else {
clipboard.addFlavorListener(this);
}
processClipboardChange(clipboard);
}
use of org.openide.util.datatransfer.ExClipboard in project netbeans-mmd-plugin by raydac.
the class MMDGraphEditor method componentClosed.
@Override
public void componentClosed() {
try {
this.mindMapPanel.dispose();
LOGGER.info("MMD Editor is disposed : " + this.mindMapPanel.toString());
} finally {
final Clipboard clipboard = NbUtils.findClipboard();
if (clipboard instanceof ExClipboard) {
((ExClipboard) clipboard).removeClipboardListener(this);
} else {
clipboard.removeFlavorListener(this);
}
super.componentClosed();
}
}
Aggregations