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