Commit f3bf8475 by Michael Koch Committed by Michael Koch

ExplicitBeanInfo.java: Explicitely import java.awt.Image.

2004-10-16  Michael Koch  <konqueror@gmx.de>

	* gnu/java/beans/ExplicitBeanInfo.java:
	Explicitely import java.awt.Image.
	(getIcon): Fixed off-by-one error.

From-SVN: r89148
parent fce22de5
2004-10-16 Michael Koch <konqueror@gmx.de>
* gnu/java/beans/ExplicitBeanInfo.java:
Explicitely import java.awt.Image.
(getIcon): Fixed off-by-one error.
2004-10-15 Andrew Haley <aph@redhat.com> 2004-10-15 Andrew Haley <aph@redhat.com>
* Makefile.am (nat_files, xlib_nat_files): New. * Makefile.am (nat_files, xlib_nat_files): New.
......
/* gnu.java.beans.ExplicitBeanInfo /* ExplicitBeanInfo.java --
Copyright (C) 1998 Free Software Foundation, Inc. Copyright (C) 1998, 2004 Free Software Foundation, Inc.
This file is part of GNU Classpath. This file is part of GNU Classpath.
...@@ -38,6 +38,7 @@ exception statement from your version. */ ...@@ -38,6 +38,7 @@ exception statement from your version. */
package gnu.java.beans; package gnu.java.beans;
import java.awt.Image;
import java.beans.BeanDescriptor; import java.beans.BeanDescriptor;
import java.beans.BeanInfo; import java.beans.BeanInfo;
import java.beans.EventSetDescriptor; import java.beans.EventSetDescriptor;
...@@ -84,7 +85,7 @@ public class ExplicitBeanInfo implements BeanInfo { ...@@ -84,7 +85,7 @@ public class ExplicitBeanInfo implements BeanInfo {
protected BeanInfo[] additionalBeanInfo; protected BeanInfo[] additionalBeanInfo;
/** The set of icons. **/ /** The set of icons. **/
protected java.awt.Image[] icons; protected Image[] icons;
public ExplicitBeanInfo(BeanDescriptor beanDescriptor, public ExplicitBeanInfo(BeanDescriptor beanDescriptor,
BeanInfo[] additionalBeanInfo, BeanInfo[] additionalBeanInfo,
...@@ -93,7 +94,7 @@ public class ExplicitBeanInfo implements BeanInfo { ...@@ -93,7 +94,7 @@ public class ExplicitBeanInfo implements BeanInfo {
EventSetDescriptor[] eventSetDescriptors, EventSetDescriptor[] eventSetDescriptors,
int defaultEventIndex, int defaultEventIndex,
MethodDescriptor[] methodDescriptors, MethodDescriptor[] methodDescriptors,
java.awt.Image[] icons) { Image[] icons) {
this.beanDescriptor = beanDescriptor; this.beanDescriptor = beanDescriptor;
this.additionalBeanInfo = additionalBeanInfo; this.additionalBeanInfo = additionalBeanInfo;
this.propertyDescriptors = propertyDescriptors; this.propertyDescriptors = propertyDescriptors;
...@@ -142,7 +143,7 @@ public class ExplicitBeanInfo implements BeanInfo { ...@@ -142,7 +143,7 @@ public class ExplicitBeanInfo implements BeanInfo {
/** Get Bean icons. /** Get Bean icons.
** @param iconType the type of icon ** @param iconType the type of icon
**/ **/
public java.awt.Image getIcon(int iconType) { public Image getIcon(int iconType) {
return icons != null ? icons[iconType] : null; return icons != null ? icons[iconType - 1] : null;
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment