Ejemplo n.º 1
0
 /**
  * If the last diagram tab and it's undo history (=controller) is empty return true, else return
  * false
  */
 private boolean lastTabIsEmpty() {
   if (!this.diagrams.isEmpty()) {
     DiagramHandler lastDiagram = this.diagrams.get(diagrams.size() - 1);
     if (lastDiagram.getController().isEmpty()
         && lastDiagram.getDrawPanel().getAllEntities().isEmpty()) {
       return true;
     }
   }
   return false;
 }