在launcher WallpaperCropActivity类中的getDefaultWallpaperSize方法中添加
Point defaultSize = new Point();
windowManager.getDefaultDisplay().getRealSize(defaultSize);
defaultWidth = defaultSize.x;
defaultHeight = defaultSize.y;