1 19 20 package org.netbeans.modules.diff.cmdline; 21 22 import java.beans.*; 23 24 import org.openide.util.NbBundle; 25 import org.openide.util.Utilities; 26 27 32 public class CmdlineDiffProviderBeanInfo extends SimpleBeanInfo { 33 34 41 public BeanDescriptor getBeanDescriptor() { 42 return new BeanDescriptor(CmdlineDiffProvider.class); 43 } 44 45 57 public PropertyDescriptor[] getPropertyDescriptors() { 58 PropertyDescriptor[] desc; 59 try { 60 PropertyDescriptor diffCommand = new PropertyDescriptor("diffCommand", CmdlineDiffProvider.class); 61 diffCommand.setDisplayName (NbBundle.getMessage(CmdlineDiffProviderBeanInfo.class, "PROP_diffCmd")); 62 diffCommand.setShortDescription (NbBundle.getMessage(CmdlineDiffProviderBeanInfo.class, "HINT_diffCmd")); 63 desc = new PropertyDescriptor[] { diffCommand }; 64 } catch (IntrospectionException ex) { 65 org.openide.ErrorManager.getDefault().notify(ex); 66 desc = null; 67 } 68 return desc; 69 } 70 71 79 public int getDefaultPropertyIndex() { 80 return 0; 81 } 82 83 104 public java.awt.Image getIcon(int iconKind) { 105 switch (iconKind) { 106 case ICON_COLOR_16x16: 107 return Utilities.loadImage("org/netbeans/modules/diff/diffSettingsIcon.gif", true); } 109 return null; 110 } 111 112 } 113 114 | Popular Tags |