Loading Android.mk +4 −1 Original line number Original line Diff line number Diff line Loading @@ -503,7 +503,10 @@ LOCAL_ADDITIONAL_DEPENDENCIES := $(framework_res_R_stamp) LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_JAVA_LIBRARIES := core-oj core-libart conscrypt okhttp core-junit bouncycastle ext LOCAL_JAVA_LIBRARIES := core-oj core-libart conscrypt okhttp core-junit bouncycastle ext LOCAL_STATIC_JAVA_LIBRARIES := framework-protos LOCAL_STATIC_JAVA_LIBRARIES := \ framework-protos \ android.hardware.thermal@1.0-java-constants \ LOCAL_MODULE := framework LOCAL_MODULE := framework Loading core/java/android/os/HardwarePropertiesManager.java +6 −4 Original line number Original line Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.os; import android.annotation.IntDef; import android.annotation.IntDef; import android.annotation.NonNull; import android.annotation.NonNull; import android.content.Context; import android.content.Context; import android.hardware.thermal.V1_0.Constants; import android.util.Log; import android.util.Log; import java.lang.annotation.Retention; import java.lang.annotation.Retention; Loading Loading @@ -56,18 +57,19 @@ public class HardwarePropertiesManager { /** /** * Device temperature types. These must match the values in * Device temperature types. These must match the values in * frameworks/native/include/hardwareproperties/HardwarePropertiesManager.h * frameworks/native/include/hardwareproperties/HardwarePropertiesManager.h * TODO(b/32022261) Remove this comment. */ */ /** Temperature of CPUs in Celsius. */ /** Temperature of CPUs in Celsius. */ public static final int DEVICE_TEMPERATURE_CPU = 0; public static final int DEVICE_TEMPERATURE_CPU = Constants.TemperatureType.CPU; /** Temperature of GPUs in Celsius. */ /** Temperature of GPUs in Celsius. */ public static final int DEVICE_TEMPERATURE_GPU = 1; public static final int DEVICE_TEMPERATURE_GPU = Constants.TemperatureType.GPU; /** Temperature of battery in Celsius. */ /** Temperature of battery in Celsius. */ public static final int DEVICE_TEMPERATURE_BATTERY = 2; public static final int DEVICE_TEMPERATURE_BATTERY = Constants.TemperatureType.BATTERY; /** Temperature of device skin in Celsius. */ /** Temperature of device skin in Celsius. */ public static final int DEVICE_TEMPERATURE_SKIN = 3; public static final int DEVICE_TEMPERATURE_SKIN = Constants.TemperatureType.SKIN; /** Get current temperature. */ /** Get current temperature. */ public static final int TEMPERATURE_CURRENT = 0; public static final int TEMPERATURE_CURRENT = 0; Loading Loading
Android.mk +4 −1 Original line number Original line Diff line number Diff line Loading @@ -503,7 +503,10 @@ LOCAL_ADDITIONAL_DEPENDENCIES := $(framework_res_R_stamp) LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_JAVA_LIBRARIES := core-oj core-libart conscrypt okhttp core-junit bouncycastle ext LOCAL_JAVA_LIBRARIES := core-oj core-libart conscrypt okhttp core-junit bouncycastle ext LOCAL_STATIC_JAVA_LIBRARIES := framework-protos LOCAL_STATIC_JAVA_LIBRARIES := \ framework-protos \ android.hardware.thermal@1.0-java-constants \ LOCAL_MODULE := framework LOCAL_MODULE := framework Loading
core/java/android/os/HardwarePropertiesManager.java +6 −4 Original line number Original line Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.os; import android.annotation.IntDef; import android.annotation.IntDef; import android.annotation.NonNull; import android.annotation.NonNull; import android.content.Context; import android.content.Context; import android.hardware.thermal.V1_0.Constants; import android.util.Log; import android.util.Log; import java.lang.annotation.Retention; import java.lang.annotation.Retention; Loading Loading @@ -56,18 +57,19 @@ public class HardwarePropertiesManager { /** /** * Device temperature types. These must match the values in * Device temperature types. These must match the values in * frameworks/native/include/hardwareproperties/HardwarePropertiesManager.h * frameworks/native/include/hardwareproperties/HardwarePropertiesManager.h * TODO(b/32022261) Remove this comment. */ */ /** Temperature of CPUs in Celsius. */ /** Temperature of CPUs in Celsius. */ public static final int DEVICE_TEMPERATURE_CPU = 0; public static final int DEVICE_TEMPERATURE_CPU = Constants.TemperatureType.CPU; /** Temperature of GPUs in Celsius. */ /** Temperature of GPUs in Celsius. */ public static final int DEVICE_TEMPERATURE_GPU = 1; public static final int DEVICE_TEMPERATURE_GPU = Constants.TemperatureType.GPU; /** Temperature of battery in Celsius. */ /** Temperature of battery in Celsius. */ public static final int DEVICE_TEMPERATURE_BATTERY = 2; public static final int DEVICE_TEMPERATURE_BATTERY = Constants.TemperatureType.BATTERY; /** Temperature of device skin in Celsius. */ /** Temperature of device skin in Celsius. */ public static final int DEVICE_TEMPERATURE_SKIN = 3; public static final int DEVICE_TEMPERATURE_SKIN = Constants.TemperatureType.SKIN; /** Get current temperature. */ /** Get current temperature. */ public static final int TEMPERATURE_CURRENT = 0; public static final int TEMPERATURE_CURRENT = 0; Loading