Remove legacy layer path in screenshot pathway

Legacy path to get layer snapshots is no longer used
and the flag can be removed to clean up the code.
Also renames layer snapshot function variable for better
clarity that the function is not immediately called wherever
declared.

Bug: b/330785038
Test: presubmit
Test: atest SurfaceFlinger_test
Change-Id: I12498f2560de07d69fff93eda901f6b7c072fce6
4 files changed