thanks sDroid !

I tried following code ...

@Override
    public void onCreate(Bundle savedInstanceState)
    {
       // this should be before calling super.onCreate()!
        setTheme(android.R.style.Theme_NoTitleBar_Fullscreen);

        super.onCreate(savedInstanceState);
        setContentView(R.layout.splashscreen);
     }

But i have to do this in every activity right ?

Thanks
~pp

On Oct 8, 6:24 pm, sDroid <[email protected]> wrote:
> I use theme to get full view - android:theme="@android:style/
> Theme.NoTitleBar.Fullscreen".
>
> On Oct 8, 7:23 am, preetam_pict <[email protected]> wrote:
>
> > please ignore line
> >         activity.setContentView(R.layout.splashscreen);
> > from above code ... :)
>
> > On Oct 8, 5:18 pm, preetam_pict <[email protected]> wrote:
>
> > > hello all
>
> > > i want my application to run in full  screen mode ... so i have
> > > written following code in my main activity "SplashScreenActivity" ...
>
> > > public static void setWindowsProperties(Activity activity)
> > >     {
> > >         // set the window properties
> > >         activity.getWindow().requestFeature(Window.FEATURE_NO_TITLE);
> > >         activity.getWindow().setFlags(
> > >                 WindowManager.LayoutParams.FLAG_FULLSCREEN,
> > >                 WindowManager.LayoutParams.FLAG_FULLSCREEN);
> > >         activity
> > >                 
> > > .setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
> > >         activity.setContentView(R.layout.splashscreen);
> > >         // print some info
> > >         Log.d(TAG, "width -- "
> > >                 + 
> > > activity.getWindowManager().getDefaultDisplay().getWidth());
> > >         Log.d(TAG, "height -- "
> > >                 + 
> > > activity.getWindowManager().getDefaultDisplay().getHeight());
> > >         Log.d(TAG, "orientation -- " + 
> > > activity.getRequestedOrientation());
> > >     }
>
> > > Now my question is ...
> > > in each activity of my application do i need to call above util
> > > method?
>
> > > is there any way in which i just set the properties once and all the
> > > activities getting called afterwords would have full screen enabled ?
>
> > > thanks & best regards,
> > > ~pp
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" 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-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to