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

Unified Diff: content/renderer/render_thread_impl.h

Issue 2260433006: Add delegate and factory function for ChildMemoryCoordinator (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: export Created 4 years, 4 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
Index: content/renderer/render_thread_impl.h
diff --git a/content/renderer/render_thread_impl.h b/content/renderer/render_thread_impl.h
index 979c22e17c8b0cf42dc67e26fd14c7c3a364a594..2457b648018b8cbe9c0e67af364009ecc169c95b 100644
--- a/content/renderer/render_thread_impl.h
+++ b/content/renderer/render_thread_impl.h
@@ -22,6 +22,7 @@
#include "base/threading/thread_checker.h"
#include "base/timer/timer.h"
#include "build/build_config.h"
+#include "components/memory_coordinator/child/child_memory_coordinator_impl.h"
#include "content/child/child_thread_impl.h"
#include "content/common/content_export.h"
#include "content/common/frame.mojom.h"
@@ -81,10 +82,6 @@ namespace media {
class GpuVideoAcceleratorFactories;
}
-namespace memory_coordinator {
-class ChildMemoryCoordinatorImpl;
-}
-
namespace ui {
class GpuService;
}
@@ -153,6 +150,7 @@ class CONTENT_EXPORT RenderThreadImpl
public ChildThreadImpl,
public gpu::GpuChannelHostFactory,
public blink::scheduler::RendererScheduler::RAILModeObserver,
+ public memory_coordinator::ChildMemoryCoordinatorDelegate,
NON_EXPORTED_BASE(public CompositorDependencies) {
public:
static RenderThreadImpl* Create(const InProcessChildThreadParams& params);
@@ -454,6 +452,9 @@ class CONTENT_EXPORT RenderThreadImpl
mojom::StoragePartitionService* GetStoragePartitionService();
+ // memory_coordinator::ChildMemoryCoordinatorDelegate implementation.
+ void OnTrimMemoryImmediately() override;
+
protected:
RenderThreadImpl(
const InProcessChildThreadParams& params,
« no previous file with comments | « components/memory_coordinator/child/child_memory_coordinator_impl_unittest.cc ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698