Code example for Gallery

Methods: setAdapter

0
        	} 
        }); 
    } 
  
    public void refresh() { 
    	g.setAdapter(new ImageAdapter(this)); 
    } 
     
    public void onItemSelected(AdapterView<?> parent, View v, int position, long id) {
        //mSwitcher.setImageURI(bmlist[0]); 
    	mSwitcher.setImageDrawable(new BitmapDrawable(getResources(),bmlist[position]));
    	name.setText(namelist[position]);
    } 
  
    public void onNothingSelected(AdapterView<?> parent) {
    } 
  
    public View makeView() {
        ImageView i = new ImageView(this);
        i.setBackgroundColor(0xFF000000);
Connect your IDE to all the code out there  Get Codota for Java