Use Layer IDs instead of handles in BufferCountTracker

Allows more versatility in looking up buffer counts by
layer ID. Layer handles will not always be available for
lookup.

Test: presubmit
Bug: b/294922229
Flag: EXEMPT pure refactoring
Change-Id: Ifba8b19f24f3f3cf35d247490a17fe3b8c4920e0
4 files changed