home *** CD-ROM | disk | FTP | other *** search
Java Source | 1997-07-30 | 1.1 KB | 42 lines |
- package borland.samples.intl.beans;
-
- import java.awt.*;
- import java.beans.*;
-
- public class ViewOnlyNavigationBarBeanInfo extends SimpleBeanInfo {
-
- public PropertyDescriptor[] getPropertyDescriptors() {
- try {
- PropertyDescriptor dataSet = new PropertyDescriptor("dataSet",
- ViewOnlyNavigationBar.class);
- PropertyDescriptor propertyDescriptor[] = { dataSet };
- return propertyDescriptor;
- } catch (Exception ex) {
- System.err.println("unexpected exeption: " + ex);
- return null;
- }
- }
-
- public EventSetDescriptor[] getEventSetDescriptors() {
- try {
- EventSetDescriptor[] eventDescriptor = new EventSetDescriptor[0];
- return eventDescriptor;
- } catch (IntrospectionException e) {
- e.printStackTrace();
- return null;
- }
- }
-
- public BeanDescriptor getBeanDescriptor() {
- return new BeanDescriptor(ViewOnlyNavigationBar.class);
- }
-
- public Image getIcon(int iconKind) {
- if (iconKind == BeanInfo.ICON_COLOR_32x32) {
- return loadImage("resources/ViewOnlyNavigationBarIconColor32.gif");
- }
- return null;
- }
-
- }
-