|
|
@ -98,9 +98,13 @@ public class BookmarksFragment extends Fragment implements View.OnClickListener, |
|
|
|
return Observable.create(new Action<BookmarkViewAdapter>() { |
|
|
|
return Observable.create(new Action<BookmarkViewAdapter>() { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void onSubscribe(@NonNull Subscriber<BookmarkViewAdapter> subscriber) { |
|
|
|
public void onSubscribe(@NonNull Subscriber<BookmarkViewAdapter> subscriber) { |
|
|
|
mBookmarkAdapter = new BookmarkViewAdapter(getContext(), mBookmarks); |
|
|
|
Context context = getContext(); |
|
|
|
setBookmarkDataSet(mBookmarkManager.getBookmarksFromFolder(null, true), false); |
|
|
|
if (context != null) { |
|
|
|
subscriber.onNext(mBookmarkAdapter); |
|
|
|
mBookmarkAdapter = new BookmarkViewAdapter(getContext(), mBookmarks); |
|
|
|
|
|
|
|
setBookmarkDataSet(mBookmarkManager.getBookmarksFromFolder(null, true), false); |
|
|
|
|
|
|
|
subscriber.onNext(mBookmarkAdapter); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
subscriber.onComplete(); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|