Adding a little more data to an exception.

Bug: 178088604
Test: Manual
Change-Id: Ia2f36c1ff12cf53c91c65913f4e1755d0d4ba1a2
This commit is contained in:
Santos Cordon
2021-02-16 17:53:11 +00:00
parent 24764efd19
commit 14d0dc0b80

View File

@@ -2404,7 +2404,7 @@ public final class SurfaceControl implements Parcelable {
if (Float.isNaN(brightness) || brightness > 1.0f
|| (brightness < 0.0f && brightness != -1.0f)) {
throw new IllegalArgumentException("brightness must be a number between 0.0f and 1.0f,"
+ " or -1 to turn the backlight off.");
+ " or -1 to turn the backlight off: " + brightness);
}
return nativeSetDisplayBrightness(displayToken, brightness);
}