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

Commit d68b8048 authored by android-build-team Robot's avatar android-build-team Robot
Browse files

release-request-6c9f747d-7df5-465f-8bde-1149394b99b4-for-git_oc-mr1-release-42...

release-request-6c9f747d-7df5-465f-8bde-1149394b99b4-for-git_oc-mr1-release-4296189 snap-temp-L54400000096309002

Change-Id: Ie7b8fea1bf742fcc76dcb0eee98f3c6a4ab1702d
parents eb0d4733 f83b94aa
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -329,7 +329,11 @@ public class DashboardAdapter extends RecyclerView.Adapter<DashboardAdapter.Dash
    }

    private void logSuggestions() {
        for (Tile suggestion : mDashboardData.getSuggestions()) {
        final List<Tile> suggestions = mDashboardData.getSuggestions();
        if (suggestions == null) {
            return;
        }
        for (Tile suggestion : suggestions) {
            final String suggestionId = mSuggestionFeatureProvider.getSuggestionIdentifier(
                mContext, suggestion);
            if (!mSuggestionsShownLogged.contains(suggestionId)) {
+1 −2
Original line number Diff line number Diff line
@@ -243,8 +243,7 @@ public class BatteryInfo {
                info.remainingTimeUs = chargeTime;
                CharSequence timeString = Utils.formatElapsedTime(context,
                        BatteryUtils.convertUsToMs(chargeTime), false /* withSeconds */);
                int resId = shortString ? R.string.power_charging_duration_short
                        : R.string.power_charging_duration;
                int resId = R.string.power_charging_duration;
                info.remainingLabel = TextUtils.expandTemplate(context.getText(
                        R.string.power_remaining_charging_duration_only), timeString);
                info.chargeLabel = TextUtils.expandTemplate(context.getText(resId),
+2 −0
Original line number Diff line number Diff line
@@ -102,6 +102,8 @@ public class AnomalySummaryPreferenceController {

            mAnomalyPreference.setTitle(title);
            mAnomalyPreference.setSummary(summary);
        } else {
            mAnomalyPreference.setVisible(false);
        }
    }

+7 −0
Original line number Diff line number Diff line
@@ -137,6 +137,13 @@ public interface SearchFeatureProvider {
        return false;
    }

    /**
     * @return smart ranking timeout in milliseconds.
     */
    default long smartSearchRankingTimeoutMs(Context context) {
        return 300L;
    }

    /**
     * Prepare for search ranking predictions to avoid latency on the first prediction call.
     */
+2 −4
Original line number Diff line number Diff line
@@ -64,9 +64,6 @@ public class SearchResultsAdapter extends RecyclerView.Adapter<SearchViewHolder>
    @VisibleForTesting
    static final int MSG_RANKING_TIMED_OUT = 1;

    // TODO(b/38197948): Tune this timeout based on latency of static and async rankings. Also, we
    // should add a gservices flag to control this.
    private static final long RANKING_TIMEOUT_MS = 300;
    private final SearchFragment mFragment;
    private final Context mContext;
    private final List<SearchResult> mSearchResults;
@@ -245,8 +242,9 @@ public class SearchResultsAdapter extends RecyclerView.Adapter<SearchViewHolder>
            mAsyncRankingState = PENDING_RESULTS;
            mSearchFeatureProvider.cancelPendingSearchQuery(mContext);
            final Handler handler = getHandler();
            final long timeoutMs = mSearchFeatureProvider.smartSearchRankingTimeoutMs(mContext);
            handler.sendMessageDelayed(
                    handler.obtainMessage(MSG_RANKING_TIMED_OUT), RANKING_TIMEOUT_MS);
                    handler.obtainMessage(MSG_RANKING_TIMED_OUT), timeoutMs);
            mSearchFeatureProvider.querySearchResults(mContext, query, this);
        } else {
            mAsyncRankingState = DISABLED;
Loading