Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7240997b authored by Lei Yu's avatar Lei Yu Committed by Android (Google) Code Review
Browse files

Merge "update summary change no matter whether summary is equal"

parents d732cc9d f6979e25
Loading
Loading
Loading
Loading
+3 −7
Original line number Diff line number Diff line
@@ -163,15 +163,11 @@ public class DashboardAdapter extends RecyclerView.Adapter<DashboardAdapter.Dash
    public void notifySummaryChanged(Tile tile) {
        final int position = mDashboardData.getPositionByTile(tile);
        if (position != DashboardData.POSITION_NOT_FOUND) {
            final Tile targetTile = (Tile) mDashboardData.getItemEntityByPosition(position);
            if (!TextUtils.equals(tile.summary, targetTile.summary)) {

            // Since usually tile in parameter and tile in mCategories are same instance,
            // which is hard to be detected by DiffUtil, so we notifyItemChanged directly.
            notifyItemChanged(position);
        }
    }
    }

    // TODO: move this method to SuggestionParser or some other util class
    public void disableSuggestion(Tile suggestion) {