Yeah this is almost certainly a difference in compatibility mode, which is enabled by default for apps built against 1.5 or earlier and disabled by default for 1.6 or later targets.
On Tue, Mar 23, 2010 at 12:48 PM, Lance Nanek <[email protected]> wrote: > One thing to check when seeing unexpectedly small screen sizes is to > make sure you aren't in compatibility mode: > >For instance, suppose a given device is using a WVGA high-denisty screen, > which is 480x800 and about the same size as a traditional HVGA screen, but > it's running an app that states that it does not support multiple densities. > In this case, the system will "lie" to the application when it queries for > screen dimensions, and report 320x533. > http://developer.android.com/intl/de/guide/practices/screens_support.html > > On Mar 23, 12:40 pm, JP <[email protected]> wrote: > > I am rolling a couple of apps with one forked off of the original. > > This means they share a lot of code and layouts. > > In both cases, the main view is a MapView, and I also use camera > > previews. > > I am in the process of porting the forked-off app to Android 2.x now > > (found a sponsor to do that, would have dropped it otherwise...), and > > to my surprise I found that on the bigger screen (of the Nexus One), I > > get a screen size/scale different from the original app. From a layout > > perspective I have no problem, but I wonder how I can control which > > screen size is being used here. > > What I am getting when calling MapView.getWidth() and .getHeight() > > (similarly with the corresponding calls to determine camera preview > > screen size): > > Original app: width: 320 - height: 508 > > Forked off: width: 480 - height: 762 > > I combed through the various layout and manifest files of the apps, as > > well as documentation (I know a lot has been written about this) and > > this very forum, but could not find anything that stuck out. > > Any pointers where I can set/select the screen size for the app (or > > individual views) are welcome, THX in advance! > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected]<android-developers%[email protected]> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > > To unsubscribe from this group, send email to android-developers+ > unsubscribegooglegroups.com or reply to this email with the words "REMOVE > ME" as the subject. > -- Dianne Hackborn Android framework engineer [email protected] Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe from this group, send email to android-developers+unsubscribegooglegroups.com or reply to this email with the words "REMOVE ME" as the subject.

