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

Side by Side Diff: third_party/WebKit/Source/core/inspector/InspectorTraceEvents.cpp

Issue 2089063005: Schedule sibling invalidation sets for sibling insert/remove. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed minDirectAdjacent optimization. Created 4 years, 5 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 | « third_party/WebKit/Source/core/inspector/InspectorTraceEvents.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "core/inspector/InspectorTraceEvents.h" 5 #include "core/inspector/InspectorTraceEvents.h"
6 6
7 #include "bindings/core/v8/ScriptSourceCode.h" 7 #include "bindings/core/v8/ScriptSourceCode.h"
8 #include "bindings/core/v8/SourceLocation.h" 8 #include "bindings/core/v8/SourceLocation.h"
9 #include "core/animation/Animation.h" 9 #include "core/animation/Animation.h"
10 #include "core/animation/KeyframeEffect.h" 10 #include "core/animation/KeyframeEffect.h"
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 234
235 const char InspectorStyleInvalidatorInvalidateEvent::ElementHasPendingInvalidati onList[] = "Element has pending invalidation list"; 235 const char InspectorStyleInvalidatorInvalidateEvent::ElementHasPendingInvalidati onList[] = "Element has pending invalidation list";
236 const char InspectorStyleInvalidatorInvalidateEvent::InvalidateCustomPseudo[] = "Invalidate custom pseudo element"; 236 const char InspectorStyleInvalidatorInvalidateEvent::InvalidateCustomPseudo[] = "Invalidate custom pseudo element";
237 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedAttri bute[] = "Invalidation set matched attribute"; 237 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedAttri bute[] = "Invalidation set matched attribute";
238 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedClass [] = "Invalidation set matched class"; 238 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedClass [] = "Invalidation set matched class";
239 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedId[] = "Invalidation set matched id"; 239 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedId[] = "Invalidation set matched id";
240 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedTagNa me[] = "Invalidation set matched tagName"; 240 const char InspectorStyleInvalidatorInvalidateEvent::InvalidationSetMatchedTagNa me[] = "Invalidation set matched tagName";
241 const char InspectorStyleInvalidatorInvalidateEvent::PreventStyleSharingForParen t[] = "Prevent style sharing for parent"; 241 const char InspectorStyleInvalidatorInvalidateEvent::PreventStyleSharingForParen t[] = "Prevent style sharing for parent";
242 242
243 namespace InspectorStyleInvalidatorInvalidateEvent { 243 namespace InspectorStyleInvalidatorInvalidateEvent {
244 std::unique_ptr<TracedValue> fillCommonPart(Element& element, const char* reason ) 244 std::unique_ptr<TracedValue> fillCommonPart(ContainerNode& node, const char* rea son)
245 { 245 {
246 std::unique_ptr<TracedValue> value = TracedValue::create(); 246 std::unique_ptr<TracedValue> value = TracedValue::create();
247 value->setString("frame", toHexString(element.document().frame())); 247 value->setString("frame", toHexString(node.document().frame()));
248 setNodeInfo(value.get(), &element, "nodeId", "nodeName"); 248 setNodeInfo(value.get(), &node, "nodeId", "nodeName");
249 value->setString("reason", reason); 249 value->setString("reason", reason);
250 return value; 250 return value;
251 } 251 }
252 } // namespace InspectorStyleInvalidatorInvalidateEvent 252 } // namespace InspectorStyleInvalidatorInvalidateEvent
253 253
254 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::data(Elem ent& element, const char* reason) 254 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::data(Elem ent& element, const char* reason)
255 { 255 {
256 return fillCommonPart(element, reason); 256 return fillCommonPart(element, reason);
257 } 257 }
258 258
259 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::selectorP art(Element& element, const char* reason, const InvalidationSet& invalidationSet , const String& selectorPart) 259 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::selectorP art(Element& element, const char* reason, const InvalidationSet& invalidationSet , const String& selectorPart)
260 { 260 {
261 std::unique_ptr<TracedValue> value = fillCommonPart(element, reason); 261 std::unique_ptr<TracedValue> value = fillCommonPart(element, reason);
262 value->beginArray("invalidationList"); 262 value->beginArray("invalidationList");
263 invalidationSet.toTracedValue(value.get()); 263 invalidationSet.toTracedValue(value.get());
264 value->endArray(); 264 value->endArray();
265 value->setString("selectorPart", selectorPart); 265 value->setString("selectorPart", selectorPart);
266 return value; 266 return value;
267 } 267 }
268 268
269 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::invalidat ionList(Element& element, const Vector<RefPtr<InvalidationSet>>& invalidationLis t) 269 std::unique_ptr<TracedValue> InspectorStyleInvalidatorInvalidateEvent::invalidat ionList(ContainerNode& node, const Vector<RefPtr<InvalidationSet>>& invalidation List)
270 { 270 {
271 std::unique_ptr<TracedValue> value = fillCommonPart(element, ElementHasPendi ngInvalidationList); 271 std::unique_ptr<TracedValue> value = fillCommonPart(node, ElementHasPendingI nvalidationList);
272 value->beginArray("invalidationList"); 272 value->beginArray("invalidationList");
273 for (const auto& invalidationSet : invalidationList) 273 for (const auto& invalidationSet : invalidationList)
274 invalidationSet->toTracedValue(value.get()); 274 invalidationSet->toTracedValue(value.get());
275 value->endArray(); 275 value->endArray();
276 return value; 276 return value;
277 } 277 }
278 278
279 std::unique_ptr<TracedValue> InspectorStyleRecalcInvalidationTrackingEvent::data (Node* node, const StyleChangeReasonForTracing& reason) 279 std::unique_ptr<TracedValue> InspectorStyleRecalcInvalidationTrackingEvent::data (Node* node, const StyleChangeReasonForTracing& reason)
280 { 280 {
281 ASSERT(node); 281 ASSERT(node);
(...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after
870 if (request.move()) 870 if (request.move())
871 value->setBoolean("move", true); 871 value->setBoolean("move", true);
872 if (request.listBased()) 872 if (request.listBased())
873 value->setBoolean("listBased", true); 873 value->setBoolean("listBased", true);
874 else if (Node* node = result.innerNode()) 874 else if (Node* node = result.innerNode())
875 setNodeInfo(value.get(), node, "nodeId", "nodeName"); 875 setNodeInfo(value.get(), node, "nodeId", "nodeName");
876 return value; 876 return value;
877 } 877 }
878 878
879 } // namespace blink 879 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/inspector/InspectorTraceEvents.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698