private void hideOverlay(WorkbenchOverlay overlay) {
    if (overlay.isAnimated()) {
      overlay.getAnimationEnd().play();
      // make sure GlassPane starts hiding at the same time as the animation, not when the animation
      // is finished and the overlay has been hidden
      overlay.getGlassPane().setHide(true);
    } else {
      view.hideOverlay(overlay.getOverlay());
    }
  }
Makes the {@code overlay} <b>in</b>visible, along with its {@code glassPane}.

@param overlay to be hidden
workbenchfx-core/src/main/java/com/dlsc/workbenchfx/view/WorkbenchPresenter.java