From 49fb2fab4f5ed558c0a87f5be5aee0f8116d44ce Mon Sep 17 00:00:00 2001 From: Erik Johansson Date: Fri, 23 Feb 2018 20:50:53 +0100 Subject: [PATCH] Hide subpage view when there is only one page --- .../java/com/health/openscale/gui/fragments/TableFragment.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/android_app/app/src/main/java/com/health/openscale/gui/fragments/TableFragment.java b/android_app/app/src/main/java/com/health/openscale/gui/fragments/TableFragment.java index 3485a41e..da5f5376 100644 --- a/android_app/app/src/main/java/com/health/openscale/gui/fragments/TableFragment.java +++ b/android_app/app/src/main/java/com/health/openscale/gui/fragments/TableFragment.java @@ -157,6 +157,8 @@ public class TableFragment extends Fragment implements FragmentUpdateListener { moveSubpageRight.setEnabled(selectedSubpageNr + 1 < subpageCount); subpageView.addView(moveSubpageRight); + subpageView.setVisibility(subpageCount > 1 ? View.VISIBLE : View.GONE); + tableHeaderView.removeAllViews(); ArrayList visibleMeasurements = new ArrayList<>();