Package preseci_krugova

Examples of preseci_krugova.Tacka


       
        x = sc.nextInt();
        y = sc.nextInt();
        r = sc.nextInt();
       
        traziPreseke.dodajKrug(new Krug(new Tacka(x,y), r));
      }
    } catch (FileNotFoundException e) {
      e.printStackTrace();
    }
   
View Full Code Here


  @Override
  public void execute() {
    switch (direction) {
    case KeyEvent.VK_LEFT:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX()-1, circleToMove.getCentar().getY()));
      break;
    case KeyEvent.VK_RIGHT:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX()+1, circleToMove.getCentar().getY()));
      break;
    case KeyEvent.VK_UP:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX(), circleToMove.getCentar().getY()+1));
      break;
    case KeyEvent.VK_DOWN:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX(), circleToMove.getCentar().getY()-1));
      break;
    }
   
    MainWindow.getInstance().drawImage();
  }
View Full Code Here

  @Override
  public void undo() {
    switch (direction) {
    case KeyEvent.VK_LEFT:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX()+1, circleToMove.getCentar().getY()));
      break;
    case KeyEvent.VK_RIGHT:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX()-1, circleToMove.getCentar().getY()));
      break;
    case KeyEvent.VK_UP:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX(), circleToMove.getCentar().getY()-1));
      break;
    case KeyEvent.VK_DOWN:
      circleToMove.setCentar(new Tacka(circleToMove.getCentar().getX(), circleToMove.getCentar().getY()+1));
      break;
    }
   
    MainWindow.getInstance().drawImage();
  }
View Full Code Here

TOP

Related Classes of preseci_krugova.Tacka

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.