1 19 20 package org.netbeans.modules.db.explorer.actions; 21 22 import java.text.MessageFormat ; 23 24 import org.openide.*; 25 import org.openide.nodes.*; 26 import org.netbeans.modules.db.explorer.nodes.*; 27 import org.netbeans.modules.db.explorer.infos.*; 28 29 public class RemoveFromIndexAction extends DatabaseAction { 30 static final long serialVersionUID =-6856108523685993652L; 31 32 public void performAction (Node[] activatedNodes) { 33 Node node; 34 if (activatedNodes != null && activatedNodes.length>0) 35 node = activatedNodes[0]; 36 else 37 return; 38 39 try { 40 DatabaseNodeInfo info = (DatabaseNodeInfo)node.getCookie(DatabaseNodeInfo.class); 41 DatabaseNodeInfo nfo = info.getParent(nodename); 42 } catch(Exception exc) { 43 String message = MessageFormat.format(bundle().getString("ERR_UnableToRemoveFromIndex"), new String [] {exc.getMessage()}); DialogDisplayer.getDefault().notify(new NotifyDescriptor.Message(message, NotifyDescriptor.ERROR_MESSAGE)); 45 } 46 } 47 } 48 | Popular Tags |