home *** CD-ROM | disk | FTP | other *** search
/ Internet Magazine 2004 July / INTERNET119.ISO / pc / software / windows / messages / inxmail_easy / install.exe / lib / lax.jar / ZeroGa2.class (.txt) < prev    next >
Encoding:
Java Class File  |  2001-05-30  |  1.2 KB  |  60 lines

  1. import java.awt.Component;
  2. import java.awt.Dimension;
  3. import java.awt.Graphics;
  4. import java.awt.Image;
  5.  
  6. public class ZeroGa2 extends Component {
  7.    // $FF: renamed from: a java.awt.Image
  8.    public Image field_0 = null;
  9.  
  10.    public void update(Graphics var1) {
  11.       this.paint(var1);
  12.    }
  13.  
  14.    public void paint(Graphics var1) {
  15.       if (this.field_0 == null) {
  16.          super.paint(var1);
  17.       } else {
  18.          var1.clearRect(0, 0, this.getSize().width, this.getSize().height);
  19.          var1.drawImage(this.field_0, 0, 0, this);
  20.          super.paint(var1);
  21.       }
  22.  
  23.    }
  24.  
  25.    // $FF: renamed from: a (java.awt.Image) void
  26.    public void method_0(Image var1) {
  27.       if (this.field_0 != null) {
  28.          this.field_0.flush();
  29.       }
  30.  
  31.       this.field_0 = var1;
  32.       if (this.field_0 != null) {
  33.          ((Component)this).prepareImage(this.field_0, this);
  34.          this.setSize(this.getSize());
  35.          ((Component)this).repaint();
  36.       }
  37.  
  38.    }
  39.  
  40.    public Dimension getSize() {
  41.       return this.field_0 == null ? new Dimension(0, 0) : new Dimension(this.field_0.getWidth(this), this.field_0.getHeight(this));
  42.    }
  43.  
  44.    public Dimension getPreferredSize() {
  45.       return this.getSize();
  46.    }
  47.  
  48.    public Dimension getMaximumSize() {
  49.       return this.getSize();
  50.    }
  51.  
  52.    public Dimension getMinimumSize() {
  53.       return this.getSize();
  54.    }
  55.  
  56.    public void setSize(Dimension var1) {
  57.       super.setSize(this.getSize());
  58.    }
  59. }
  60.