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

Side by Side Diff: third_party/WebKit/Source/core/dom/Node.h

Issue 2220873002: Add a fast-path for independent inherited properties (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added 2 more tests 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 unified diff | Download patch
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) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2004-2011, 2014 Apple Inc. All rights reserved. 5 * Copyright (C) 2004-2011, 2014 Apple Inc. All rights reserved.
6 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 6 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 823 matching lines...) Expand 10 before | Expand all | Expand 10 after
834 834
835 AttachContext context; 835 AttachContext context;
836 context.performingReattach = true; 836 context.performingReattach = true;
837 837
838 detachLayoutTree(context); 838 detachLayoutTree(context);
839 markAncestorsWithChildNeedsStyleRecalc(); 839 markAncestorsWithChildNeedsStyleRecalc();
840 } 840 }
841 841
842 inline bool Node::shouldCallRecalcStyle(StyleRecalcChange change) 842 inline bool Node::shouldCallRecalcStyle(StyleRecalcChange change)
843 { 843 {
844 return change >= Inherit || needsStyleRecalc() || childNeedsStyleRecalc(); 844 return change >= IndependentInherit || needsStyleRecalc() || childNeedsStyle Recalc();
845 } 845 }
846 846
847 inline bool isTreeScopeRoot(const Node* node) 847 inline bool isTreeScopeRoot(const Node* node)
848 { 848 {
849 return !node || node->isDocumentNode() || node->isShadowRoot(); 849 return !node || node->isDocumentNode() || node->isShadowRoot();
850 } 850 }
851 851
852 inline bool isTreeScopeRoot(const Node& node) 852 inline bool isTreeScopeRoot(const Node& node)
853 { 853 {
854 return node.isDocumentNode() || node.isShadowRoot(); 854 return node.isDocumentNode() || node.isShadowRoot();
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
886 } // namespace blink 886 } // namespace blink
887 887
888 #ifndef NDEBUG 888 #ifndef NDEBUG
889 // Outside the WebCore namespace for ease of invocation from gdb. 889 // Outside the WebCore namespace for ease of invocation from gdb.
890 void showNode(const blink::Node*); 890 void showNode(const blink::Node*);
891 void showTree(const blink::Node*); 891 void showTree(const blink::Node*);
892 void showNodePath(const blink::Node*); 892 void showNodePath(const blink::Node*);
893 #endif 893 #endif
894 894
895 #endif // Node_h 895 #endif // Node_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/Element.cpp ('k') | third_party/WebKit/Source/core/dom/shadow/InsertionPoint.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698