Add TYPE_MAGNIFICATION_OVERLAY to isTrustedOverlay
This fixes a bug where a View with filterTouchesWhenObscured will have all touches filtered when in magnification accessibility mode. This is due to magnification being a separate Window over top of the running Activity. The method onFilterTouchEventForSecurity in View will then always return false when filterTouchesWhenObscured is enabled on the View. By adding the magnification Window to the list of Trusted Overlays we can ensure that touches will work properly with this property enabled. This corresponds to AOSP change I07706588a625682d05da5cb19f401139eb08a54c Change-Id: Iba095433a1f9045349d1b47a58a33b850ed31c97
This commit is contained in:
parent
e4d9761196
commit
51eb29fa9a
@ -43,6 +43,7 @@ bool InputWindowInfo::frameContainsPoint(int32_t x, int32_t y) const {
|
||||
bool InputWindowInfo::isTrustedOverlay() const {
|
||||
return layoutParamsType == TYPE_INPUT_METHOD
|
||||
|| layoutParamsType == TYPE_INPUT_METHOD_DIALOG
|
||||
|| layoutParamsType == TYPE_MAGNIFICATION_OVERLAY
|
||||
|| layoutParamsType == TYPE_SECURE_SYSTEM_OVERLAY;
|
||||
}
|
||||
|
||||
|
@ -106,6 +106,7 @@ struct InputWindowInfo {
|
||||
TYPE_NAVIGATION_BAR = FIRST_SYSTEM_WINDOW+19,
|
||||
TYPE_VOLUME_OVERLAY = FIRST_SYSTEM_WINDOW+20,
|
||||
TYPE_BOOT_PROGRESS = FIRST_SYSTEM_WINDOW+21,
|
||||
TYPE_MAGNIFICATION_OVERLAY = FIRST_SYSTEM_WINDOW+22,
|
||||
LAST_SYSTEM_WINDOW = 2999,
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user