diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/gui/BufferQueueCore.h | 6 | ||||
| -rw-r--r-- | include/gui/IProducerListener.h | 3 |
2 files changed, 8 insertions, 1 deletions
diff --git a/include/gui/BufferQueueCore.h b/include/gui/BufferQueueCore.h index 15b7dbefa1..b1c730a587 100644 --- a/include/gui/BufferQueueCore.h +++ b/include/gui/BufferQueueCore.h @@ -185,8 +185,12 @@ private: // PID of the process which last successfully called connect(...) pid_t mConnectedPid; - // mConnectedProducerToken is used to set a binder death notification on + // mLinkedToDeath is used to set a binder death notification on // the producer. + sp<IProducerListener> mLinkedToDeath; + + // mConnectedProducerListener is used to handle the onBufferReleased + // notification. sp<IProducerListener> mConnectedProducerListener; // mSlots is an array of buffer slots that must be mirrored on the producer diff --git a/include/gui/IProducerListener.h b/include/gui/IProducerListener.h index 4a5ed46891..e808bd3bc3 100644 --- a/include/gui/IProducerListener.h +++ b/include/gui/IProducerListener.h @@ -41,6 +41,7 @@ public: // This is called without any lock held and can be called concurrently by // multiple threads. virtual void onBufferReleased() = 0; // Asynchronous + virtual bool needsReleaseNotify() = 0; }; class IProducerListener : public ProducerListener, public IInterface @@ -54,6 +55,7 @@ class BnProducerListener : public BnInterface<IProducerListener> public: virtual status_t onTransact(uint32_t code, const Parcel& data, Parcel* reply, uint32_t flags = 0); + virtual bool needsReleaseNotify(); }; class DummyProducerListener : public BnProducerListener @@ -61,6 +63,7 @@ class DummyProducerListener : public BnProducerListener public: virtual ~DummyProducerListener(); virtual void onBufferReleased() {} + virtual bool needsReleaseNotify() { return false; } }; } // namespace android |