From 40a75af610d9401be4d741f45b8bbfbde291fe1d Mon Sep 17 00:00:00 2001 From: nessup Date: Tue, 29 Oct 2013 08:56:26 -0700 Subject: [PATCH] Fixed scrolling on discover page. --- .../joumaa/workouthome/DiscoverFragment.java | 5 ++- .../src/main/res/layout/discover_fragment.xml | 41 +++++++++++-------- 2 files changed, 27 insertions(+), 19 deletions(-) diff --git a/Workoutathome/src/main/java/com/joumaa/workouthome/DiscoverFragment.java b/Workoutathome/src/main/java/com/joumaa/workouthome/DiscoverFragment.java index 550950a..e9e015a 100644 --- a/Workoutathome/src/main/java/com/joumaa/workouthome/DiscoverFragment.java +++ b/Workoutathome/src/main/java/com/joumaa/workouthome/DiscoverFragment.java @@ -45,9 +45,10 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle sa private void findViews(View view) { this.view = (ViewGroup) view; + ViewGroup columnsContainer = (ViewGroup) this.view.findViewById(R.id.columnsContainer); columns = new ArrayList(); - for (int i = 0; i < this.view.getChildCount(); i++) { - columns.add((ViewGroup) this.view.getChildAt(i)); + for (int i = 0; i < columnsContainer.getChildCount(); i++) { + columns.add((ViewGroup) columnsContainer.getChildAt(i)); } } diff --git a/Workoutathome/src/main/res/layout/discover_fragment.xml b/Workoutathome/src/main/res/layout/discover_fragment.xml index 22e17a5..4d6aca4 100644 --- a/Workoutathome/src/main/res/layout/discover_fragment.xml +++ b/Workoutathome/src/main/res/layout/discover_fragment.xml @@ -1,33 +1,40 @@ - - + - + + + + + - \ No newline at end of file + \ No newline at end of file