import java.awt.*;

public class DrawCanvas extends Canvas {
  private int step = 0;
  
  public void setStep (int pStep){
    this.step = pStep;
  } 
  public void incStep (){
    this.step++;
  } 
  @Override
  public void paint( Graphics g )
  {
    super.paint( g );
    if (this.step >= 0) {
      g.drawLine( 10, 10, 100, 50 );
    } // end of if
    if (this.step > 0) {
      g.drawLine( 10, 20, 100, 60 );
    } // end of if
    if (this.step > 1) {
      g.drawLine( 10, 30, 100, 70 );
    } // end of if
  }    
}
