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

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

Issue 2164493002: Renamed Node::attach to Node::attachLayoutTree. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
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, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 899 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 } 910 }
911 911
912 void Node::reattach(const AttachContext& context) 912 void Node::reattach(const AttachContext& context)
913 { 913 {
914 AttachContext reattachContext(context); 914 AttachContext reattachContext(context);
915 reattachContext.performingReattach = true; 915 reattachContext.performingReattach = true;
916 916
917 // We only need to detach if the node has already been through attach(). 917 // We only need to detach if the node has already been through attach().
918 if (getStyleChangeType() < NeedsReattachStyleChange) 918 if (getStyleChangeType() < NeedsReattachStyleChange)
919 detach(reattachContext); 919 detach(reattachContext);
920 attach(reattachContext); 920 attachLayoutTree(reattachContext);
921 } 921 }
922 922
923 void Node::attach(const AttachContext&) 923 void Node::attachLayoutTree(const AttachContext&)
924 { 924 {
925 DCHECK(document().inStyleRecalc() || isDocumentNode()); 925 DCHECK(document().inStyleRecalc() || isDocumentNode());
926 DCHECK(!document().lifecycle().inDetach()); 926 DCHECK(!document().lifecycle().inDetach());
927 DCHECK(needsAttach()); 927 DCHECK(needsAttach());
928 DCHECK(!layoutObject() || (layoutObject()->style() && (layoutObject()->paren t() || layoutObject()->isLayoutView()))); 928 DCHECK(!layoutObject() || (layoutObject()->style() && (layoutObject()->paren t() || layoutObject()->isLayoutView())));
929 929
930 clearNeedsStyleRecalc(); 930 clearNeedsStyleRecalc();
931 931
932 if (AXObjectCache* cache = document().axObjectCache()) 932 if (AXObjectCache* cache = document().axObjectCache())
933 cache->updateCacheAfterNodeIsAttached(this); 933 cache->updateCacheAfterNodeIsAttached(this);
(...skipping 1569 matching lines...) Expand 10 before | Expand all | Expand 10 after
2503 2503
2504 void showNodePath(const blink::Node* node) 2504 void showNodePath(const blink::Node* node)
2505 { 2505 {
2506 if (node) 2506 if (node)
2507 node->showNodePathForThis(); 2507 node->showNodePathForThis();
2508 else 2508 else
2509 fprintf(stderr, "Cannot showNodePath for (nil)\n"); 2509 fprintf(stderr, "Cannot showNodePath for (nil)\n");
2510 } 2510 }
2511 2511
2512 #endif 2512 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698