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

Unified Diff: content/child/web_memory_dump_provider_adapter.cc

Issue 1660383002: Refactoring: Move some classes from content/child to platform (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add PLATFORM_EXPORT; Address haraken's review Created 4 years, 10 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 | « content/child/web_memory_dump_provider_adapter.h ('k') | content/child/web_process_memory_dump_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/child/web_memory_dump_provider_adapter.cc
diff --git a/content/child/web_memory_dump_provider_adapter.cc b/content/child/web_memory_dump_provider_adapter.cc
deleted file mode 100644
index 051f155fd98162695d6bbd7890139f435f47d5d2..0000000000000000000000000000000000000000
--- a/content/child/web_memory_dump_provider_adapter.cc
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/child/web_memory_dump_provider_adapter.h"
-
-#include <stddef.h>
-
-#include "base/trace_event/trace_event_argument.h"
-#include "content/child/web_process_memory_dump_impl.h"
-#include "third_party/WebKit/public/platform/WebMemoryDumpProvider.h"
-
-namespace content {
-
-WebMemoryDumpProviderAdapter::WebMemoryDumpProviderAdapter(
- blink::WebMemoryDumpProvider* wmdp)
- : web_memory_dump_provider_(wmdp), is_registered_(false) {
-}
-
-WebMemoryDumpProviderAdapter::~WebMemoryDumpProviderAdapter() {
- DCHECK(!is_registered_);
-}
-
-bool WebMemoryDumpProviderAdapter::OnMemoryDump(
- const base::trace_event::MemoryDumpArgs& args,
- base::trace_event::ProcessMemoryDump* pmd) {
- blink::WebMemoryDumpLevelOfDetail level;
- switch (args.level_of_detail) {
- case base::trace_event::MemoryDumpLevelOfDetail::LIGHT:
- level = blink::WebMemoryDumpLevelOfDetail::Light;
- break;
- case base::trace_event::MemoryDumpLevelOfDetail::DETAILED:
- level = blink::WebMemoryDumpLevelOfDetail::Detailed;
- break;
- default:
- NOTREACHED();
- return false;
- }
- WebProcessMemoryDumpImpl web_pmd_impl(args.level_of_detail, pmd);
- return web_memory_dump_provider_->onMemoryDump(level, &web_pmd_impl);
-}
-
-void WebMemoryDumpProviderAdapter::OnHeapProfilingEnabled(bool enabled) {
- if (!web_memory_dump_provider_->supportsHeapProfiling())
- return;
- web_memory_dump_provider_->onHeapProfilingEnabled(enabled);
-}
-
-} // namespace content
« no previous file with comments | « content/child/web_memory_dump_provider_adapter.h ('k') | content/child/web_process_memory_dump_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698