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

Side by Side Diff: content/browser/loader_delegate_impl.cc

Issue 2098923002: Remove dependency of ResourceDispatcherHostImpl on RenderViewHostImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . 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
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "content/browser/loader_delegate_impl.h"
6
7 #include "content/browser/renderer_host/render_view_host_impl.h"
8 #include "content/public/browser/browser_thread.h"
9
10 namespace content {
11
12 LoaderDelegateImpl::~LoaderDelegateImpl() {}
13
14 void LoaderDelegateImpl::LoadStateChanged(
15 const GlobalRoutingID& routing_id,
16 const GURL& url,
17 const net::LoadStateWithParam& load_state,
18 uint64_t upload_position,
19 uint64_t upload_size) {
20 BrowserThread::PostTask(
21 BrowserThread::UI, FROM_HERE,
22 base::Bind(&LoaderDelegateImpl::NotifyLoadStateChangedOnUI,
23 base::Unretained(this), routing_id, url, load_state,
24 upload_position, upload_size));
25 }
26
27 void LoaderDelegateImpl::NotifyLoadStateChangedOnUI(
28 const GlobalRoutingID& routing_id,
29 const GURL& url,
30 const net::LoadStateWithParam& load_state,
31 uint64_t upload_position,
32 uint64_t upload_size) {
33 RenderViewHostImpl* view =
34 RenderViewHostImpl::FromID(routing_id.child_id, routing_id.route_id);
35 if (view)
36 view->LoadStateChanged(url, load_state, upload_position, upload_size);
37 }
38
39 } // namespace content
40
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698