Android 默认修改壁纸

一.Android7.1

 

二.

--- a/frameworks/base/core/res/res/values/symbols.xml
+++ b/frameworks/base/core/res/res/values/symbols.xml
@@ -1160,6 +1160,7 @@
   <java-symbol type="array" name="config_gpsParameters" />
 
   <java-symbol type="drawable" name="default_wallpaper" />
+  <java-symbol type="drawable" name="custom_wallpaper" />
   <java-symbol type="drawable" name="default_lock_wallpaper" />
   <java-symbol type="drawable" name="indicator_input_error" />
   <java-symbol type="drawable" name="popup_bottom_dark" />

 

--- a/frameworks/base/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java
+++ b/frameworks/base/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java
@@ -1490,7 +1490,8 @@ public class WallpaperManagerService extends IWallpaperManager.Stub {
     }
 
     private Bitmap getDefaultWallpaper(Context context) {
-            int    defaultResId = com.android.internal.R.drawable.default_wallpaper;
+            //int    defaultResId = com.android.internal.R.drawable.default_wallpaper;
+			int    defaultResId = com.android.internal.R.drawable.custom_wallpaper;
         InputStream is = getDefaultWallpaperISFromFile();
         if (is == null) {
             is = context.getResources().openRawResource(defaultResId);

  

 

 

posted @ 2020-10-27 14:21  CrushGirl  阅读(1357)  评论(0编辑  收藏  举报