fix bug: java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState