Refactor of screenshot code on main thread.

Create helper functions to improve readability of what is scheduled on
the SurfaceFlinger main thread. This will allow for cleaner changes in
reducing the calls on the main thread for screenshots. Changes include
some renaming for better clarity.

Bug: b/294936197
Test: presubmit
Test: atest SurfaceFlinger_test
Change-Id: I729b62b3fc1919b5b048b7992b4aead336e87d7f
diff --git a/services/surfaceflinger/RegionSamplingThread.cpp b/services/surfaceflinger/RegionSamplingThread.cpp
index c888ccc..77e045d 100644
--- a/services/surfaceflinger/RegionSamplingThread.cpp
+++ b/services/surfaceflinger/RegionSamplingThread.cpp
@@ -377,8 +377,8 @@
     constexpr bool kIsProtected = false;
 
     if (const auto fenceResult =
-                mFlinger.captureScreenCommon(std::move(renderAreaFuture), getLayerSnapshots, buffer,
-                                             kRegionSampling, kGrayscale, kIsProtected, nullptr)
+                mFlinger.captureScreenshot(std::move(renderAreaFuture), getLayerSnapshots, buffer,
+                                           kRegionSampling, kGrayscale, kIsProtected, nullptr)
                         .get();
         fenceResult.ok()) {
         fenceResult.value()->waitForever(LOG_TAG);