Page Curl. Switc between activities
<p>I downloaded the page curl project in github to apply it on my project using gridview. Once I click the image in gridview it will go to another activity in which there are arrays of image which I will pass the id from my gridview to my fullview activity using bundle. I want to use the page curl animation to slide between image in fullview so that the use will not have to go back to gridview just to see another image. But I can't pass an Integer to an ARRAYLIST. Here are the snippets:</p>

<p>This is my pagecurl adapter in this link: <a href="http://pastebin.com/JCq2YD6r" rel="nofollow">http://pastebin.com/JCq2YD6r</a></p>

<p>and my Base adapter for my gridview is here:</p>

<pre><code>import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;
import android.util.Log;
import android.util.TypedValue;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.GridView;
import android.widget.ImageView;
import android.widget.Toast;

public class ImageAdapter extends BaseAdapter {
    private Context mContext;

    public Integer[] mThumbIds = {
            R.drawable.r01,R.drawable.r02
            ,R.drawable.r03,R.drawable.r04,
            R.drawable.r05,R.drawable.r06,
            R.drawable.r07,R.drawable.r08,
            R.drawable.r09,R.drawable.r10,
            R.drawable.r11,R.drawable.r12



    };
    public ImageAdapter(Context c){
        mContext = c;
    }
    public int getCount() {
        // TODO Auto-generated method stub
        return  mThumbIds.length;
    }

    public Object getItem(int position) {
        // TODO Auto-generated method stub
        return mThumbIds[position];
    }

    public long getItemId(int position) {
        // TODO Auto-generated method stub
        return 0;
    }

    public View getView(int position, View convertView, ViewGroup parent) {
        // TODO Auto-generated method stub
        ImageView imageView;

        SharedPreferences app_preferences = 
                PreferenceManager.getDefaultSharedPreferences(MainTab.current_act);
        int dpw = app_preferences.getInt("dpiw", 0);

        Log.i("IMmmm" , "" + dpw);
//      if (convertView == null) {  
         imageView = new ImageView(mContext);
         imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
        imageView.setImageResource(mThumbIds[position]);


//        int width = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 150, parent.getResources().getDisplayMetrics());
//        int height = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 175, parent.getResources().getDisplayMetrics());

        final float scale = parent.getResources().getDisplayMetrics().density;
        int width = (int) (100 * scale + 0.5f);
        int height = (int) (150 * scale + 0.5f);
        Log.i("with h " , ""+width + "  " + height + "   scale   " + scale );

        imageView.setLayoutParams(new GridView.LayoutParams(width, height));
        //}

//      } else {
//          imageView = (ImageView) convertView;
//        }

        return imageView;
    }


}
</code></pre>

<p>This is the part i want to change in page curl adapter</p>

<pre><code>    // Create pages
    mPages = new ArrayList&lt;Bitmap&gt;();
    mPages.add(BitmapFactory.decodeResource(getResources(), R.drawable.ic_launcher));
    mPages.add(BitmapFactory.decodeResource(getResources(), R.drawable.ic_launcher));
</code></pre>

<p>How can I pass the Array of Integer to this arraylist the is bitmap? And by the way what do you call this? Arraylist? Is that arraylist of a bitmap?? :)</p>
