| Index: chrome/browser/download/download_util.cc
|
| diff --git a/chrome/browser/download/download_util.cc b/chrome/browser/download/download_util.cc
|
| index c7a261f786158fdbddfdacc02147a1a6a9c62691..2c856be3ceb79dff58248555bc8f11413eadf8a7 100644
|
| --- a/chrome/browser/download/download_util.cc
|
| +++ b/chrome/browser/download/download_util.cc
|
| @@ -544,21 +544,15 @@ std::wstring GetProgressStatusText(DownloadItem* download) {
|
|
|
| // Adjust both strings for the locale direction since we don't yet know which
|
| // string we'll end up using for constructing the final progress string.
|
| - std::wstring amount_localized;
|
| - if (base::i18n::AdjustStringForLocaleDirection(amount, &amount_localized)) {
|
| - amount.assign(amount_localized);
|
| - received_size.assign(amount_localized);
|
| - }
|
| + base::i18n::AdjustStringForLocaleDirection(&amount);
|
|
|
| if (total) {
|
| amount_units = GetByteDisplayUnits(total);
|
| std::wstring total_text =
|
| UTF16ToWideHack(FormatBytes(total, amount_units, true));
|
| - std::wstring total_text_localized;
|
| - if (base::i18n::AdjustStringForLocaleDirection(total_text,
|
| - &total_text_localized))
|
| - total_text.assign(total_text_localized);
|
| + base::i18n::AdjustStringForLocaleDirection(&total_text);
|
|
|
| + base::i18n::AdjustStringForLocaleDirection(&received_size);
|
| amount = l10n_util::GetStringF(IDS_DOWNLOAD_TAB_PROGRESS_SIZE,
|
| received_size,
|
| total_text);
|
| @@ -569,10 +563,7 @@ std::wstring GetProgressStatusText(DownloadItem* download) {
|
| amount_units = GetByteDisplayUnits(current_speed);
|
| std::wstring speed_text = UTF16ToWideHack(FormatSpeed(current_speed,
|
| amount_units, true));
|
| - std::wstring speed_text_localized;
|
| - if (base::i18n::AdjustStringForLocaleDirection(speed_text,
|
| - &speed_text_localized))
|
| - speed_text.assign(speed_text_localized);
|
| + base::i18n::AdjustStringForLocaleDirection(&speed_text);
|
|
|
| base::TimeDelta remaining;
|
| string16 time_remaining;
|
| @@ -582,6 +573,7 @@ std::wstring GetProgressStatusText(DownloadItem* download) {
|
| time_remaining = TimeFormat::TimeRemaining(remaining);
|
|
|
| if (time_remaining.empty()) {
|
| + base::i18n::AdjustStringForLocaleDirection(&amount);
|
| return l10n_util::GetStringF(IDS_DOWNLOAD_TAB_PROGRESS_STATUS_TIME_UNKNOWN,
|
| speed_text, amount);
|
| }
|
|
|