Search in sources :

Example 6 with TreeNode

use of org.jcryptool.crypto.flexiprovider.ui.nodes.TreeNode in project core by jcryptool.

the class KeyDropListener method drop.

public void drop(DropTargetEvent event) {
    Widget item = event.item;
    Object tmp = event.data;
    if (item != null && tmp != null) {
        if (item instanceof TreeItem) {
            entryNode = getTopLevel((TreeNode) ((TreeItem) item).getData());
            // $NON-NLS-1$
            LogUtil.logInfo("target: " + entryNode.getTimestamp());
            entryNode.setKeyStoreAlias(new KeyStoreAlias((String) tmp));
        }
    } else {
        // $NON-NLS-1$
        LogUtil.logInfo("item is null");
    }
}
Also used : KeyStoreAlias(org.jcryptool.crypto.keystore.backend.KeyStoreAlias) TreeItem(org.eclipse.swt.widgets.TreeItem) TreeNode(org.jcryptool.crypto.flexiprovider.ui.nodes.TreeNode) ITreeNode(org.jcryptool.crypto.flexiprovider.ui.nodes.ITreeNode) Widget(org.eclipse.swt.widgets.Widget)

Aggregations

ITreeNode (org.jcryptool.crypto.flexiprovider.ui.nodes.ITreeNode)6 TreeNode (org.jcryptool.crypto.flexiprovider.ui.nodes.TreeNode)6 EntryNode (org.jcryptool.crypto.flexiprovider.operations.ui.views.nodes.EntryNode)3 InputNode (org.jcryptool.crypto.flexiprovider.operations.ui.views.nodes.io.InputNode)2 SignatureNode (org.jcryptool.crypto.flexiprovider.operations.ui.views.nodes.io.SignatureNode)2 KeyNode (org.jcryptool.crypto.flexiprovider.operations.ui.views.nodes.keys.KeyNode)2 OperationsNode (org.jcryptool.crypto.flexiprovider.operations.ui.views.nodes.ops.OperationsNode)2 AbstractHandler (org.eclipse.core.commands.AbstractHandler)1 ExecutionEvent (org.eclipse.core.commands.ExecutionEvent)1 IMenuListener (org.eclipse.jface.action.IMenuListener)1 IMenuManager (org.eclipse.jface.action.IMenuManager)1 MenuManager (org.eclipse.jface.action.MenuManager)1 ISelection (org.eclipse.jface.viewers.ISelection)1 MouseAdapter (org.eclipse.swt.events.MouseAdapter)1 MouseEvent (org.eclipse.swt.events.MouseEvent)1 Menu (org.eclipse.swt.widgets.Menu)1 ToolTip (org.eclipse.swt.widgets.ToolTip)1 Tree (org.eclipse.swt.widgets.Tree)1 TreeItem (org.eclipse.swt.widgets.TreeItem)1 Widget (org.eclipse.swt.widgets.Widget)1