.class public MyLabel2

.super java/applet/Applet

.field private protected f Ljava/awt/Font;
.field private protected c Ljoos/lib/JoosConstants;
.field private protected noLabel Ljava/awt/Label;

.method public <init>()V
  .limit locals 1
  .limit stack 3
  aload_0
  invokenonvirtual java/applet/Applet/<init>()V
  new joos/lib/JoosConstants
  dup
  invokenonvirtual joos/lib/JoosConstants/<init>()V
  aload_0
  swap
  putfield MyLabel2/c Ljoos/lib/JoosConstants;
  return
.end method

.method public init()V
  .limit locals 3
  .limit stack 5
  new java/awt/Font
  dup
  ldc "Courier"
  aload_0
  getfield MyLabel2/c Ljoos/lib/JoosConstants;
  invokevirtual joos/lib/JoosConstants/BOLD()I
  ldc 14
  invokenonvirtual java/awt/Font/<init>(Ljava/lang/String;II)V
  aload_0
  swap
  putfield MyLabel2/f Ljava/awt/Font;
  new java/awt/Label
  dup
  ldc ""
  aload_0
  getfield MyLabel2/c Ljoos/lib/JoosConstants;
  invokevirtual joos/lib/JoosConstants/LABEL_LEFT()I
  invokenonvirtual java/awt/Label/<init>(Ljava/lang/String;I)V
  aload_0
  swap
  putfield MyLabel2/noLabel Ljava/awt/Label;
  aload_0
  getfield MyLabel2/noLabel Ljava/awt/Label;
  ldc "new text!"
  invokevirtual java/awt/Label/setText(Ljava/lang/String;)V
  aload_0
  getfield MyLabel2/noLabel Ljava/awt/Label;
  aload_0
  getfield MyLabel2/f Ljava/awt/Font;
  invokevirtual java/awt/Component/setFont(Ljava/awt/Font;)V
  aload_0
  aload_0
  getfield MyLabel2/noLabel Ljava/awt/Label;
  invokevirtual java/awt/Container/add(Ljava/awt/Component;)Ljava/awt/Component;
  pop
  return
.end method

.method public paint(Ljava/awt/Graphics;)V
  .limit locals 2
  .limit stack 4
  aload_0
  ldc "Label is displaying: "
  aload_0
  getfield MyLabel2/noLabel Ljava/awt/Label;
  invokevirtual java/awt/Label/getText()Ljava/lang/String;
  dup
  ifnonnull stop_3
  pop
  ldc "null"
  stop_3:
  invokevirtual java/lang/String/concat(Ljava/lang/String;)Ljava/lang/String;
  invokevirtual java/applet/Applet/showStatus(Ljava/lang/String;)V
  return
.end method

