onEnd is called onStop