@Override public void onStart() { super.onStart(); mBus = new Bus(ThreadEnforcer.ANY); mBus.register(this); if (mSpritzer == null) { mSpritzView.setText(getActivity().getString(R.string.select_epub)); } else { mSpritzer.setEventBus(mBus); mSpritzer.swapTextView(mSpritzView); if (!mSpritzer.isPlaying()) { updateMetaUi(); showMetaUi(true); } } }
@Override public void onStart() { super.onStart(); mBus = new Bus(ThreadEnforcer.ANY); mBus.register(this); if (mSpritzer == null) { mSpritzer = new EpubSpritzer(mSpritzView); if (mSpritzer.getBook() == null) { mSpritzView.setText(getString(R.string.select_epub)); } else { // EpubSpritzer loaded the last book being reads updateMetaUi(); showMetaUi(true); } } else { mSpritzer.setEventBus(mBus); mSpritzer.swapTextView(mSpritzView); if (!mSpritzer.isPlaying()) { updateMetaUi(); showMetaUi(true); } } }