i have an imageview
and i have set a bitmap on it:
package com.integrated.mpr;
import android.app.Activity;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.Bundle;
import android.os.Environment;
import android.widget.ImageView;
import android.widget.TextView;
public class AlternativeShow extends Activity{
ImageView altiva;
@Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.alternativeshow);
File fa = new File(folder,"bmp1.png");
Bitmap bmpa = BitmapFactory.decodeFile(fa.getAbsolutePath());
altiva.setImageBitmap(bmpa);
}
}
}
I want that on touching of the screen on the imageview , the image should be zoomed >>
How can I make it possible??
Use a WebView instead. You can load your image like this:
Of course you must have your image.jpg in your assets folder.
If you have it in your SD Card…
WebView already has zoom implemented so you don’t really need to do anything 😉
Hope it helps you.