得到当前View的Bit地图

得到当前View的BitmapView cvActivity.getWindow().getDecorView()Bitmap b Bitmap.createBitmap(w,h,

得到当前View的Bitmap

View cv=Activity.getWindow().getDecorView();Bitmap b = Bitmap.createBitmap(w,h, Bitmap.Config.RGB_565);    Canvas c = new Canvas(b);    cv.draw(c);
1 楼 liuborama 2010-08-30   Cannot make a static reference to the non-static method getWindow() from the type Activity
使用2.2版本的SDK,第一句出现这个错误。。