@Override
      public void dispose() {
        ConsoleHistoryController controller = getController(myConsole);
        if (controller == ConsoleHistoryController.this) {
          ControllerRegistry controllerRegistry = ApplicationManager.getApplication().getServiceIfCreated(ControllerRegistry.class);
          if (controllerRegistry != null) {
            controllerRegistry.controllers.remove(myConsole);
          }
        }
        saveHistory();
      }
@Override
      public void dispose()