[SurfaceFlinger] Avoid comparing to identity matrix.

hasColorTransform is called every time on every layer that needs to be client
composited. This patch adds a boolean for that check and move that check to
when color transform matrix is set.

BUG: 111562338
Test: Build, flash and boot.
Change-Id: Icbd17458dc194f10f744ee7cc72c3462ae239a28
2 files changed