[Android] Avoid Lint error about DimStatusBar for api >= 11
Jean-Baptiste Kempf
git at videolan.org
Mon Jun 18 17:05:23 CEST 2012
android | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Mon Jun 18 19:04:36 2012 +0200| [e48d3c540fe530406ac2e2e7d7f440f3588cba95] | committer: Jean-Baptiste Kempf
Avoid Lint error about DimStatusBar for api >= 11
> http://git.videolan.org/gitweb.cgi/android.git/?a=commit;h=e48d3c540fe530406ac2e2e7d7f440f3588cba95
---
.../src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
index d214abb..a591f43 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -35,6 +35,7 @@ import org.videolan.vlc.interfaces.OnPlayerControlListener;
import org.videolan.vlc.widget.PlayerControlClassic;
import org.videolan.vlc.widget.PlayerControlWheel;
+import android.annotation.TargetApi;
import android.app.Activity;
import android.app.AlertDialog;
import android.app.AlertDialog.Builder;
@@ -768,7 +769,8 @@ public class VideoPlayerActivity extends Activity {
* Dim the status bar and/or navigation icons when needed.
* Android 3.0 and later
*/
- private void dimStatusBar(boolean dim) {
+ @TargetApi(11)
+ private void dimStatusBar(boolean dim) {
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.HONEYCOMB) {
if (dim) {
mSurface.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LOW_PROFILE);
More information about the Android
mailing list