Revert "[PK settings] Remove metrics."

1. This reverts commit bdf89255a0.
2. Modify ACTION_USE_SPECIFIC_KEYBOARD to log vendor and product id.

Reason for revert: <Add metrics>
Test: atest

Change-Id: I187b990eec7dd0c0009f6c695f595d95420cb4ab
This commit is contained in:
Daniel Huang
2023-11-01 11:50:26 +00:00
committed by danielwbhuang
parent 7b6440649e
commit 6b9d8c530f
25 changed files with 347 additions and 4 deletions

View File

@@ -52,6 +52,8 @@ public class PhysicalKeyboardPreferenceControllerTest {
private static final String DEVICE_NAME = "deviceName";
private static final String LAYOUT_LABEL = "deviceLayutLabel";
private static final String BLUETOOTHADDRESS = "deviceBluetoothAddress";
private static final int VENDOR_ID = 123;
private static final int PRODUCT_ID = 456;
@Mock
private Context mContext;
@@ -84,7 +86,9 @@ public class PhysicalKeyboardPreferenceControllerTest {
DEVICE_NAME,
mIdentifier,
LAYOUT_LABEL,
BLUETOOTHADDRESS));
BLUETOOTHADDRESS,
VENDOR_ID,
PRODUCT_ID));
mController = spy(new PhysicalKeyboardPreferenceController(context, null));
when(mController.getKeyboards()).thenReturn(keyboards);