Android:Is this possible to generate the view's Bitmap
I have 4 layouts(views) and I wanna get their shortcuts.
I use "getDrawingCache()
",yeah,I get the pictures,but I found if I wanna get the pictures,I had to make them shown.(I mean they have to be 开发者_JAVA百科displayed to the user).
So Is there any way to get their pictures without displaying them??
Thanks in advance!
This might work
Window window = getLocalActivityManager().startActivity(Id,intent.addFlags(
Intent.FLAG_ACTIVITY_CLEAR_TOP));
window.getDecorView().buildDrawingCache();
window.getDecorView().getDrawingCache();
This is what is done to update activities in tab activity. Im not sure but its worth a try.
精彩评论