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

Unified Diff: content/public/renderer/document_state.cc

Issue 8404018: chrome.loadTimes() shouldn't be affected by in-document navigation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync and merge Created 9 years, 1 month 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 | « content/public/renderer/document_state.h ('k') | content/public/renderer/navigation_state.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/renderer/document_state.cc
diff --git a/content/public/renderer/navigation_state.cc b/content/public/renderer/document_state.cc
similarity index 50%
copy from content/public/renderer/navigation_state.cc
copy to content/public/renderer/document_state.cc
index c461835037208386d51d0372b46706d72f04a77d..a4c22b5969527de22c3e55c85dd85e025de2884f 100644
--- a/content/public/renderer/navigation_state.cc
+++ b/content/public/renderer/document_state.cc
@@ -2,50 +2,43 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/public/renderer/navigation_state.h"
+#include "content/public/renderer/document_state.h"
+#include "content/public/renderer/navigation_state.h"
#include "webkit/glue/alt_error_page_resource_fetcher.h"
#include "webkit/glue/password_form.h"
namespace content {
-NavigationState::~NavigationState() {}
+DocumentState::DocumentState()
+ : load_histograms_recorded_(false),
+ web_timing_histograms_recorded_(false),
+ http_status_code_(0),
+ was_fetched_via_spdy_(false),
+ was_npn_negotiated_(false),
+ was_alternate_protocol_available_(false),
+ was_fetched_via_proxy_(false),
+ use_error_page_(false),
+ was_prefetcher_(false),
+ was_referred_by_prefetcher_(false),
+ load_type_(UNDEFINED_LOAD),
+ cache_policy_override_set_(false),
+ cache_policy_override_(WebKit::WebURLRequest::UseProtocolCachePolicy) {
+}
+
+DocumentState::~DocumentState() {}
-void NavigationState::set_password_form_data(webkit_glue::PasswordForm* data) {
+void DocumentState::set_password_form_data(webkit_glue::PasswordForm* data) {
password_form_data_.reset(data);
}
-void NavigationState::set_alt_error_page_fetcher(
+void DocumentState::set_alt_error_page_fetcher(
webkit_glue::AltErrorPageResourceFetcher* f) {
alt_error_page_fetcher_.reset(f);
}
-NavigationState::NavigationState(content::PageTransition transition_type,
- const base::Time& request_time,
- bool is_content_initiated,
- int32 pending_page_id,
- int pending_history_list_offset)
- : transition_type_(transition_type),
- load_type_(UNDEFINED_LOAD),
- request_time_(request_time),
- load_histograms_recorded_(false),
- web_timing_histograms_recorded_(false),
- request_committed_(false),
- is_content_initiated_(is_content_initiated),
- pending_page_id_(pending_page_id),
- pending_history_list_offset_(pending_history_list_offset),
- use_error_page_(false),
- cache_policy_override_set_(false),
- cache_policy_override_(WebKit::WebURLRequest::UseProtocolCachePolicy),
- http_status_code_(0),
- was_fetched_via_spdy_(false),
- was_npn_negotiated_(false),
- was_alternate_protocol_available_(false),
- was_fetched_via_proxy_(false),
- was_translated_(false),
- was_within_same_page_(false),
- was_prefetcher_(false),
- was_referred_by_prefetcher_(false) {
+void DocumentState::set_navigation_state(NavigationState* navigation_state) {
+ navigation_state_.reset(navigation_state);
}
} // namespace content
« no previous file with comments | « content/public/renderer/document_state.h ('k') | content/public/renderer/navigation_state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698