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

Unified Diff: content/browser/browser_thread_impl.cc

Issue 815183002: Using the new MemoryPressureListener instead of the LowMemoryObserver when the enhanced memory mana… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed Created 6 years 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/browser/browser_thread_impl.cc
diff --git a/content/browser/browser_thread_impl.cc b/content/browser/browser_thread_impl.cc
index a8ce1b0dcd510dea55cc7a95829e83bd116bd345..8e796758c10c3f91dd6e5739ecd6972ca9376992 100644
--- a/content/browser/browser_thread_impl.cc
+++ b/content/browser/browser_thread_impl.cc
@@ -14,6 +14,7 @@
#include "base/message_loop/message_loop_proxy.h"
#include "base/threading/sequenced_worker_pool.h"
#include "base/threading/thread_restrictions.h"
+#include "content/browser/browser_main_loop.h"
#include "content/public/browser/browser_thread_delegate.h"
#include "net/disk_cache/simple/simple_backend_impl.h"
@@ -480,6 +481,14 @@ bool BrowserThread::PostTaskAndReply(
reply);
}
+#if defined(OS_CHROMEOS)
+// static
+base::MemoryPressureObserverChromeOS*
+BrowserThread::GetMemoryPressureObserver() {
+ return BrowserMainLoop::GetInstance()->memory_pressure_observer();
+}
+#endif
+
// static
bool BrowserThread::GetCurrentThreadIdentifier(ID* identifier) {
if (g_globals == NULL)

Powered by Google App Engine
This is Rietveld 408576698