I have a custom WebView and I want to get a bitmap of its content (offscreen included). I used this code, which I got from here:
public static Bitm
Okay, I've cracked this one meself. The problem indeed was in the fact that the function returned the Bitmap waay before the zooming out procedure was over, so I had to delay it.
I incorporated
Handler handler = new Handler();
handler.postDelayed(new Runnable() {
@Override
public void run() {
//bulk of my code
}
}, 1000);
which forced to change the structure of the function from public Bitmap to public void. Here's directly related thread. Despite some minor tweaks I still need to fix, the approach works like a charm