안녕하세요,

대학교 학술제 참가를 위해 맨땅에 해딩하고 있는 학생입니다.

아무것도 모르는 상태에서 자바와 같이 공부하려니 참 머리가 아프네요;

 

간단한 질문입니다ㅠ 제발좀 알려주세요 ㅠㅠㅠ

 

리스트뷰 선택으로 갤러리가 있는 java로 넘어가는 것까지는 구현이 되었는데요

갤러리 java에서 갤러리 이미지 클릭시 AlertDialog 박스를 띄우고 싶습니다.

여러개의 이미지가 있는데 각각 이미지를 클릭하면 어떤식으로 값을 가져와 AlertDialog를 실행할지 잘 모르겠어요ㅠ

도와주세요~!!! ㅠㅠ 

 

아 그리고 AlertDialog 에 버튼을 여러개 넣을수는 없나요 ?

 

소스는 갤러리java의 윗부분 입니다.

---------------------------------------------------------------------------------------------------------------------------------------------------------------

public class Kb extends Activity {
    /** Called when the activity is first created. */
 @Override
 public void onCreate(Bundle savedInstanceState) {
     super.onCreate(savedInstanceState);
     setContentView(R.layout.gallery);

     Gallery g = (Gallery) findViewById(R.id.gallery);
     g.setAdapter(new ImageAdapter(this));
 }
 
 public class ImageAdapter extends BaseAdapter {
     int mGalleryItemBackground;
     private Context mContext;

     private Integer[] mImageIds = {
             R.drawable.k01,
             R.drawable.k02,
             R.drawable.k03,
             R.drawable.k04,
             R.drawable.k05
     };

.

.

.

.

.