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

Commit 91adbd3b authored by ykhung's avatar ykhung Committed by YK Hung
Browse files

Use en-dash in the time range instead of a hyphen for different format

Expected format: 00:00–02:00 or (2pm – 4pm)

Screenshots:
https://screenshot.googleplex.com/4RvaovK6RN7kjqo
https://screenshot.googleplex.com/ADZRr2TPuuctFre

Bug: 229264053
Test: make RunSettingsRoboTests
Change-Id: Ifd9bea0ce4525c8b582778e255104e875d365563
parent b593e00a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -508,7 +508,9 @@ public class BatteryChartPreferenceController extends AbstractPreferenceControll
            mBatteryHistoryKeys[mTrapezoidIndex * 2], mIs24HourFormat);
        final String toHour = ConvertUtils.utcToLocalTimeHour(mPrefContext,
            mBatteryHistoryKeys[(mTrapezoidIndex + 1) * 2], mIs24HourFormat);
        return String.format("%s - %s", fromHour, toHour);
        return mIs24HourFormat
            ? String.format("%s–%s", fromHour, toHour)
            : String.format("%s – %s", fromHour, toHour);
    }

    @VisibleForTesting