Chromium Code Reviews| Index: components/error_page/common/localized_error.cc |
| diff --git a/components/error_page/common/localized_error.cc b/components/error_page/common/localized_error.cc |
| index e81da543c56cd9d521ccd1351040bc123992575d..3b1f50bebe15a5262e376d7ba8fc718953cc3b0f 100644 |
| --- a/components/error_page/common/localized_error.cc |
| +++ b/components/error_page/common/localized_error.cc |
| @@ -970,7 +970,9 @@ void LocalizedError::GetStrings( |
| // Add the reload suggestion, if needed for pages that didn't come |
| // from a post. |
| + bool reload_visible = false; |
| if (params->suggest_reload && !is_post) { |
| + reload_visible = true; |
| base::DictionaryValue* reload_button = new base::DictionaryValue; |
| reload_button->SetString( |
| "msg", l10n_util::GetStringUTF16(IDS_ERRORPAGES_BUTTON_RELOAD)); |
| @@ -1023,8 +1025,8 @@ void LocalizedError::GetStrings( |
| } |
| #if defined(OS_ANDROID) |
| - if (!show_saved_copy_visible && !is_incognito && |
| - failed_url.SchemeIsHTTPOrHTTPS() && |
| + if (!reload_visible && !show_saved_copy_visible && !is_incognito && |
| + failed_url.is_valid() && failed_url.SchemeIsHTTPOrHTTPS() && |
|
fgorski
2016/12/09 18:09:32
is it possible to use OfflinePageModel::CanSaveURL
|
| offline_pages::IsOfflinePagesAsyncDownloadEnabled()) { |
| std::unique_ptr<base::DictionaryValue> download_button = |
| base::MakeUnique<base::DictionaryValue>(); |