The virtual device sensors are handled as runtime sensors internally. They are returned from getSensorsList *iff* the current context in SensorManager is associated with a virtual device, which has a custom sensors policy.
The SystemSensorManager adds a new implementation of getSensorList in order to avoid the cache the per-device sensor lists separately.
The virtual device sensors do not trigger DynamicSensorCallbacks and are removed from the system when the virtual device is closed. The virtual device broadcasts the fact that it's being closed so the SensorManager can clean up any cached lists associated with that device.
Bug: 237278244
Test: atest cts/tests/sensor
Change-Id: I63938377f4eedca32fba14d8e15e09be1b85e460
This basically duplicates the behavior of config_perDisplayFocusEnabled
but via a display flag instead of globally for all displays. The display
must be trusted for the new flag to be set.
This is particularly needed for virtual devices and displays with
navigation-type inputs, for which touching the default display will
cause everything to enter touch mode and therefore the currently focused
view would lose focus.
Bug: 233911853
Bug: 256810557
Test: atest DisplayManagerServiceTest
Test: atest WindowManagerServiceTests
Change-Id: Ie1c3b8a42f512530bf0ce3fabc56f0da236a311c
This feature gives users of STB/OTT devices with built-in or connected speakers the possibility to use it as a proper soundbar for the audio of the TV or other connected devices, supporting the main CEC functionalities for soundbars.
Bug: 237275185
Test: make && atest com.android.server.hdmi
Change-Id: I919eb3c75a89599135d3bb6bf52f0a4488e51dcf
This is precursor to adding new APIs for PK layout selection
implementation which will be handled in KeyboardLayoutManager.
Bug: 259530132
Test: atest KeyboardLayoutChangeTest
Change-Id: I99e396816838c05f28ce57ac50680a3369221921
Change-Id: I4f8ba5350e6affa9f6b2df31262c8aadafc0da05
Introduce the API HdmiControlManager#getPortInfo.
Deprecate HdmiSwitchClient#getPortInfo.
Bug: 237067393
Test: m && atest android.hardware.hdmi.cts.HdmiControlManagerTest
Change-Id: I7a3c16f862c8ffdfd0bc69637469761728be7a8a
VirtualTouchEvent.Builder raises an exception during build() that is not
obvious why it is raised. Adding documentation with explanation.
Test: pure documentation change
Change-Id: I877fd17dd8325ff614ea056aa005740c1a25da1f
This commit is part of a large scale change to fix errorprone
errors that have been downgraded to warnings in the android
source tree, so that they can be promoted to errors again.
The full list of changes include the following, but not all
will be present in any one individual commit:
BadAnnotationImplementation
BadShiftAmount
BanJNDI
BoxedPrimitiveEquality
ComparableType
ComplexBooleanConstant
CollectionToArraySafeParameter
ConditionalExpressionNumericPromotion
DangerousLiteralNull
DoubleBraceInitialization
DurationFrom
DurationTemporalUnit
EmptyTopLevelDeclaration
EqualsNull
EqualsReference
FormatString
FromTemporalAccessor
GetClassOnAnnotation
GetClassOnClass
HashtableContains
IdentityBinaryExpression
IdentityHashMapBoxing
InstantTemporalUnit
InvalidTimeZoneID
InvalidZoneId
IsInstanceIncompatibleType
JUnitParameterMethodNotFound
LockOnBoxedPrimitive
MathRoundIntLong
MislabeledAndroidString
MisusedDayOfYear
MissingSuperCall
MisusedWeekYear
ModifyingCollectionWithItself
NoCanIgnoreReturnValueOnClasses
NonRuntimeAnnotation
NullableOnContainingClass
NullTernary
OverridesJavaxInjectableMethod
ParcelableCreator
PeriodFrom
PreconditionsInvalidPlaceholder
ProtoBuilderReturnValueIgnored
ProtoFieldNullComparison
RandomModInteger
RectIntersectReturnValueIgnored
ReturnValueIgnored
SelfAssignment
SelfComparison
SelfEquals
SizeGreaterThanOrEqualsZero
StringBuilderInitWithChar
TreeToString
TryFailThrowable
UnnecessaryCheckNotNull
UnusedCollectionModifiedInPlace
XorPower
See https://errorprone.info/bugpatterns for more
information on the checks.
Bug: 253827323
Test: m RUN_ERROR_PRONE=true javac-check
Merged-In: I19920151701b25e34a1c82af073759d50e3bcc77
Change-Id: If7d7720bd650295d0e8be234ca5221a75cde167f
Band config constructor using band descriptor was updated to
create base band config instance rather than using extended
band config class instance directly.
Bug: 220733218
Test: atest RadioManagerTest
Change-Id: I1d7481c9042e5dd77df2a0bde40cec0f22057cbe
StylusListener detects first usage of a stylus, and
updates the STYLUS_EVER_USED Settings flag.
Bug: 251206662
DD: go/stylus-first-usage-options
Test: StylusListenerTest
Change-Id: I165481d1166e31b5b8560da5c695003d105068ef
The underlying input devices are configured with a pressure range of
0-255. MotionEvent uses a normalized range of 0.0-1.0, which has caused
some confusion. This change adds documentation about the expected range.
Test: Documentation only change
Bug: 259554911
Change-Id: Iddb6cd5b5cd23bb15f75620041d7d3cbf49959db
DisplayBrightnessModeStrategies
DisplayBrightnessController is expected to handle all the changes that
happens to the brightness of the display. We have also introduced the
notion of DisplayBrightnessModeStrategies, and are making this
controller implement 2 different strategies - DozeBrightnessModeStrategy
and ScreenOffBrightnessModeStrategy. In the future, we will be
introducing more such strategies.
In future, DisplayBrightnessController will also be responsible for clamping the
brightness, and notifying the system about the changes
Test: atest ScreenOffBrightnessModeStrategyTest DisplayBrightnessControllerTest DozeBrightnessModeStrategyTest
Bug: 253226419
Change-Id: I6658ccf778274378194e158b4e9f19fb04dc1d3f