[android-developers] Re: The screen size of galaxy nexus (ICS )

2012-02-15 Thread Seshu
Hi... u ll get the device width and height by using Display..

check this one..

Display display = getWindowManager().getDefaultDisplay();
int targetWidth  = display.getWidth();
int targetHeight = display.getHeight();


Thanks and Regards,
S.Seshu

On Feb 15, 12:55 pm, chen ji  wrote:
> Hi All,
>
> If I use DisplayMetrics to get galaxy nexus (ICS )'s screen's width &
> Height, I found a very strange thing. It is 1184x720 if I set miniSDK
> = 8 and it is 1196*720 if I set miniSDK =7. And actually I think it
> should be 1960*720.
> Anyone can give some advices?
>
> Thanks,
>
> Ji

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: The screen size of galaxy nexus (ICS )

2012-02-15 Thread chen ji

Of course, I use the below APIs.

My question is why the value is not 1960*720. Thanks.

On 2月15日, 下午4时03分, Seshu  wrote:
> Hi... u ll get the device width and height by using Display..
>
> check ths one..
>
> Display display = getWindowManager().getDefaultDisplay();
> int targetWidth  = display.getWidth();
> int targetHeight = display.getHeight();
>
> Thanks and Regards,
> S.Seshu
>
> On Feb 15, 12:55 pm, chen ji  wrote:
>
>
>
> > Hi All,
>
> > If I use DisplayMetrics to get galaxy nexus (ICS )'s screen's width &
> > Height, I found a very strange thing. It is 1184x720 if I set miniSDK
> > = 8 and it is 1196*720 if I set miniSDK =7. And actually I think it
> > should be 1960*720.
> > Anyone can give some advices?
>
> > Thanks,
>
> > Ji- 隐藏被引用文字 -
>
> - 显示引用的文字 -

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: The screen size of galaxy nexus (ICS )

2012-02-15 Thread Mark Murphy
2012/2/15 chen ji :
> My question is why the value is not 1960*720. Thanks.

Because the screen size of a Galaxy Nexus is not 1960*720.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_Android Programming Tutorials_ Version 4.1 Available!

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en