home *** CD-ROM | disk | FTP | other *** search
/ S283 Planetary Science &n…he Search for Life DVD 2 / DVD-ROM.iso / install / jre1_3 / lib / rt.jar / sun / java2d / SunGraphicsEnvironment$2.class (.txt) < prev    next >
Encoding:
Java Class File  |  1979-12-31  |  1.5 KB  |  49 lines

  1. package sun.java2d;
  2.  
  3. import java.security.PrivilegedAction;
  4. import sun.awt.font.NativeFontWrapper;
  5.  
  6. class SunGraphicsEnvironment$2 implements PrivilegedAction {
  7.    // $FF: synthetic field
  8.    private final SunGraphicsEnvironment this$0;
  9.  
  10.    SunGraphicsEnvironment$2(SunGraphicsEnvironment var1) {
  11.       this.this$0 = var1;
  12.    }
  13.  
  14.    public Object run() {
  15.       if (this.this$0.fontPath == null) {
  16.          this.this$0.fontPath = System.getProperty("java.awt.fonts");
  17.          if (this.this$0.fontPath.length() == 0) {
  18.             boolean var1 = false;
  19.             String var2 = System.getProperty("sun.java2d.noType1Font");
  20.             if (var2 == null) {
  21.                var1 = NativeFontWrapper.getType1FontVar();
  22.             }
  23.  
  24.             if ("true".equals(var2)) {
  25.                var1 = true;
  26.             }
  27.  
  28.             this.this$0.fontPath = NativeFontWrapper.getFontPath(var1);
  29.             SunGraphicsEnvironment.access$000(this.this$0);
  30.             this.this$0.loadNativeFonts = true;
  31.          }
  32.       }
  33.  
  34.       boolean var3 = SunGraphicsEnvironment.access$200(this.this$0, this.this$0.fontPath);
  35.       boolean var4 = false;
  36.       if (this.this$0.loadNativeFonts) {
  37.          var4 = this.this$0.registerNativeFonts();
  38.       }
  39.  
  40.       if (!var3 && !var4) {
  41.          System.out.println("\nNo fonts were found in '" + this.this$0.fontPath + "'.\n");
  42.          System.exit(2);
  43.       }
  44.  
  45.       SunGraphicsEnvironment.access$302(this.this$0, true);
  46.       return null;
  47.    }
  48. }
  49.