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

Side by Side Diff: content/browser/loader/render_view_host_tracker.h

Issue 12600018: ResourceScheduler should use renderer notifications instead of MRUCache to track renderers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rename to RenderViewHostTracker Created 7 years, 9 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 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 #ifndef CONTENT_BROWSER_LOADER_RENDER_VIEW_HOST_TRACKER_H_
6 #define CONTENT_BROWSER_LOADER_RENDER_VIEW_HOST_TRACKER_H_
7
8 #include "content/public/browser/notification_observer.h"
9 #include "content/public/browser/notification_registrar.h"
10
11 namespace content {
12
13 // The ResourceDispatcherHost needs to know when renderers are created and
14 // destroyed. That happens on the UI thread, but the ResourceDispatcherHost
15 // operates on the IO thread. RenderViewHostTracker listens for renderer
16 // notifications on the UI thread, then bounces them over to the IO thread so
17 // the ResourceDispatcherHost can be notified.
18 class CONTENT_EXPORT RenderViewHostTracker : public NotificationObserver {
19 public:
20 RenderViewHostTracker();
21 virtual ~RenderViewHostTracker();
22
23 private:
24 // NotificationObserver interface:
25 virtual void Observe(int type,
26 const NotificationSource& source,
27 const NotificationDetails& details) OVERRIDE;
28
29 content::NotificationRegistrar registrar_;
30 };
31
32 } // namespace content
33
34 #endif // CONTENT_BROWSER_LOADER_RENDER_VIEW_HOST_TRACKER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698