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

Side by Side Diff: Source/core/timing/PerformanceBase.h

Issue 1185553002: ResourceTiming should not depend on Document (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « Source/core/loader/FrameFetchContext.cpp ('k') | Source/core/timing/PerformanceBase.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * Copyright (C) 2012 Intel Inc. All rights reserved. 3 * Copyright (C) 2012 Intel Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 28 matching lines...) Expand all
39 #include "wtf/RefCounted.h" 39 #include "wtf/RefCounted.h"
40 #include "wtf/RefPtr.h" 40 #include "wtf/RefPtr.h"
41 #include "wtf/text/WTFString.h" 41 #include "wtf/text/WTFString.h"
42 42
43 namespace blink { 43 namespace blink {
44 44
45 class Document; 45 class Document;
46 class ExceptionState; 46 class ExceptionState;
47 class PerformanceTiming; 47 class PerformanceTiming;
48 class ResourceTimingInfo; 48 class ResourceTimingInfo;
49 class SecurityOrigin;
49 class UserTiming; 50 class UserTiming;
50 51
51 using PerformanceEntryVector = HeapVector<Member<PerformanceEntry>>; 52 using PerformanceEntryVector = HeapVector<Member<PerformanceEntry>>;
52 53
53 class CORE_EXPORT PerformanceBase : public RefCountedGarbageCollectedEventTarget WithInlineData<PerformanceBase> { 54 class CORE_EXPORT PerformanceBase : public RefCountedGarbageCollectedEventTarget WithInlineData<PerformanceBase> {
54 REFCOUNTED_GARBAGE_COLLECTED_EVENT_TARGET(PerformanceBase); 55 REFCOUNTED_GARBAGE_COLLECTED_EVENT_TARGET(PerformanceBase);
55 public: 56 public:
56 virtual ~PerformanceBase(); 57 virtual ~PerformanceBase();
57 58
58 virtual const AtomicString& interfaceName() const override; 59 virtual const AtomicString& interfaceName() const override;
(...skipping 10 matching lines...) Expand all
69 void webkitClearResourceTimings(); 70 void webkitClearResourceTimings();
70 void webkitSetResourceTimingBufferSize(unsigned); 71 void webkitSetResourceTimingBufferSize(unsigned);
71 72
72 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitresourcetimingbufferfull); 73 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitresourcetimingbufferfull);
73 74
74 void clearFrameTimings(); 75 void clearFrameTimings();
75 void setFrameTimingBufferSize(unsigned); 76 void setFrameTimingBufferSize(unsigned);
76 77
77 DEFINE_ATTRIBUTE_EVENT_LISTENER(frametimingbufferfull); 78 DEFINE_ATTRIBUTE_EVENT_LISTENER(frametimingbufferfull);
78 79
79 void addResourceTiming(const ResourceTimingInfo&, Document*); 80 void addResourceTiming(const ResourceTimingInfo&, const SecurityOrigin*);
kinuko 2015/06/12 05:44:54 nit: if we don't expect this could be null conside
Kunihiko Sakamoto 2015/06/12 06:03:21 Done.
80 81
81 void addRenderTiming(Document*, unsigned, double, double); 82 void addRenderTiming(Document*, unsigned, double, double);
82 83
83 void addCompositeTiming(Document*, unsigned, double); 84 void addCompositeTiming(Document*, unsigned, double);
84 85
85 void mark(const String& markName, ExceptionState&); 86 void mark(const String& markName, ExceptionState&);
86 void clearMarks(const String& markName); 87 void clearMarks(const String& markName);
87 88
88 void measure(const String& measureName, const String& startMark, const Strin g& endMark, ExceptionState&); 89 void measure(const String& measureName, const String& startMark, const Strin g& endMark, ExceptionState&);
89 void clearMeasures(const String& measureName); 90 void clearMeasures(const String& measureName);
(...skipping 13 matching lines...) Expand all
103 PerformanceEntryVector m_resourceTimingBuffer; 104 PerformanceEntryVector m_resourceTimingBuffer;
104 unsigned m_resourceTimingBufferSize; 105 unsigned m_resourceTimingBufferSize;
105 double m_timeOrigin; 106 double m_timeOrigin;
106 107
107 Member<UserTiming> m_userTiming; 108 Member<UserTiming> m_userTiming;
108 }; 109 };
109 110
110 } // namespace blink 111 } // namespace blink
111 112
112 #endif // PerformanceBase_h 113 #endif // PerformanceBase_h
OLDNEW
« no previous file with comments | « Source/core/loader/FrameFetchContext.cpp ('k') | Source/core/timing/PerformanceBase.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698