| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef PerformanceLongTaskTiming_h | 5 #ifndef PerformanceLongTaskTiming_h |
| 6 #define PerformanceLongTaskTiming_h | 6 #define PerformanceLongTaskTiming_h |
| 7 | 7 |
| 8 #include "core/timing/PerformanceEntry.h" | 8 #include "core/timing/PerformanceEntry.h" |
| 9 #include "platform/heap/Handle.h" | 9 #include "platform/heap/Handle.h" |
| 10 #include "wtf/Forward.h" | 10 #include "wtf/Forward.h" |
| 11 #include "wtf/text/WTFString.h" | 11 #include "wtf/text/WTFString.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 class DOMWindow; | 15 class DOMWindow; |
| 16 | 16 |
| 17 class PerformanceLongTaskTiming final : public PerformanceEntry { | 17 class PerformanceLongTaskTiming final : public PerformanceEntry { |
| 18 DEFINE_WRAPPERTYPEINFO(); | 18 DEFINE_WRAPPERTYPEINFO(); |
| 19 | 19 |
| 20 public: | 20 public: |
| 21 static PerformanceLongTaskTiming* create(double startTime, | 21 static PerformanceLongTaskTiming* create(double startTime, |
| 22 double endTime, | 22 double endTime, |
| 23 String name, | 23 String name, |
| 24 DOMWindow* culpritWindow) { | 24 String culpritFrameSrc, |
| 25 String culpritFrameId, |
| 26 String culpritFrameName) { |
| 25 return new PerformanceLongTaskTiming(startTime, endTime, name, | 27 return new PerformanceLongTaskTiming(startTime, endTime, name, |
| 26 culpritWindow); | 28 culpritFrameSrc, culpritFrameId, |
| 29 culpritFrameName); |
| 27 } | 30 } |
| 28 | 31 |
| 29 DOMWindow* culpritWindow() const; | 32 String culpritFrameSrc() const; |
| 33 String culpritFrameId() const; |
| 34 String culpritFrameName() const; |
| 30 | 35 |
| 31 DECLARE_VIRTUAL_TRACE(); | 36 DECLARE_VIRTUAL_TRACE(); |
| 32 | 37 |
| 33 private: | 38 private: |
| 34 PerformanceLongTaskTiming(double startTime, | 39 PerformanceLongTaskTiming(double startTime, |
| 35 double endTime, | 40 double endTime, |
| 36 String name, | 41 String name, |
| 37 DOMWindow* culpritWindow); | 42 String culpritFrameSrc, |
| 43 String culpritFrameId, |
| 44 String culpritFrameName); |
| 38 ~PerformanceLongTaskTiming() override; | 45 ~PerformanceLongTaskTiming() override; |
| 39 | 46 |
| 40 Member<DOMWindow> m_culpritWindow; | 47 String m_culpritFrameSrc; |
| 48 String m_culpritFrameId; |
| 49 String m_culpritFrameName; |
| 41 }; | 50 }; |
| 42 | 51 |
| 43 } // namespace blink | 52 } // namespace blink |
| 44 | 53 |
| 45 #endif // PerformanceLongTaskTiming_h | 54 #endif // PerformanceLongTaskTiming_h |
| OLD | NEW |