diff options
author | Andrew Dolgov <[email protected]> | 2013-11-28 22:57:58 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2013-11-28 22:57:58 +0400 |
commit | e36580667c6d6a4458ef46cc4dc6b753a39472f2 (patch) | |
tree | a8355b1bad1e7aa1cd0ceeaa596a32053f0af9da /src | |
parent | bd1801e40f31a94da4b83bd2afcdd45049c10dac (diff) |
properly restore system ui visibility flags if not fullscreen
Diffstat (limited to 'src')
-rw-r--r-- | src/org/fox/ttcomics/CommonActivity.java | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/org/fox/ttcomics/CommonActivity.java b/src/org/fox/ttcomics/CommonActivity.java index 6267ee2..92ceba2 100644 --- a/src/org/fox/ttcomics/CommonActivity.java +++ b/src/org/fox/ttcomics/CommonActivity.java @@ -557,10 +557,15 @@ public class CommonActivity extends SherlockFragmentActivity { public void showSystemUiIfNecessary() {
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.KITKAT) {
- getWindow().getDecorView().setSystemUiVisibility(
- View.SYSTEM_UI_FLAG_LAYOUT_STABLE
- | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
- | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN);
+ if (m_prefs.getBoolean("use_full_screen", false)) {
+ getWindow().getDecorView().setSystemUiVisibility(
+ View.SYSTEM_UI_FLAG_LAYOUT_STABLE
+ | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
+ | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN);
+ } else {
+ getWindow().getDecorView().setSystemUiVisibility(
+ View.SYSTEM_UI_FLAG_VISIBLE);
+ }
}
}
|