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

Commit 9e3cb0c6 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Make showing percentage texts configurable on shutdown dialog" into main

parents d1693d79 301113ea
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -6901,4 +6901,8 @@
    <!-- Defines suitability of the built-in speaker route.
         Refer to {@link MediaRoute2Info} to see supported values.  -->
    <integer name="config_mediaRouter_builtInSpeakerSuitability">0</integer>

    <!-- Whether to show a percentage text next to the progressbar while preparing to update the
         device -->
    <bool name="config_showPercentageTextDuringRebootToUpdate">true</bool>
</resources>
+3 −0
Original line number Diff line number Diff line
@@ -5313,4 +5313,7 @@

  <!-- Android MediaRouter framework configs. -->
  <java-symbol type="integer" name="config_mediaRouter_builtInSpeakerSuitability" />

  <!-- Shutdown thread config flags -->
  <java-symbol type="bool" name="config_showPercentageTextDuringRebootToUpdate" />
</resources>
+6 −1
Original line number Diff line number Diff line
@@ -319,6 +319,11 @@ public final class ShutdownThread extends Thread {
                pd.setMax(100);
                pd.setProgress(0);
                pd.setIndeterminate(false);
                boolean showPercent = context.getResources().getBoolean(
                    com.android.internal.R.bool.config_showPercentageTextDuringRebootToUpdate);
                if (!showPercent) {
                    pd.setProgressPercentFormat(null);
                }
                pd.setProgressNumberFormat(null);
                pd.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
                pd.setMessage(context.getText(