OSDN Git Service

Report the new size to wallpapers when the requested size changed.
authorJoe Onorato <joeo@android.com>
Fri, 29 Oct 2010 01:03:23 +0000 (18:03 -0700)
committerJoe Onorato <joeo@android.com>
Fri, 29 Oct 2010 01:04:10 +0000 (18:04 -0700)
We were telling the app, but we weren't saving the data for ourselves.
This also tells them to re-scroll when there's a new size.

Bug: 3144373
Change-Id: I9d12b714119ff02dd7d7f1cfa997d8a44475b9e9

core/java/android/service/wallpaper/WallpaperService.java

index 9645a17..26346d2 100644 (file)
@@ -655,7 +655,10 @@ public abstract class WallpaperService extends Service {
             if (!mDestroyed) {
                 if (DEBUG) Log.v(TAG, "onDesiredSizeChanged("
                         + desiredWidth + "," + desiredHeight + "): " + this);
+                mIWallpaperEngine.mReqWidth = desiredWidth;
+                mIWallpaperEngine.mReqHeight = desiredHeight;
                 onDesiredSizeChanged(desiredWidth, desiredHeight);
+                doOffsetsChanged();
             }
         }