diff --git a/core/java/com/android/internal/app/ChooserActivity.java b/core/java/com/android/internal/app/ChooserActivity.java index 5294714c05aec..f9d27bb46592b 100644 --- a/core/java/com/android/internal/app/ChooserActivity.java +++ b/core/java/com/android/internal/app/ChooserActivity.java @@ -2327,10 +2327,12 @@ public class ChooserActivity extends ResolverActivity { private static final int MAX_SUGGESTED_APP_TARGETS = 4; private static final int MAX_CHOOSER_TARGETS_PER_APP = 2; - private static final int MAX_SHORTCUT_TARGETS_PER_APP = 8; private static final int MAX_SERVICE_TARGETS = 8; + private final int mMaxShortcutTargetsPerApp = + getResources().getInteger(R.integer.config_maxShortcutTargetsPerApp); + private int mNumShortcutResults = 0; // Reserve spots for incoming direct share targets by adding placeholders @@ -2648,7 +2650,7 @@ public class ChooserActivity extends ResolverActivity { final float baseScore = getBaseScore(origTarget, isShortcutResult); Collections.sort(targets, mBaseTargetComparator); - final int maxTargets = isShortcutResult ? MAX_SHORTCUT_TARGETS_PER_APP + final int maxTargets = isShortcutResult ? mMaxShortcutTargetsPerApp : MAX_CHOOSER_TARGETS_PER_APP; float lastScore = 0; boolean shouldNotify = false; diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml index a2bae3f0537e1..9a642add609e1 100644 --- a/core/res/res/values/config.xml +++ b/core/res/res/values/config.xml @@ -4159,4 +4159,6 @@ one bar higher than they actually are --> false + + 3 diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml index a8a70fe6a83c8..bafbffd26ca46 100644 --- a/core/res/res/values/symbols.xml +++ b/core/res/res/values/symbols.xml @@ -2817,6 +2817,7 @@ +