mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-22 16:03:15 +00:00
WIP
This commit is contained in:
parent
c45847ecd2
commit
0da5e8a961
|
@ -71,10 +71,12 @@ public class ComponentViewerTopFragment extends Fragment {
|
|||
recyclerView.setAdapter(viewerBodyAdapter);
|
||||
|
||||
document.getDocument(documentId).thenAccept(documentDetail -> {
|
||||
ArrayList<Page> pages = documentDetail.getPages();
|
||||
viewerBodyAdapter.setPages(pages);
|
||||
viewerBodyAdapter.setPages(documentDetail.getPages());
|
||||
// getActivity().runOnUiThread(() -> {
|
||||
// viewerBodyAdapter.notifyItemRangeChanged(0, pages.size());
|
||||
// });
|
||||
getActivity().runOnUiThread(() -> {
|
||||
viewerBodyAdapter.notifyItemRangeChanged(0, pages.size());
|
||||
viewerBodyAdapter.notifyDataSetChanged();
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
@ -139,9 +139,11 @@ public class DocumentImpl implements Document {
|
|||
DocumentDetail detail = new DocumentDetail();
|
||||
|
||||
getPagesByXmlMeta(documentId).thenCompose(xmlMetaPageModels -> getPagesByXmlMetaPageModel(documentId, xmlMetaPageModels)).thenAccept(pages -> {
|
||||
logger.debug(TAG, "pages: " + pages.size());
|
||||
detail.setMeta(meta);
|
||||
detail.setPages(pages);
|
||||
});
|
||||
}).join();
|
||||
|
||||
return detail;
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user