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

Unified Diff: third_party/WebKit/public/platform/WebTraceLocation.h

Issue 2218933003: Revert of Make WebTraceLocation be an alias of tracked_objects::Location (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 | « third_party/WebKit/public/platform/WebThread.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/public/platform/WebTraceLocation.h
diff --git a/third_party/WebKit/public/platform/WebTraceLocation.h b/third_party/WebKit/public/platform/WebTraceLocation.h
index 168badc5bffa73f694b60ed30dc792a7ba8f31e1..3203f0805ae85ceb1534ec0937db30927a3605c4 100644
--- a/third_party/WebKit/public/platform/WebTraceLocation.h
+++ b/third_party/WebKit/public/platform/WebTraceLocation.h
@@ -5,12 +5,27 @@
#ifndef WebTraceLocation_h
#define WebTraceLocation_h
-#include "base/location.h"
+#include "WebCommon.h"
namespace blink {
-using WebTraceLocation = tracked_objects::Location;
-#define BLINK_FROM_HERE FROM_HERE
+// This class is used to keep track of where posted tasks originate. See base/location.h in Chromium.
+// Currently only store the bits used in Blink, base::Location stores more.
+class BLINK_PLATFORM_EXPORT WebTraceLocation {
+public:
+ // These char*s are not copied and must live for the duration of the program.
+ WebTraceLocation(const char* function, const char* file);
+ WebTraceLocation();
+
+ const char* functionName() const;
+ const char* fileName() const;
+
+private:
+ const char* m_functionName;
+ const char* m_fileName;
+};
+
+#define BLINK_FROM_HERE ::blink::WebTraceLocation(__FUNCTION__, __FILE__)
}
« no previous file with comments | « third_party/WebKit/public/platform/WebThread.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698