forked from organicmaps/organicmaps
[android] Use full-screen mode only on Kindle Fire
This commit is contained in:
parent
db74ea08f6
commit
b3d9e4cb03
3 changed files with 9 additions and 2 deletions
|
@ -26,7 +26,7 @@
|
|||
android:label="@string/app_name"
|
||||
android:screenOrientation="behind"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:theme="@style/MWMFullScreen">
|
||||
android:theme="@style/MWMNoTitle">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<style name="MWMFullScreen" parent="@android:style/Theme.NoTitleBar.Fullscreen">
|
||||
<style name="MWMNoTitle" parent="@android:style/Theme.NoTitleBar">
|
||||
<item name="android:windowBackground">@color/background_gray</item>
|
||||
</style>
|
||||
</resources>
|
|
@ -149,6 +149,13 @@ public class MWMActivity extends NvEventQueueActivity implements
|
|||
@Override
|
||||
public void onCreate(Bundle savedInstanceState)
|
||||
{
|
||||
// Use full-screen on Kindle Fire only
|
||||
if (android.os.Build.MODEL.equals("Kindle Fire"))
|
||||
{
|
||||
getWindow().addFlags(android.view.WindowManager.LayoutParams.FLAG_FULLSCREEN);
|
||||
getWindow().clearFlags(android.view.WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
|
||||
}
|
||||
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
m_context = this;
|
||||
|
|
Loading…
Add table
Reference in a new issue