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

Side by Side Diff: content/browser/loader/sync_resource_handler.cc

Issue 2092993002: Browser process changes for Resource Timing sizes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Method renames Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/loader/sync_resource_handler.h" 5 #include "content/browser/loader/sync_resource_handler.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/browser/loader/netlog_observer.h" 8 #include "content/browser/loader/netlog_observer.h"
9 #include "content/browser/loader/resource_dispatcher_host_impl.h" 9 #include "content/browser/loader/resource_dispatcher_host_impl.h"
10 #include "content/browser/loader/resource_message_filter.h" 10 #include "content/browser/loader/resource_message_filter.h"
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 const std::string& security_info, 120 const std::string& security_info,
121 bool* defer) { 121 bool* defer) {
122 ResourceMessageFilter* filter = GetFilter(); 122 ResourceMessageFilter* filter = GetFilter();
123 if (!filter) 123 if (!filter)
124 return; 124 return;
125 125
126 result_.error_code = status.error(); 126 result_.error_code = status.error();
127 127
128 int total_transfer_size = request()->GetTotalReceivedBytes(); 128 int total_transfer_size = request()->GetTotalReceivedBytes();
129 result_.encoded_data_length = total_transfer_size_ + total_transfer_size; 129 result_.encoded_data_length = total_transfer_size_ + total_transfer_size;
130 result_.encoded_body_length = request()->GetRawBodyBytes();
130 131
131 ResourceHostMsg_SyncLoad::WriteReplyParams(result_message_, result_); 132 ResourceHostMsg_SyncLoad::WriteReplyParams(result_message_, result_);
132 filter->Send(result_message_); 133 filter->Send(result_message_);
133 result_message_ = NULL; 134 result_message_ = NULL;
134 return; 135 return;
135 } 136 }
136 137
137 void SyncResourceHandler::OnDataDownloaded(int bytes_downloaded) { 138 void SyncResourceHandler::OnDataDownloaded(int bytes_downloaded) {
138 // Sync requests don't involve ResourceMsg_DataDownloaded messages 139 // Sync requests don't involve ResourceMsg_DataDownloaded messages
139 // being sent back to renderers as progress is made. 140 // being sent back to renderers as progress is made.
140 } 141 }
141 142
142 } // namespace content 143 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/loader/async_resource_handler_unittest.cc ('k') | content/child/resource_dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698