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

Side by Side Diff: Source/core/rendering/RenderObject.cpp

Issue 547823002: Track reasons for |Node::SetNeedsStyleRecalc| (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: use AtomicString Created 6 years, 2 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/page/Page.cpp ('k') | Source/core/rendering/RenderTextControl.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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2009 Google Inc. All rights reserved. 7 * Copyright (C) 2009 Google Inc. All rights reserved.
8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 2510 matching lines...) Expand 10 before | Expand all | Expand 10 after
2521 { 2521 {
2522 return createPositionWithAffinity(caretMinOffset(), DOWNSTREAM); 2522 return createPositionWithAffinity(caretMinOffset(), DOWNSTREAM);
2523 } 2523 }
2524 2524
2525 void RenderObject::updateDragState(bool dragOn) 2525 void RenderObject::updateDragState(bool dragOn)
2526 { 2526 {
2527 bool valueChanged = (dragOn != isDragging()); 2527 bool valueChanged = (dragOn != isDragging());
2528 setIsDragging(dragOn); 2528 setIsDragging(dragOn);
2529 if (valueChanged && node()) { 2529 if (valueChanged && node()) {
2530 if (node()->isElementNode() && toElement(node())->childrenOrSiblingsAffe ctedByDrag()) 2530 if (node()->isElementNode() && toElement(node())->childrenOrSiblingsAffe ctedByDrag())
2531 node()->setNeedsStyleRecalc(SubtreeStyleChange); 2531 node()->setNeedsStyleRecalc(SubtreeStyleChange, StyleChangeReasonFor Tracing::create(StyleChangeReason::Drag));
2532 else if (style()->affectedByDrag()) 2532 else if (style()->affectedByDrag())
2533 node()->setNeedsStyleRecalc(LocalStyleChange); 2533 node()->setNeedsStyleRecalc(LocalStyleChange, StyleChangeReasonForTr acing::create(StyleChangeReason::Drag));
2534 } 2534 }
2535 for (RenderObject* curr = slowFirstChild(); curr; curr = curr->nextSibling() ) 2535 for (RenderObject* curr = slowFirstChild(); curr; curr = curr->nextSibling() )
2536 curr->updateDragState(dragOn); 2536 curr->updateDragState(dragOn);
2537 } 2537 }
2538 2538
2539 CompositingState RenderObject::compositingState() const 2539 CompositingState RenderObject::compositingState() const
2540 { 2540 {
2541 return hasLayer() ? toRenderLayerModelObject(this)->layer()->compositingStat e() : NotComposited; 2541 return hasLayer() ? toRenderLayerModelObject(this)->layer()->compositingStat e() : NotComposited;
2542 } 2542 }
2543 2543
(...skipping 629 matching lines...) Expand 10 before | Expand all | Expand 10 after
3173 { 3173 {
3174 if (object1) { 3174 if (object1) {
3175 const blink::RenderObject* root = object1; 3175 const blink::RenderObject* root = object1;
3176 while (root->parent()) 3176 while (root->parent())
3177 root = root->parent(); 3177 root = root->parent();
3178 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); 3178 root->showRenderTreeAndMark(object1, "*", object2, "-", 0);
3179 } 3179 }
3180 } 3180 }
3181 3181
3182 #endif 3182 #endif
OLDNEW
« no previous file with comments | « Source/core/page/Page.cpp ('k') | Source/core/rendering/RenderTextControl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698