안녕하세요?
메뉴버튼을 누르면 메뉴바가 나오고 메뉴버튼을 다시 누르면 원래대로 돌아가도록 하기위한
Layout을 구성하였습니다.
문제는 메뉴바가 나오는 부분을 FrameLayout으로 구성하였는데
뒤에 있는 View가 가려지게됩니다.
각 해상도 크기 때문에 layout_weight를 사용 안할수도 없고..
말보다는 소스를 보시는게 낫을거 같아 첨부합니다..
조금 길수도 있지만 봐주시면 감사하겠습니다.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/main"
android:orientation="vertical" >
<!-- 메인상단 빈 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="3.3"/>
<!-- 메인 중앙 메뉴버튼 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="3.3">
<ImageView
android:id="@+id/btn_mnuO"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/mnu_open"/>
</LinearLayout>
<!-- 메인하단 빈 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:orientation="vertical">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="1"/>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:orientation="horizontal"
android:layout_weight="1.2">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:layout_weight="1.7"/>
<android.support.v4.view.ViewPager
android:id="@+id/pager"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:background="@drawable/ad_edge"
android:layout_weight="1"/>
<LinearLayout
android:id="@android:id/empty"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:layout_weight="1.7"/>
</LinearLayout>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="1.5"/>
</LinearLayout>
<!-- 메뉴 프레임 에이아웃 -->
<FrameLayout
android:id="@+id/linearBar"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:visibility="gone">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<!-- 상단 빈 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="3.3"/>
<!-- 중간 메뉴 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="3.3"
android:orientation="horizontal">
<!-- 메뉴바 -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:background="@drawable/mnu_bar"
android:layout_weight="1">
<!-- 메뉴바 내부 버튼 -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:layout_weight="1">
<!-- 스크롤 뷰 -->
<HorizontalScrollView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:scrollbars="none">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_gravity="center_vertical"
android:paddingRight="20dp"
android:layout_marginLeft="10dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp">
<Button
android:id="@+id/mnu_sub1"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:background="@drawable/mnu_sub1"
android:layout_weight="1" />
<Button
android:id="@+id/mnu_sub2"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:background="@drawable/mnu_sub2"
android:layout_weight="1" />
<Button
android:id="@+id/mnu_sub3"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:background="@drawable/mnu_sub3"
android:layout_weight="1" />
</LinearLayout>
</HorizontalScrollView>
</LinearLayout>
<ImageView
android:id="@+id/btn_mnuX"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:layout_weight="9"/>
</LinearLayout>
<!-- 메뉴바 오른쪽 여백 -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:layout_weight="3"/>
</LinearLayout>
<!-- 하단 빈 레이아웃 -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_weight="1"/>
</LinearLayout>
</FrameLayout>
<!-- 메뉴 프레임 에이아웃 끝 -->
</LinearLayout>




자답입니다..
질문하고 생각하게 되네요 ..;
<!-- 상단 레이아웃 -->
<LinearLayout...... android:layout_weight = "1"/>
<!-- 중간 레이아웃 -->
<LinearLayout...... android:layout_weight = "1">
<FrameLayout /> <!-- 메뉴버튼 -->
<FrameLayout /> <!-- 메뉴바 -->
</LinearLayout>
<!--하단 레이아웃-->
<LinearLayout...... android:layout_weight = "1"/>