Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e5762159 authored by John Reck's avatar John Reck Committed by Dan Stoza
Browse files

Add ConsumerBase::isAbandoned

Bug: 20105644
Change-Id: I21526b5397ea51a15500c44a99daa9d75fc4ea67
(cherry picked from commit e4783051)
parent 738fc3a7
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -56,6 +56,9 @@ public:
    // or by OpenGL ES as a texture) then those buffer will remain allocated.
    void abandon();

    // Returns true if the ConsumerBase is in the 'abandoned' state
    bool isAbandoned();

    // set the name of the ConsumerBase that will be used to identify it in
    // log messages.
    void setName(const String8& name);
+5 −0
Original line number Diff line number Diff line
@@ -171,6 +171,11 @@ void ConsumerBase::abandonLocked() {
    mConsumer.clear();
}

bool ConsumerBase::isAbandoned() {
    Mutex::Autolock _l(mMutex);
    return mAbandoned;
}

void ConsumerBase::setFrameAvailableListener(
        const wp<FrameAvailableListener>& listener) {
    CB_LOGV("setFrameAvailableListener");