int getAdjustedDropAction(int action, int allowed) { int possibleAction = action; if ((possibleAction & allowed) == 0) { possibleAction = allowed; } if ((possibleAction & getNodeAllowedActions()) == 0) { possibleAction = getNodeAllowedActions(); } return possibleAction; }
private boolean canReorderWhenMoving(Node folder, Node[] dragNodes) { if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_MOVE) == 0) { return false; } return canReorder( folder, dragNodes ); }
public void dragEnter (DragSourceDragEvent dsde) { dsde.getDragSourceContext().setCursor(DragDropUtilities.chooseCursor( dsde.getDropAction (), canDrag(dsde.getUserAction (), exDnD.getNodeAllowedActions ()))); }
public void dragOver (DragSourceDragEvent dsde) { dsde.getDragSourceContext().setCursor(DragDropUtilities.chooseCursor( dsde.getDropAction (), canDrag(dsde.getUserAction (), exDnD.getNodeAllowedActions ()))); }
public void dragEnter (DragSourceDragEvent dsde) { dsde.getDragSourceContext().setCursor(DragDropUtilities.chooseCursor( dsde.getDropAction (), canDrag(dsde.getUserAction (), exDnD.getNodeAllowedActions ()))); }
public void dragOver (DragSourceDragEvent dsde) { dsde.getDragSourceContext().setCursor(DragDropUtilities.chooseCursor( dsde.getDropAction (), canDrag(dsde.getUserAction (), exDnD.getNodeAllowedActions ()))); }
private boolean canReorder (Node folder, Node[] dragNodes) { if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_MOVE) == 0) { return false; } if (folder==null||dragNodes.length==0) { return false; } // has folder a index cookie? Index ic = (Index)folder.getCookie (Index.class); if (ic==null) { return false; } // folder has index cookie // check if all dragNodes are from same folder for (int i=0; i<dragNodes.length; i++) { // bugfix #23988, check if dragNodes[i] isn't null if (dragNodes[i]==null) { return false; } if (dragNodes[i].getParentNode ()==null) return false; if (!dragNodes[i].getParentNode ().equals (folder)) return false; } return true; }
private boolean canReorder (Node folder, Node[] dragNodes) { if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_MOVE) == 0) { return false; } if (folder==null||dragNodes.length==0) { return false; } // has folder a index cookie? Index ic = (Index)folder.getCookie (Index.class); if (ic==null) { return false; } // folder has index cookie // check if all dragNodes are from same folder for (int i=0; i<dragNodes.length; i++) { // bugfix #23988, check if dragNodes[i] isn't null if (dragNodes[i]==null) { return false; } if (dragNodes[i].getParentNode ()==null) return false; if (!dragNodes[i].getParentNode ().equals (folder)) return false; } return true; }
if (ExplorerDnDManager.getDefault ().getNodeAllowedActions () == DnDConstants.ACTION_NONE) { return false;
if (ExplorerDnDManager.getDefault().getNodeAllowedActions() == DnDConstants.ACTION_NONE) { return false;
if (ExplorerDnDManager.getDefault ().getNodeAllowedActions () == DnDConstants.ACTION_NONE) { return false;
if (ExplorerDnDManager.getDefault().getNodeAllowedActions() == DnDConstants.ACTION_NONE) { return false;
if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_MOVE) != 0) { ptCut = DragDropUtilities.getPasteTypes (dropNode, ExplorerDnDManager.getDefault ().getDraggedTransferable (true)); if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_COPY) != 0){ ptCopy = DragDropUtilities.getPasteTypes (dropNode, ExplorerDnDManager.getDefault ().getDraggedTransferable (false));
private boolean canReorder(Node folder, Node[] dragNodes) { if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_MOVE) == 0) { log("canReorder returning false 1"); return false;
if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_MOVE) != 0) { ptCut = DragDropUtilities.getPasteTypes( dropNode, ExplorerDnDManager.getDefault().getDraggedTransferable(true) if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_COPY) != 0) { ptCopy = DragDropUtilities.getPasteTypes( dropNode, ExplorerDnDManager.getDefault().getDraggedTransferable(false)
if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_MOVE) != 0) { ptCut = DragDropUtilities.getPasteTypes( dropNode, ExplorerDnDManager.getDefault().getDraggedTransferable(true) if ((ExplorerDnDManager.getDefault().getNodeAllowedActions() & DnDConstants.ACTION_COPY) != 0) { ptCopy = DragDropUtilities.getPasteTypes( dropNode, ExplorerDnDManager.getDefault().getDraggedTransferable(false)
if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_MOVE) != 0) { ptCut = DragDropUtilities.getPasteTypes (dropNode, ExplorerDnDManager.getDefault ().getDraggedTransferable (true)); if ((ExplorerDnDManager.getDefault ().getNodeAllowedActions () & DnDConstants.ACTION_COPY) != 0){ ptCopy = DragDropUtilities.getPasteTypes (dropNode, ExplorerDnDManager.getDefault ().getDraggedTransferable (false));