When logging ranking positions, use the number of displayed targets

in calculating offset rather than the total number available.

Test: ChooserActivityTest; log inspection
Bug: 169344682
Change-Id: I40c841bf0f3e1cf90b0e4998bde1c9e8009c09c5
(cherry picked from commit b17dbd20c3)
This commit is contained in:
Alison Cichowlas
2020-09-25 21:16:22 -04:00
parent 753f80a08a
commit 7f03b9f0cf

View File

@@ -1761,7 +1761,7 @@ public class ChooserActivity extends ResolverActivity implements
case ChooserListAdapter.TARGET_CALLER:
case ChooserListAdapter.TARGET_STANDARD:
cat = MetricsEvent.ACTION_ACTIVITY_CHOOSER_PICKED_APP_TARGET;
value -= currentListAdapter.getSelectableServiceTargetCount();
value -= currentListAdapter.getSurfacedTargetInfo().size();
numCallerProvided = currentListAdapter.getCallerTargetCount();
getChooserActivityLogger().logShareTargetSelected(
SELECTION_TYPE_APP,