title: how to get image from gridview list when i click image, i'm using picasso library
body: <p>i want when i click image from gridview, image send to new layout (Details Image)</p>
  
  <p>this is MainActivity</p>
  
  <pre><code>public class MainActivity extends Activity {
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
      GridView gridview = (GridView) findViewById(R.id.gridview);
      gridview.setAdapter(new ImageAdapter(this));
  
      gridview.setOnItemClickListener(new OnItemClickListener() {
  
          @Override
          public void onItemClick(AdapterView&lt;?&gt; arg0, View arg1, int arg2,
                  long arg3) {
  
              Intent i = new  Intent(getApplicationContext(), SingleViewActivity.class);
              i.putExtra("arg3", arg2);
              startActivity(i);
              // TODO Auto-generated method stub
              Toast.makeText(getApplicationContext(), "okey", Toast.LENGTH_SHORT).show();
          }
      });
  
  }
  </code></pre>
  
  <p>ImageAdapter</p>
  
  <pre><code>public class ImageAdapter extends BaseAdapter {
  public static final String URL ="http://api.androidhive.info/json/movies/";
  Context mContext;
  int mThumbIds = 18;
  public ImageAdapter(Context c) {
      mContext = c;
  }
  
  public int getCount() {
       return mThumbIds;
  }
  
  public Object getItem(int position) {
      return null;
  }
  
  public long getItemId(int position) {
      return 0;
  }
  
  // create a new ImageView for each item referenced by the Adapter
  public View getView(int position, View convertView, ViewGroup parent) {
      ImageView imageView;
      if (convertView == null) {  // if it's not recycled, initialize some attributes
          imageView = new ImageView(mContext);
          imageView.setLayoutParams(new GridView.LayoutParams(95, 95));
     //     imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
          imageView.setPadding(4, 4, 4, 4);
      } else {
          imageView = (ImageView) convertView;
      }
  
      Picasso.with(this.mContext)
      .load(URL + position +".jpg")
    //  .placeholder(R.drawable.loader).error(R.drawable.ic_launcher).fit()
     .into(imageView);
  
  
    //  imageView.setImageResource(mThumbIds[position]);
     return imageView;
      }
  // references to our images }
  </code></pre>
  
  <p>in here i try get image from gridview, i try use intent, it's not work</p>
  
  <p>Details Image</p>
  
  <pre><code>public class SingleViewActivity extends Activity {
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      // TODO Auto-generated method stub
      super.onCreate(savedInstanceState);
      setContentView(R.layout.single_view);
      Intent i = getIntent();
      int position = i.getExtras().getInt("arg3");
      ImageAdapter imageAdapter = new ImageAdapter(this);
  
      ImageView imageView = (ImageView) findViewById(R.id.SingleView);
  
  
      imageView.setImageResource(imageAdapter.getItemViewType(position));}}
  </code></pre>
  
  <p>can anyone help me</p>