I have a GridView, which elements consist of a ViewGroup (in LinearLayout style)
My adapter is from type "baseAdapter" and holding my ViewGroup Elements.
if i make this
Using java Syntax Highlighting
- GridView myGrid = new GridView(blabla);
- MyCustomViewGroupView myView = new MyCustomViewGroupView (blabla Parameters);
- myView.setOnClickListener(new OnClickListener() {
- Log.i("TestMyView", "ok");
- }
- myGrid.add(myView);
Parsed in 0.030 seconds, using GeSHi 1.0.8.4
it works. but if i make this:
Using java Syntax Highlighting
- myGrid.setOnItemClickListener(new OnItemClickListener(){
- @Override
- public void onItemClick(AdapterView arg0, View arg1, int arg2,
- long arg3) {
- Log.i("Test", String.valueOf(arg2));
- }});
Parsed in 0.031 seconds, using GeSHi 1.0.8.4
it doesnt work. ANY ideas? Do i have to implement on my Views (which i combine to the ViewGroup myView some kind of listeners also?)



