OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 package com.skia; | 8 package com.skia; |
9 | 9 |
10 import android.app.Activity; | 10 import android.app.Activity; |
(...skipping 29 matching lines...) Expand all Loading... |
40 // Disable backlight to keep the system as cool as possible | 40 // Disable backlight to keep the system as cool as possible |
41 // TODO make this configurable | 41 // TODO make this configurable |
42 Settings.System.putInt(getContentResolver(), Settings.System.SCREEN_BRIG
HTNESS_MODE, | 42 Settings.System.putInt(getContentResolver(), Settings.System.SCREEN_BRIG
HTNESS_MODE, |
43 Settings.System.SCREEN_BRIG
HTNESS_MODE_MANUAL); | 43 Settings.System.SCREEN_BRIG
HTNESS_MODE_MANUAL); |
44 | 44 |
45 WindowManager.LayoutParams lp = getWindow().getAttributes(); | 45 WindowManager.LayoutParams lp = getWindow().getAttributes(); |
46 lp.screenBrightness = 0; // 0f - no backlight | 46 lp.screenBrightness = 0; // 0f - no backlight |
47 getWindow().setAttributes(lp); | 47 getWindow().setAttributes(lp); |
48 } | 48 } |
49 } | 49 } |
OLD | NEW |