aboutsummaryrefslogtreecommitdiff
path: root/src/core/SkTraceEventCommon.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkTraceEventCommon.h')
-rw-r--r--src/core/SkTraceEventCommon.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/core/SkTraceEventCommon.h b/src/core/SkTraceEventCommon.h
index db46692415..b6495fba8a 100644
--- a/src/core/SkTraceEventCommon.h
+++ b/src/core/SkTraceEventCommon.h
@@ -118,7 +118,11 @@ private:
class SkAndroidFrameworkTraceUtilAlways {
public:
- SkAndroidFrameworkTraceUtilAlways(const char* fmt, ...) {
+ SkAndroidFrameworkTraceUtilAlways(const char* name) {
+ ATRACE_BEGIN(name);
+ }
+
+ SkAndroidFrameworkTraceUtilAlways(bool, const char* fmt, ...) {
if (!ATRACE_ENABLED()) return;
const int BUFFER_SIZE = 256;
@@ -137,7 +141,7 @@ public:
};
#define ATRACE_ANDROID_FRAMEWORK(fmt, ...) SkAndroidFrameworkTraceUtil __trace(true, fmt, ##__VA_ARGS__)
-#define ATRACE_ANDROID_FRAMEWORK_ALWAYS(fmt, ...) SkAndroidFrameworkTraceUtilAlways __trace_always(fmt, ##__VA_ARGS__)
+#define ATRACE_ANDROID_FRAMEWORK_ALWAYS(fmt, ...) SkAndroidFrameworkTraceUtilAlways __trace_always(true, fmt, ##__VA_ARGS__)
// Records a pair of begin and end events called "name" for the current scope, with 0, 1 or 2
// associated arguments. In the framework, the arguments are ignored.