void SurfaceComposerClient::Transaction::clear() {
mComposerStates.clear();
mDisplayStates.clear();
mListenerCallbacks.clear();
mInputWindowCommands.clear();
mContainsBuffer = false;
mForceSynchronous = 0;
mTransactionNestCount = 0;
mAnimation = false;
mEarlyWakeupStart = false;
mEarlyWakeupEnd = false;
mDesiredPresentTime = 0;
mIsAutoTimestamp = true;
mFrameTimelineInfo.clear();
mApplyToken = nullptr;
}
清除 mListenerCallbacks
。这里会递减对 SurfaceControl 的强引用计数,它对应在 Transaction::registerSurfaceControlForCallback() 中递增的强引用计数。