diff options
author | 2017-01-10 16:42:54 -0800 | |
---|---|---|
committer | 2017-02-27 10:20:10 -0800 | |
commit | 0d48072f6047140119ff194c1194ce402fca2c0b (patch) | |
tree | 3db72861fcac7b9a1622d3f7d75d54bcba2e22b3 /libs/gui/SurfaceControl.cpp | |
parent | e7f1979d8180ff9ab10422da2020e77fafe8d7d6 (diff) |
Add deferTransaction variant taking GraphicBufferProducer.
For SurfaceView using child layers, the client framework
will not have access to the Handle* for the parent surface,
but still needs a way to defer transactions to it's frames.
Test: Tested with corresponding SurfaceView modifications and existing tests.
Change-Id: I6f01c360e85a95ff0ab08db406741221152e5d5c
Diffstat (limited to 'libs/gui/SurfaceControl.cpp')
-rw-r--r-- | libs/gui/SurfaceControl.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libs/gui/SurfaceControl.cpp b/libs/gui/SurfaceControl.cpp index 0362216258..94094e5a51 100644 --- a/libs/gui/SurfaceControl.cpp +++ b/libs/gui/SurfaceControl.cpp @@ -170,6 +170,13 @@ status_t SurfaceControl::deferTransactionUntil(const sp<IBinder>& handle, return mClient->deferTransactionUntil(mHandle, handle, frameNumber); } +status_t SurfaceControl::deferTransactionUntil(const sp<Surface>& handle, + uint64_t frameNumber) { + status_t err = validate(); + if (err < 0) return err; + return mClient->deferTransactionUntil(mHandle, handle, frameNumber); +} + status_t SurfaceControl::reparentChildren(const sp<IBinder>& newParentHandle) { status_t err = validate(); if (err < 0) return err; |