home *** CD-ROM | disk | FTP | other *** search
/ PC Plus SuperCD (UK) 2000 March / pcp161a.iso / handson / files / copyjava.exe / com / sun / java / swing / plaf / IconUIResource.class (.txt) < prev    next >
Encoding:
Java Class File  |  1998-02-26  |  882 b   |  31 lines

  1. package com.sun.java.swing.plaf;
  2.  
  3. import com.sun.java.swing.Icon;
  4. import java.awt.Component;
  5. import java.awt.Graphics;
  6. import java.io.Serializable;
  7.  
  8. public class IconUIResource implements Icon, UIResource, Serializable {
  9.    private Icon delegate;
  10.  
  11.    public IconUIResource(Icon var1) {
  12.       if (var1 == null) {
  13.          throw new IllegalArgumentException("null delegate icon argument");
  14.       } else {
  15.          this.delegate = var1;
  16.       }
  17.    }
  18.  
  19.    public void paintIcon(Component var1, Graphics var2, int var3, int var4) {
  20.       this.delegate.paintIcon(var1, var2, var3, var4);
  21.    }
  22.  
  23.    public int getIconWidth() {
  24.       return this.delegate.getIconWidth();
  25.    }
  26.  
  27.    public int getIconHeight() {
  28.       return this.delegate.getIconHeight();
  29.    }
  30. }
  31.