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

Unified Diff: content/browser/memory/memory_coordinator_impl.h

Issue 2735633002: Add MemoryCoordinatorImpl::OnChildVisibilityChanged() (Closed)
Patch Set: fix test Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/memory/memory_coordinator_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/memory/memory_coordinator_impl.h
diff --git a/content/browser/memory/memory_coordinator_impl.h b/content/browser/memory/memory_coordinator_impl.h
index 7bf66b16c0b172caace37d0f6099d1afac820cf5..4b63fb4cc38d88fafcf566aba4e8a951b7e1c36e 100644
--- a/content/browser/memory/memory_coordinator_impl.h
+++ b/content/browser/memory/memory_coordinator_impl.h
@@ -160,6 +160,7 @@ class CONTENT_EXPORT MemoryCoordinatorImpl : public base::MemoryCoordinator,
FRIEND_TEST_ALL_PREFIXES(MemoryCoordinatorWithServiceWorkerTest,
CannotSuspendRendererWithServiceWorker);
#endif
+ FRIEND_TEST_ALL_PREFIXES(MemoryCoordinatorImplTest, OnChildVisibilityChanged);
FRIEND_TEST_ALL_PREFIXES(MemoryCoordinatorImplTest, CalculateNextCondition);
FRIEND_TEST_ALL_PREFIXES(MemoryCoordinatorImplTest, UpdateCondition);
FRIEND_TEST_ALL_PREFIXES(MemoryCoordinatorImplTest, SetMemoryStateForTesting);
@@ -171,6 +172,9 @@ class CONTENT_EXPORT MemoryCoordinatorImpl : public base::MemoryCoordinator,
// Called when ChildMemoryCoordinator calls AddChild().
void OnChildAdded(int render_process_id);
+ // Called when visibility of a child process is changed.
+ void OnChildVisibilityChanged(int render_process_id, bool is_visible);
+
// Called by SetChildMemoryState() to determine a child memory state based on
// the current status of the child process.
MemoryState OverrideState(MemoryState memroy_state, const ChildInfo& child);
« no previous file with comments | « no previous file | content/browser/memory/memory_coordinator_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698