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

Unified Diff: chrome/browser/browser_process_platform_part_android.cc

Issue 15995014: Adds MemoryPressureListener. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Joth's comments 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
Index: chrome/browser/browser_process_platform_part_android.cc
diff --git a/chrome/browser/browser_process_platform_part_android.cc b/chrome/browser/browser_process_platform_part_android.cc
index 4fdede00141b526c8ec98d4e86f69017749ed30f..ebc32c669a184d28beb9eff104e53f09a7c2ef40 100644
--- a/chrome/browser/browser_process_platform_part_android.cc
+++ b/chrome/browser/browser_process_platform_part_android.cc
@@ -2,10 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "chrome/browser/browser_process_platform_part_mac.h"
+#include "chrome/browser/browser_process_platform_part_android.h"
+
+#include "base/android/memory_pressure_handler_android.h"
#include "chrome/browser/lifetime/application_lifetime_android.h"
+#include "chrome/browser/memory_purger.h"
BrowserProcessPlatformPart::BrowserProcessPlatformPart() {
+ base::android::MemoryPressureHandlerAndroid::RegisterSystemCallback(
+ base::android::AttachCurrentThread());
+ MemoryPurger::RegisterMemoryPressureListener();
}
BrowserProcessPlatformPart::~BrowserProcessPlatformPart() {

Powered by Google App Engine
This is Rietveld 408576698