This commit is contained in:
r-ca 2024-01-28 13:51:04 +09:00
parent 8270156373
commit c88ab85cf2
No known key found for this signature in database
GPG Key ID: 6A72911AC73464A9

View File

@ -80,6 +80,7 @@ public class ViewerContainerFragment extends Fragment {
if (getArguments() != null){ if (getArguments() != null){
documentId = getArguments().getString("documentId"); documentId = getArguments().getString("documentId");
documentName = getArguments().getString("documentName"); documentName = getArguments().getString("documentName");
hasCombined = getArguments().getBoolean("hasCombined");
} }
} }
@ -106,6 +107,7 @@ public class ViewerContainerFragment extends Fragment {
initToolbar(toolbar, true, documentName); initToolbar(toolbar, true, documentName);
if (this.hasCombined) { if (this.hasCombined) {
logger.debug("ViewerContainerFragment", "hasCombined: " + hasCombined);
lacertaLibrary.getCombinedDocumentToxiList(documentId).thenAccept(combinedDocumentToxiList -> { lacertaLibrary.getCombinedDocumentToxiList(documentId).thenAccept(combinedDocumentToxiList -> {
for (ToxiDocumentModel toxiDocumentModel : combinedDocumentToxiList) { for (ToxiDocumentModel toxiDocumentModel : combinedDocumentToxiList) {
viewerViewPagerAdapter viewerViewPagerAdapter
@ -114,6 +116,7 @@ public class ViewerContainerFragment extends Fragment {
} }
}); });
} else { } else {
logger.debug("ViewerContainerFragment", "hasCombined: " + hasCombined);
TabLayout tabLayout = view.findViewById(R.id.tab_layout); TabLayout tabLayout = view.findViewById(R.id.tab_layout);
tabLayout.setVisibility(View.GONE); tabLayout.setVisibility(View.GONE);
viewerViewPagerAdapter.addFragment(ViewerBodyFragment.newInstance(documentId, documentName), documentName); viewerViewPagerAdapter.addFragment(ViewerBodyFragment.newInstance(documentId, documentName), documentName);