DO NOT MERGE Add metric log for anomaly.

This cl creates metric log when anomaly surfaces in battery page or
anomaly dialog.

Each anomaly action contains two fields:
1. FIELD_CONTEXT(int): determine which fragment start this action.
2. FIELD_ANOMALY_ACTION_TYPE(int): determine action type for this
anomaly.

**Cherry-picked from ag/3120176. Fix merge conflict in import part
in AdvancedPowerUsageDetail**

Bug: 68215016
Test: RunSettingsRoboTests
Change-Id: I83761e2a9c206ea7a04f7d031a6961fdab7ca9a0
(cherry picked from commit adf11594d3510cd947e186ce4dec254223f1da10)
8 files changed