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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutObject.h

Issue 2766943002: Do-not-commit: Count layout tree memory usage
Patch Set: Rebase, add object paint property counter Created 3 years, 8 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) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 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) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc.
7 * All rights reserved. 7 * All rights reserved.
8 * Copyright (C) 2009 Google Inc. All rights reserved. 8 * Copyright (C) 2009 Google Inc. All rights reserved.
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 621 matching lines...) Expand 10 before | Expand all | Expand 10 after
632 bool isSVGResourceContainer() const { 632 bool isSVGResourceContainer() const {
633 return isOfType(LayoutObjectSVGResourceContainer); 633 return isOfType(LayoutObjectSVGResourceContainer);
634 } 634 }
635 bool isSVGResourceFilter() const { 635 bool isSVGResourceFilter() const {
636 return isOfType(LayoutObjectSVGResourceFilter); 636 return isOfType(LayoutObjectSVGResourceFilter);
637 } 637 }
638 bool isSVGResourceFilterPrimitive() const { 638 bool isSVGResourceFilterPrimitive() const {
639 return isOfType(LayoutObjectSVGResourceFilterPrimitive); 639 return isOfType(LayoutObjectSVGResourceFilterPrimitive);
640 } 640 }
641 641
642 // Total size of this object.
643 virtual char objectSize() const { return sizeof(this); }
644 // Total size of this object plus any heap-allocated memory.
645 virtual char approximateHeapMemoryUsage() const;
646
642 // FIXME: Those belong into a SVG specific base-class for all layoutObjects 647 // FIXME: Those belong into a SVG specific base-class for all layoutObjects
643 // (see above). Unfortunately we don't have such a class yet, because it's not 648 // (see above). Unfortunately we don't have such a class yet, because it's not
644 // possible for all layoutObjects to inherit from LayoutSVGObject -> 649 // possible for all layoutObjects to inherit from LayoutSVGObject ->
645 // LayoutObject (some need LayoutBlock inheritance for instance) 650 // LayoutObject (some need LayoutBlock inheritance for instance)
646 virtual void setNeedsTransformUpdate() {} 651 virtual void setNeedsTransformUpdate() {}
647 virtual void setNeedsBoundariesUpdate(); 652 virtual void setNeedsBoundariesUpdate();
648 653
649 bool isBlendingAllowed() const { 654 bool isBlendingAllowed() const {
650 return !isSVG() || (isSVGContainer() && !isSVGHiddenContainer()) || 655 return !isSVG() || (isSVGContainer() && !isSVGHiddenContainer()) ||
651 isSVGShape() || isSVGImage() || isSVGText(); 656 isSVGShape() || isSVGImage() || isSVGText();
(...skipping 2127 matching lines...) Expand 10 before | Expand all | Expand 10 after
2779 CORE_EXPORT void showLineTree(const blink::LayoutObject*); 2784 CORE_EXPORT void showLineTree(const blink::LayoutObject*);
2780 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1); 2785 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1);
2781 // We don't make object2 an optional parameter so that showLayoutTree 2786 // We don't make object2 an optional parameter so that showLayoutTree
2782 // can be called from gdb easily. 2787 // can be called from gdb easily.
2783 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1, 2788 CORE_EXPORT void showLayoutTree(const blink::LayoutObject* object1,
2784 const blink::LayoutObject* object2); 2789 const blink::LayoutObject* object2);
2785 2790
2786 #endif 2791 #endif
2787 2792
2788 #endif // LayoutObject_h 2793 #endif // LayoutObject_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698