示例#1
0
  /**
   * Constructor for open a Board
   *
   * @param board
   */
  public WorkingView(Board board) {
    this.sport = board.getSport();
    this.board = board;
    tbe.setSaved(true);

    int value = board.getPath().lastIndexOf("\\");
    tbe.getFrame().setTitle("TBE - Tactic Board Editor - " + board.getPath().substring(value + 1));
    createWorkingView();
  }
示例#2
0
 /**
  * Constructor for a new Board
  *
  * @param sport
  */
 public WorkingView(Sport sport) {
   this.sport = sport;
   GraphModel model = new DefaultGraphModel();
   GraphLayoutCache view = new GraphLayoutCache(model, new TBECellViewFactory());
   this.board = new Board(model, view, sport);
   board.getDescription().setDescription(sport.getName());
   tbe.setSaved(false);
   createWorkingView();
 }