mirror of
https://github.com/CTCaer/CTCaer-TWRP.git
synced 2025-02-05 18:46:56 +00:00
Merge "add no fb blanking Change-Id: Iaf771257d8f904807ca6f6c1a6c3d7993abadb85" into twrp2.4
This commit is contained in:
commit
4771e0130a
@ -187,6 +187,9 @@ endif
|
||||
ifeq ($(TW_HAS_DOWNLOAD_MODE), true)
|
||||
LOCAL_CFLAGS += -DTW_HAS_DOWNLOAD_MODE
|
||||
endif
|
||||
ifeq ($(TW_NO_SCREEN_BLANK), true)
|
||||
LOCAL_CFLAGS += -DTW_NO_SCREEN_BLANK
|
||||
endif
|
||||
ifeq ($(TW_SDEXT_NO_EXT4), true)
|
||||
LOCAL_CFLAGS += -DTW_SDEXT_NO_EXT4
|
||||
endif
|
||||
|
@ -51,6 +51,9 @@ endif
|
||||
ifneq ($(TW_BRIGHTNESS_PATH),)
|
||||
LOCAL_CFLAGS += -DTW_BRIGHTNESS_PATH=$(TW_BRIGHTNESS_PATH)
|
||||
endif
|
||||
ifneq ($(TW_NO_SCREEN_BLANK),)
|
||||
LOCAL_CFLAGS += -DTW_NO_SCREEN_BLANK
|
||||
endif
|
||||
|
||||
LOCAL_C_INCLUDES += bionic external/stlport/stlport $(commands_recovery_local_path)/gui/devices/$(DEVICE_RESOLUTION)
|
||||
|
||||
|
@ -95,9 +95,11 @@ int blanktimer::setClockTimer(void) {
|
||||
setBrightness(0);
|
||||
PageManager::ChangeOverlay("lock");
|
||||
}
|
||||
#ifndef TW_NO_SCREEN_BLANK
|
||||
if (conblank == 2 && gr_fb_blank(1) >= 0) {
|
||||
setConBlank(3);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
return -1; //shouldn't get here
|
||||
}
|
||||
@ -126,10 +128,12 @@ void blanktimer::resetTimerAndUnblank(void) {
|
||||
setTimer();
|
||||
switch (conblank) {
|
||||
case 3:
|
||||
#ifndef TW_NO_SCREEN_BLANK
|
||||
if (gr_fb_blank(0) < 0) {
|
||||
LOGI("blanktimer::resetTimerAndUnblank failed to gr_fb_blank(0)\n");
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
// No break here, we want to keep going
|
||||
case 2:
|
||||
gui_forceRender();
|
||||
|
Loading…
x
Reference in New Issue
Block a user