How To Make My App Full Screen On Galaxy Tab
Solution 1:
If you set your target sdk level to anything less than 9, then support for extra-large screens is assumed to be false. If you set targetSdkVersion=9 in the manifest, then xlarge support is assumed to be true. See the documentation on Supporting Multiple Screens, in particular the description of compatibility mode.
Solution 2:
another way to do is creating a xml called styles.xml in res/values
define a style:
<style name="Theme.FullScreen" parent="android:Theme">
<item name="android:windowFullscreen">true</item>
<item name="android:windowNoTitle">true</item>
</style>
later in the manifest, tell android what activity must be in fullscreen setting the style above:
<activity android:name=".activity.NewSearchBrowserActivity" android:theme="@style/Theme.FullScreen" android:screenOrientation="landscape"></activity>
in this way you make a reusable theme what can be applied to any activity.
Solution 3:
Ted mentioned XLargeSceens, the Galaxy Tab is running 2.2 and therefore doesn't have the xlargeScreens attribute as it was added in 2.3; Because the upcoming generation of tablets will have 3.0 and XlargeScreens you are going to want to use it anyway (and compile against 2.3/3.0)
In your Manifest you need to declare support for all reasonable screen sizes and provide the correct set of resources
<supports-screens
android:smallScreens="false"
android:largeScreens="true"
android:xlargeScreens="true"
android:normalScreens="true"
android:anyDensity="true"
/>
Solution 4:
Unless you support SDK versions that are at least 4, i.e.:
<uses-sdk android:minSdkVersion="4"/>
,
you will have to do the following explicitly:
<supports-screens android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:anyDensity="true" />
Solution 5:
public void onCreate(Bundle savedInstanceState) {
requestWindowFeature(Window.FEATURE_NO_TITLE);
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
This is working fine for me... try this
Post a Comment for "How To Make My App Full Screen On Galaxy Tab"