Move some function to manager
fix get empty page when page flush