mirror of
https://github.com/geometer/FBReaderJ.git
synced 2025-10-05 02:39:23 +02:00
use standard book key for selected book in library
This commit is contained in:
parent
a9d948322c
commit
d4d37f45c9
2 changed files with 6 additions and 15 deletions
|
@ -21,8 +21,8 @@ package org.geometerplus.android.fbreader;
|
|||
|
||||
import android.content.Intent;
|
||||
|
||||
import org.geometerplus.fbreader.book.SerializerUtil;
|
||||
import org.geometerplus.fbreader.fbreader.FBReaderApp;
|
||||
import org.geometerplus.fbreader.bookmodel.BookModel;
|
||||
|
||||
import org.geometerplus.android.fbreader.library.LibraryActivity;
|
||||
|
||||
|
@ -33,10 +33,9 @@ class ShowLibraryAction extends FBAndroidAction {
|
|||
|
||||
@Override
|
||||
protected void run(Object ... params) {
|
||||
final BookModel model = Reader.Model;
|
||||
Intent intent = new Intent(BaseActivity.getApplicationContext(), LibraryActivity.class);
|
||||
if (model != null && model.Book != null) {
|
||||
intent.putExtra(LibraryActivity.SELECTED_BOOK_PATH_KEY, model.Book.File.getPath());
|
||||
final Intent intent = new Intent(BaseActivity.getApplicationContext(), LibraryActivity.class);
|
||||
if (Reader.Model != null) {
|
||||
intent.putExtra(FBReader.BOOK_KEY, SerializerUtil.serialize(Reader.Model.Book));
|
||||
}
|
||||
OrientationUtil.startActivity(BaseActivity, intent);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue