Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(901)

Unified Diff: chrome/renderer/net/net_error_helper.cc

Issue 13811022: New network error page: Fix resubmit warning page (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: sync prior to commit Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/net/net_error_helper.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/net/net_error_helper.cc
===================================================================
--- chrome/renderer/net/net_error_helper.cc (revision 194509)
+++ chrome/renderer/net/net_error_helper.cc (working copy)
@@ -101,7 +101,8 @@
&NetErrorHelper::TrackerCallback,
base::Unretained(this)))),
dns_error_page_state_(NetErrorTracker::DNS_ERROR_PAGE_NONE),
- updated_error_page_(false) {
+ updated_error_page_(false),
+ is_failed_post_(false) {
}
NetErrorHelper::~NetErrorHelper() {
@@ -113,6 +114,9 @@
void NetErrorHelper::DidFailProvisionalLoad(WebKit::WebFrame* frame,
const WebKit::WebURLError& error) {
+ WebKit::WebDataSource* data_source = frame->provisionalDataSource();
+ const WebKit::WebURLRequest& failed_request = data_source->request();
+ is_failed_post_ = EqualsASCII(failed_request.httpMethod(), "POST");
tracker_.OnFailProvisionalLoad(GetFrameType(frame), GetErrorType(error));
}
@@ -180,8 +184,9 @@
DictionaryValue error_strings;
LocalizedError::GetStrings(NetErrorToWebURLError(net_error),
- &error_strings,
- RenderThread::Get()->GetLocale());
+ is_failed_post_,
+ RenderThread::Get()->GetLocale(),
+ &error_strings);
// TODO(ttuttle): Update error page with error_strings.
}
« no previous file with comments | « chrome/renderer/net/net_error_helper.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698