manageCommands(false);
navigate(ViewerPane.ABOUT_BLANK);
if (interruptR)
commands_.interruptR().execute();
server_.viewerStopped(new VoidServerRequestCallback());
// If we were viewing a Shiny application, let the rest of the app know
// that the application has been stopped
if (runningShinyAppParams_ != null)
{
runningShinyAppParams_.setState(ShinyApplicationParams.STATE_STOPPED);
events_.fireEvent(new ShinyApplicationStatusEvent(
runningShinyAppParams_));
}
runningShinyAppParams_ = null;
events_.fireEvent(new ViewerClearedEvent());
// if this was a static widget then clear the current widget
if (clearAll)
server_.viewerClearAll(new VoidServerRequestCallback(indicator));
else if (wasStaticWidget)
server_.viewerClearCurrent(new VoidServerRequestCallback(indicator));
// otherwise restore the last static widget
else
server_.viewerCurrent(new VoidServerRequestCallback());
}