diff options
| author | Robert Carr <racarr@google.com> | 2020-02-21 12:04:31 -0800 |
|---|---|---|
| committer | Valerie Hau <vhau@google.com> | 2020-02-24 15:56:07 +0000 |
| commit | 6d16c8c340eace35b0ea40496918edae47082f85 (patch) | |
| tree | a0fd699117cc2c862022753bd1d5addd7c8cb9dc /core/java/android/view/ViewRootImpl.java | |
| parent | 14ebab3b195446eabadc8eafe30005c5cf5bb4d8 (diff) | |
RESTRICT AUTOMERGE - Explicitly disable BLAST for SurfaceControlViewHost surfaces
Right now it crashes because the ViewRoot expects to receive a
BLAST surface but the WindowlessWindowManager doesn't support it.
Adding support should be relatively trivial (coming in a follow-up)
but we haven't tested it yet so suggesting merging this patch for
today.
Bug: 150000636
Test: Existing tests pass
Change-Id: I4b36d190c8f4f022dada656e02452034113a4000
(cherry picked from commit b4727e0f55a83dae0dff09dcdcde92d9eabc71a5)
Diffstat (limited to 'core/java/android/view/ViewRootImpl.java')
| -rw-r--r-- | core/java/android/view/ViewRootImpl.java | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java index 148b32744e30..4a093e6038b8 100644 --- a/core/java/android/view/ViewRootImpl.java +++ b/core/java/android/view/ViewRootImpl.java @@ -322,7 +322,7 @@ public final class ViewRootImpl implements ViewParent, */ private boolean mForceNextConfigUpdate; - private final boolean mUseBLASTAdapter; + private boolean mUseBLASTAdapter; /** * Signals that compatibility booleans have been initialized according to @@ -9639,4 +9639,16 @@ public final class ViewRootImpl implements ViewParent, public void onDescendantUnbufferedRequested() { mUnbufferedInputSource = mView.mUnbufferedInputSource; } + + /** + * Force disabling use of the BLAST adapter regardless of the system + * flag. Needs to be called before addView. + */ + void forceDisableBLAST() { + mUseBLASTAdapter = false; + } + + boolean useBLAST() { + return mUseBLASTAdapter; + } } |
