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

Side by Side Diff: content/child/memory/child_memory_coordinator_impl.cc

Issue 2321313002: Move components/memory_coordinator -> content/ (Closed)
Patch Set: rebase etc Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/memory_coordinator/child/child_memory_coordinator_impl.h" 5 #include "content/child/memory/child_memory_coordinator_impl.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/memory/memory_coordinator_client_registry.h" 8 #include "base/memory/memory_coordinator_client_registry.h"
9 #include "base/synchronization/lock.h" 9 #include "base/synchronization/lock.h"
10 10
11 namespace memory_coordinator { 11 namespace content {
12 12
13 namespace { 13 namespace {
14 14
15 base::LazyInstance<base::Lock>::Leaky g_lock = LAZY_INSTANCE_INITIALIZER; 15 base::LazyInstance<base::Lock>::Leaky g_lock = LAZY_INSTANCE_INITIALIZER;
16 ChildMemoryCoordinatorImpl* g_child_memory_coordinator = nullptr; 16 ChildMemoryCoordinatorImpl* g_child_memory_coordinator = nullptr;
17 17
18 base::MemoryState ToBaseMemoryState(mojom::MemoryState state) { 18 base::MemoryState ToBaseMemoryState(mojom::MemoryState state) {
19 switch (state) { 19 switch (state) {
20 case mojom::MemoryState::UNKNOWN: 20 case mojom::MemoryState::UNKNOWN:
21 return base::MemoryState::UNKNOWN; 21 return base::MemoryState::UNKNOWN;
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 65
66 #if !defined(OS_ANDROID) 66 #if !defined(OS_ANDROID)
67 std::unique_ptr<ChildMemoryCoordinatorImpl> CreateChildMemoryCoordinator( 67 std::unique_ptr<ChildMemoryCoordinatorImpl> CreateChildMemoryCoordinator(
68 mojom::MemoryCoordinatorHandlePtr parent, 68 mojom::MemoryCoordinatorHandlePtr parent,
69 ChildMemoryCoordinatorDelegate* delegate) { 69 ChildMemoryCoordinatorDelegate* delegate) {
70 return base::WrapUnique( 70 return base::WrapUnique(
71 new ChildMemoryCoordinatorImpl(std::move(parent), delegate)); 71 new ChildMemoryCoordinatorImpl(std::move(parent), delegate));
72 } 72 }
73 #endif 73 #endif
74 74
75 } // namespace memory_coordinator 75 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698