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

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

Issue 1533683002: Persist invalidation sets on detach root (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Avoid detaching when in inactive state Created 4 years, 12 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 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
515 else 515 else
516 m_data.m_layoutObject = layoutObject; 516 m_data.m_layoutObject = layoutObject;
517 } 517 }
518 518
519 // Use these two methods with caution. 519 // Use these two methods with caution.
520 LayoutBox* layoutBox() const; 520 LayoutBox* layoutBox() const;
521 LayoutBoxModelObject* layoutBoxModelObject() const; 521 LayoutBoxModelObject* layoutBoxModelObject() const;
522 522
523 struct AttachContext { 523 struct AttachContext {
524 STACK_ALLOCATED(); 524 STACK_ALLOCATED();
525 ComputedStyle* resolvedStyle; 525 ComputedStyle* resolvedStyle = nullptr;
526 bool performingReattach; 526 bool performingReattach = false;
527 bool clearInvalidation = false;
527 528
528 AttachContext() : resolvedStyle(nullptr), performingReattach(false) { } 529 AttachContext() { }
529 }; 530 };
530 531
531 // Attaches this node to the layout tree. This calculates the style to be ap plied to the node and creates an 532 // Attaches this node to the layout tree. This calculates the style to be ap plied to the node and creates an
532 // appropriate LayoutObject which will be inserted into the tree (except whe n the style has display: none). This 533 // appropriate LayoutObject which will be inserted into the tree (except whe n the style has display: none). This
533 // makes the node visible in the FrameView. 534 // makes the node visible in the FrameView.
534 virtual void attach(const AttachContext& = AttachContext()); 535 virtual void attach(const AttachContext& = AttachContext());
535 536
536 // Detaches the node from the layout tree, making it invisible in the render ed view. This method will remove 537 // Detaches the node from the layout tree, making it invisible in the render ed view. This method will remove
537 // the node's layout object from the layout tree and delete it. 538 // the node's layout object from the layout tree and delete it.
538 virtual void detach(const AttachContext& = AttachContext()); 539 virtual void detach(const AttachContext& = AttachContext());
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
918 } // namespace blink 919 } // namespace blink
919 920
920 #ifndef NDEBUG 921 #ifndef NDEBUG
921 // Outside the WebCore namespace for ease of invocation from gdb. 922 // Outside the WebCore namespace for ease of invocation from gdb.
922 void showNode(const blink::Node*); 923 void showNode(const blink::Node*);
923 void showTree(const blink::Node*); 924 void showTree(const blink::Node*);
924 void showNodePath(const blink::Node*); 925 void showNodePath(const blink::Node*);
925 #endif 926 #endif
926 927
927 #endif // Node_h 928 #endif // Node_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/ContainerNode.cpp ('k') | third_party/WebKit/Source/core/dom/Node.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698