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

Unified Diff: skia/ext/SkTraceMemoryDump_chrome.h

Issue 1324453008: Implement the getRequestDetails api in chrome side. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@skia_expose
Patch Set: Using correct hash. Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/output/output_surface.cc ('k') | skia/ext/SkTraceMemoryDump_chrome.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/SkTraceMemoryDump_chrome.h
diff --git a/skia/ext/SkTraceMemoryDump_chrome.h b/skia/ext/SkTraceMemoryDump_chrome.h
index 749d99d54677aa6ddbd40dddf1b82e26eaeee53d..e4e1a5defc3a5a344440bb360e7f3c29b14ce9fc 100644
--- a/skia/ext/SkTraceMemoryDump_chrome.h
+++ b/skia/ext/SkTraceMemoryDump_chrome.h
@@ -7,7 +7,9 @@
#include <string>
+#include "base/basictypes.h"
#include "base/macros.h"
+#include "base/trace_event/memory_dump_request_args.h"
#include "third_party/skia/include/core/SkTraceMemoryDump.h"
namespace base {
@@ -26,10 +28,12 @@ class SkTraceMemoryDump_Chrome : public SkTraceMemoryDump {
// |dump_name_prefix| argument specifies the prefix appended to the dump
// name skia provides. By default it is taken as empty string.
SkTraceMemoryDump_Chrome(
+ base::trace_event::MemoryDumpLevelOfDetail level_of_detail,
base::trace_event::ProcessMemoryDump* process_memory_dump);
SkTraceMemoryDump_Chrome(
- const char* dump_name_prefix,
+ const std::string& dump_name_prefix,
+ base::trace_event::MemoryDumpLevelOfDetail level_of_detail,
base::trace_event::ProcessMemoryDump* process_memory_dump);
~SkTraceMemoryDump_Chrome() override;
@@ -45,6 +49,7 @@ class SkTraceMemoryDump_Chrome : public SkTraceMemoryDump {
void setDiscardableMemoryBacking(
const char* dumpName,
const SkDiscardableMemory& discardableMemoryObject) override;
+ LevelOfDetail getRequestedDetails() const override;
protected:
base::trace_event::ProcessMemoryDump* process_memory_dump() {
@@ -52,13 +57,16 @@ class SkTraceMemoryDump_Chrome : public SkTraceMemoryDump {
}
private:
+ // Helper to create allocator dumps.
+ base::trace_event::MemoryAllocatorDump* GetOrCreateAllocatorDump(
+ const char* dumpName);
+
std::string dump_name_prefix_;
base::trace_event::ProcessMemoryDump* process_memory_dump_;
- // Helper to create allocator dumps.
- base::trace_event::MemoryAllocatorDump* GetOrCreateAllocatorDump(
- const char* dumpName);
+ // Stores the level of detail for the current dump.
+ LevelOfDetail request_level_;
DISALLOW_COPY_AND_ASSIGN(SkTraceMemoryDump_Chrome);
};
« no previous file with comments | « cc/output/output_surface.cc ('k') | skia/ext/SkTraceMemoryDump_chrome.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698