@Override
 public void delete() {
   if (foreground != null) {
     foreground.deleteObserver(this);
   }
   super.delete();
   disableStartObjectObserving();
   disableEndObjectObserving();
 }
  protected void enableEndObjectObserving(ShapeGraphicalRepresentation<?> anEndObject) {

    if (anEndObject == null || !anEndObject.isValidated()) {
      return;
    }

    if (enabledEndObjectObserving) {
      disableEndObjectObserving();
    }

    if (anEndObject != null /*&& !enabledEndObjectObserving*/) {
      anEndObject.addObserver(this);
      observedEndObjects.add(anEndObject);
      if (!isDeserializing()) {
        for (Object o : anEndObject.getAncestors(true)) {
          if (getGraphicalRepresentation(o) != null) {
            getGraphicalRepresentation(o).addObserver(this);
            observedEndObjects.add(getGraphicalRepresentation(o));
          }
        }
      }
      enabledEndObjectObserving = true;
    }
  }