Fix rendered window termination (from CameraNavigationV2 branch)
Add the changes from 8ff3266c
When running simulations from Camera Navigation App, one of the desired behaviors was to close just the simulation window (and not the whole app) on pressing Esc. Esc's key handler calls imstk::Viewer::endRenderingLoop()
which in turn calls the vtkRenderWindowInteractor::TerminateApp()
. This did not close the simulation window, but instead closes the complete app on pressing Esc twice. Adding vtkRenderWindow::Finalize()
fixes the behavior and closes just the simulation window and not the whole app.