This is great stuff!  It would have saved me some coding if I knew it
before.  However, it only solves half of the issue I addressed.
Because I have custom resolutions.  So, I have the horizontal and
vertical, and I also have radio mode ( avg text size ) and radar mode
( large text size).  To accommodate all 4 options I wrote a subroutine
that I pass orientation and SharedPreference of the text size.

When dealing with different resolutions, I've had to make a completely
different layout.  Also, each layout has required it's own unique id's
of controls, all handled with a postfix on the control name.  In the
main calling routine, it gets the class wide variable of the integer
of the generic of the control.  Then the subroutine that parses out
preferences, set these control variables to the unique of the control
for that given orientation and resolution.  Thus, enabling all
controls to be unique, but handled in one body with just the classwide
integer for that control.

Thanks,

John Leone aka Radiolistener
RadiolistenersElectricEasel.com, Inc.

On Feb 16, 2:19 am, Romain Guy <romain...@google.com> wrote:
> Hi,
>
> There's no need to do this.
>
> Instead, use two files:
>
> res/layout-port/splash.xml << splash for portrait mode
> res/layout-land/splash.xml << splash for landscape mode
>
> Then in your code just call setContentView(R.layout.splash).
>
> Android will take care of the rest :)
>
>
>
> On Sun, Feb 15, 2009 at 11:15 PM, Gulfam <gulfa...@gmail.com> wrote:
>
> > Hi all,
>
> >    I have two splash screens for my android app one for horizontal
> > and second for vertical
> > and also have two xml layout file like h_splash.xml and second is
> > v_splash.
>
> > and i want to show these file like this in my code
>
> > if(horizontal or event which for horizontal )
> > {
> >  setContentView(R.layout.h_splash)
> > }
> > else
> > {
> >  setContentView(R.layout.v_splash)
> > }
>
> > issue is this how i can get horizontal and vertical event in my code?
> > On the base of that event i want to show my splash.
> >  i have used also getOrientation()or like this method in my code but
> > it give same value on both horizontal and vertical.
> > any one can help ragarding this.
>
> > Thanks and Regards,
> > Gulfam Hassan
>
> --
> Romain Guy
> Android framework engineer
> romain...@android.com
>
> Note: please don't send private questions to me, as I don't have time
> to provide private support.  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 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to