menualert.xml 입니다.

 

 

<?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">
 
 
  <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/Linear1" android:background="#ffffff">
   <TextView  android:textSize="18sp" android:layout_width="fill_parent" android:layout_height="wrap_content" android:id="@+id/Detail" android:text="상세보기"> </TextView>
   <TextView  android:textSize="18sp" android:layout_width="fill_parent" android:layout_height="wrap_content" android:id="@+id/Mapping" android:text="지도" ></TextView>
  </LinearLayout>
</LinearLayout>

 

 

 

 

그리고 아래는 실제로   LayoutInflater 를 이요해서   Customizing 하는 부분입니다.

 

 

  listView.setAdapter(adapter);
  
  listView.setOnItemClickListener( new AdapterView.OnItemClickListener() {
   @Override
   public void onItemClick( AdapterView<?>  arg0 , View v , int position , long arg3 ) {
    LayoutInflater vi = (LayoutInflater)getSystemService( Context.LAYOUT_INFLATER_SERVICE );
    View customView;
    customView = vi.inflate( R.layout.menualert , null);
    
    AlertDialog.Builder dialog = new AlertDialog.Builder(
      main.this);
    dialog.setTitle( "메뉴를 선택하세요" );
    dialog.setView( customView );
    
    dialog.show();
    }
  });

 

 

 

리스트 뷰에서 각 아이템을 클릭 했을 때,  AlertDialog 를 띄워주는 것인데

 

이와 같이 코드를 작성해 테스트 해보니

 

원하는 모양의( 예상했던 )  AlertDialog  의 뷰가 나오지 않고 영 이상하게

 

첨부파일의 화면과 같이 나옵니다. ㅠㅠ

 

뭐가 잘못 된것인지 잘 모르겠어서 질문 올립니다.