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

Unified Diff: third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h

Issue 2259013003: Move and rename TaskTimeTracker to public interface exposed to WebThread, use in WebPerf Agent. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move TaskTimeTracker to public interface, expose to WebThread. 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
Index: third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h
diff --git a/third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h b/third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h
index 09a7094e7b0163b262447cf08f6738939ad7d598..1bb6192e16b4ca42bb7467c085e8eb805d3f4cc0 100644
--- a/third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h
+++ b/third_party/WebKit/Source/core/inspector/InspectorWebPerfAgent.h
@@ -7,6 +7,8 @@
#include "core/CoreExport.h"
#include "platform/heap/Handle.h"
+#include "public/platform/WebThread.h"
+#include "public/platform/scheduler/base/task_time_tracker.h"
namespace blink {
@@ -15,7 +17,10 @@ class LocalFrame;
class InspectedFrames;
// Inspector Agent for Web Performance APIs
-class CORE_EXPORT InspectorWebPerfAgent final : public GarbageCollectedFinalized<InspectorWebPerfAgent> {
+class CORE_EXPORT InspectorWebPerfAgent final
+ : public GarbageCollectedFinalized<InspectorWebPerfAgent>
+ , public WebThread::TaskObserver
+ , public scheduler::TaskTimeTracker {
WTF_MAKE_NONCOPYABLE(InspectorWebPerfAgent);
public:
InspectorWebPerfAgent(InspectedFrames*);
alph 2016/08/22 23:51:07 nit: you used to add explicit here. curious why is
panickercorp 2016/08/23 17:43:31 Oops, fixed.
@@ -25,6 +30,13 @@ public:
void willExecuteScript(ExecutionContext*);
void didExecuteScript();
+ // WebThread::TaskTimeObserver implementation.
Sami 2016/08/23 10:34:59 s/Time//
panickercorp 2016/08/23 17:43:31 Done.
+ void willProcessTask() override;
+ void didProcessTask() override;
+
+ // scheduler::TaskTimeTracker implementation
+ void ReportTaskTime(double startTime, double endTime) override;
+
private:
Member<InspectedFrames> m_inspectedFrames;
};

Powered by Google App Engine
This is Rietveld 408576698