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

Unified Diff: content/browser/renderer_host/render_widget_host_impl.h

Issue 17351006: MemoryPressure: sends the signal to the renderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | « no previous file | content/browser/renderer_host/render_widget_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_widget_host_impl.h
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
index b79eea67dd779e9641380b20c820218ef6f0c66d..975cded0c08b9bdc1fa912b50d6bd77f3e447b26 100644
--- a/content/browser/renderer_host/render_widget_host_impl.h
+++ b/content/browser/renderer_host/render_widget_host_impl.h
@@ -15,6 +15,7 @@
#include "base/callback.h"
#include "base/gtest_prod_util.h"
+#include "base/memory/memory_pressure_listener.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
@@ -716,6 +717,9 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
// which may get in recursive loops).
void DelayedAutoResized();
+ // Sends a memory pressure signal to the renderer.
+ void SendMemoryPressureSignal(
+ base::MemoryPressureListener::MemoryPressureLevel level);
joth 2013/06/21 21:52:13 I think you want to do this at the RenderProcess,
// Our delegate, which wants to know mainly about keyboard events.
// It will remain non-NULL until DetachDelegate() is called.
@@ -936,6 +940,8 @@ class CONTENT_EXPORT RenderWidgetHostImpl : virtual public RenderWidgetHost,
BrowserRenderingStats rendering_stats_;
+ base::MemoryPressureListener memory_pressure_listener_;
+
DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);
};
« no previous file with comments | « no previous file | content/browser/renderer_host/render_widget_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698