diff options
-rw-r--r-- | aconfig/FeatureFlags.aconfig | 10 | ||||
-rw-r--r-- | java/src/com/android/intentresolver/grid/ChooserGridAdapter.java | 9 |
2 files changed, 18 insertions, 1 deletions
diff --git a/aconfig/FeatureFlags.aconfig b/aconfig/FeatureFlags.aconfig index 0da543ac..04883baf 100644 --- a/aconfig/FeatureFlags.aconfig +++ b/aconfig/FeatureFlags.aconfig @@ -6,6 +6,16 @@ container: "system" # bug: "Feature_Bug_#" or "<none>" flag { + name: "fix_target_list_footer" + namespace: "intentresolver" + description: "Update app target grid footer on window insets change" + bug: "324011248" + metadata { + purpose: PURPOSE_BUGFIX + } +} + +flag { name: "scrollable_preview" namespace: "intentresolver" description: "Makes preview scrollable with multiple profiles" diff --git a/java/src/com/android/intentresolver/grid/ChooserGridAdapter.java b/java/src/com/android/intentresolver/grid/ChooserGridAdapter.java index 5ed3e67a..036b686b 100644 --- a/java/src/com/android/intentresolver/grid/ChooserGridAdapter.java +++ b/java/src/com/android/intentresolver/grid/ChooserGridAdapter.java @@ -162,7 +162,14 @@ public final class ChooserGridAdapter extends RecyclerView.Adapter<RecyclerView. } public void setFooterHeight(int height) { - mFooterHeight = height; + if (mFooterHeight != height) { + mFooterHeight = height; + if (mFeatureFlags.fixTargetListFooter()) { + // we always have at least one view, the footer, see getItemCount() and + // getFooterRowCount() + notifyItemChanged(getItemCount() - 1); + } + } } /** |