Hi,

I have a development platform with a 800x480 landscape panel. For the
wallpaper, launcher (using eclair) is setting the wallpaper dimensions
to 960x800 instead of 1600x480.

Following code is the suspect (from
http://android.git.kernel.org/?p=platform/packages/apps/Launcher.git;a=blob;f=src/com/android/launcher/Launcher.java;hb=HEAD)

private void setWallpaperDimension() {
 WallpaperManager wpm = (WallpaperManager)getSystemService(WALLPAPER_SERVICE);

 Display display = getWindowManager().getDefaultDisplay();
 boolean isPortrait = display.getWidth() < display.getHeight();
 final int width = isPortrait ? display.getWidth() : display.getHeight();
 final int height = isPortrait ? display.getHeight() : display.getWidth();
 wpm.suggestDesiredDimensions(width * WALLPAPER_SCREENS_SPAN, height);
}

Should the fix be to change the above code to get the
portrait/landscape information from android:screenOrientation?

Even after I fixed above, when I attempt to change the wallpaper with
the bitmap of 1600x480  com.android.camera.cropImage is launched and
the resulting wallpaper is the cropped and zoomed version of my
original bitmap. Cropping/Zooming seems to kick-in no matter what the
dimensions of my bitmap is. I was wondering under what conditions the
cropping will kicks-in.

I am tyring to understand the logic here by digging through the code.
But, if someone can provide a quick answer or pointer to look for that
would be great.

Thanks
-Muni

-- 
unsubscribe: [email protected]
website: http://groups.google.com/group/android-porting

Reply via email to