Some fixes to TrustedPresentationListener

1. Ignore display overlays since we don't want screen decorations
   included in the occlusion

2. Handle occluded region as separate Rects to ensure that disconnected
   Rects in a Region are not considered occluding in the disconnected
   area.

Test: LayerTrustedPresentationListenerTest
Bug: 256993331
Change-Id: Ib0a4b850e2aafb42e206b8728fcc9b6013171f3f
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index 68ab776..39b942c 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -2511,6 +2511,7 @@
     refreshArgs.previousPresentFence = mPreviousPresentFences[0].fenceTime;
     refreshArgs.scheduledFrameTime = mScheduler->getScheduledFrameTime();
     refreshArgs.expectedPresentTime = mExpectedPresentTime.ns();
+    refreshArgs.hasTrustedPresentationListener = mNumTrustedPresentationListeners > 0;
 
     // Store the present time just before calling to the composition engine so we could notify
     // the scheduler.