Remove an unneeded FrameLayout in the ExpandableListFragment layout.
authorkruland2607 <kruland2607@180e2498-e6e9-4542-8430-84ac67f01cd8>
Fri, 10 Feb 2012 02:28:54 +0000 (02:28 +0000)
committerkruland2607 <kruland2607@180e2498-e6e9-4542-8430-84ac67f01cd8>
Fri, 10 Feb 2012 02:28:54 +0000 (02:28 +0000)
git-svn-id: https://openrocket.svn.sourceforge.net/svnroot/openrocket/trunk@406 180e2498-e6e9-4542-8430-84ac67f01cd8

android/src/net/sf/openrocket/android/util/ExpandableListFragment.java

index 47fc7fe2d5664d3a8f872e6d42fe4c7975fd3073..e72cc36fd3ac21baa1e4c8410c09f623368b7257 100644 (file)
@@ -36,7 +36,6 @@ ExpandableListView.OnGroupCollapseListener, ExpandableListView.OnGroupExpandList
 {\r
 \r
        static final int INTERNAL_EMPTY_ID = 0x00ff0001;\r
-       static final int INTERNAL_LIST_CONTAINER_ID = 0x00ff0003;\r
 \r
        final private Handler mHandler = new Handler();\r
 \r
@@ -82,13 +81,10 @@ ExpandableListView.OnGroupCollapseListener, ExpandableListView.OnGroupExpandList
        public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\r
                FrameLayout root = new FrameLayout(getActivity());\r
 \r
-               FrameLayout lframe = new FrameLayout(getActivity());\r
-               lframe.setId(INTERNAL_LIST_CONTAINER_ID);\r
-\r
                TextView tv = new TextView(getActivity());\r
                tv.setId(INTERNAL_EMPTY_ID);\r
                tv.setGravity(Gravity.CENTER);\r
-               lframe.addView(tv,\r
+               root.addView(tv,\r
                                new FrameLayout.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.FILL_PARENT));\r
 \r
                ExpandableListView lv = new ExpandableListView(getActivity());\r
@@ -98,10 +94,7 @@ ExpandableListView.OnGroupCollapseListener, ExpandableListView.OnGroupExpandList
                lv.setOnGroupExpandListener(this);\r
                lv.setOnGroupCollapseListener(this);\r
 \r
-               lframe.addView(lv,\r
-                               new FrameLayout.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.FILL_PARENT));\r
-\r
-               root.addView(lframe, new FrameLayout.LayoutParams(\r
+               root.addView(lv, new FrameLayout.LayoutParams(\r
                                ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.FILL_PARENT));\r
 \r
                ListView.LayoutParams lp =\r
@@ -272,7 +265,7 @@ ExpandableListView.OnGroupCollapseListener, ExpandableListView.OnGroupExpandList
                        if (mStandardEmptyView == null) {\r
                                mEmptyView = root.findViewById(android.R.id.empty);\r
                        }\r
-                       mListContainer = root.findViewById(INTERNAL_LIST_CONTAINER_ID);\r
+                       mListContainer = root.findViewById(android.R.id.list);\r
                        View rawListView = root.findViewById(android.R.id.list);\r
                        if (!(rawListView instanceof ExpandableListView)) {\r
                                if (rawListView == null) {\r