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

Side by Side Diff: Source/core/rendering/RenderBox.h

Issue 23866007: Fix painting order for floats with shape-outside (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 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 | Annotate | Revision Log
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 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 42
43 enum ContentsClipBehavior { ForceContentsClip, SkipContentsClipIfPossible }; 43 enum ContentsClipBehavior { ForceContentsClip, SkipContentsClipIfPossible };
44 44
45 class RenderBox : public RenderBoxModelObject { 45 class RenderBox : public RenderBoxModelObject {
46 public: 46 public:
47 explicit RenderBox(ContainerNode*); 47 explicit RenderBox(ContainerNode*);
48 virtual ~RenderBox(); 48 virtual ~RenderBox();
49 49
50 // hasAutoZIndex only returns true if the element is positioned or a flex-it em since 50 // hasAutoZIndex only returns true if the element is positioned or a flex-it em since
51 // position:static elements that are not flex-items get their z-index coerce d to auto. 51 // position:static elements that are not flex-items get their z-index coerce d to auto.
52 virtual bool requiresLayer() const OVERRIDE { return isRoot() || isPositione d() || createsGroup() || hasClipPath() || hasOverflowClip() || hasTransform() || hasHiddenBackface() || hasReflection() || style()->specifiesColumns() || !style ()->hasAutoZIndex() || isFloatingWithShapeOutside(); } 52 virtual bool requiresLayer() const OVERRIDE { return isRoot() || isPositione d() || createsGroup() || hasClipPath() || hasOverflowClip() || hasTransform() || hasHiddenBackface() || hasReflection() || style()->specifiesColumns() || !style ()->hasAutoZIndex(); }
53 53
54 virtual bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) const OVERRIDE; 54 virtual bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) const OVERRIDE;
55 55
56 // Use this with caution! No type checking is done! 56 // Use this with caution! No type checking is done!
57 RenderBox* firstChildBox() const; 57 RenderBox* firstChildBox() const;
58 RenderBox* lastChildBox() const; 58 RenderBox* lastChildBox() const;
59 59
60 LayoutUnit x() const { return m_frameRect.x(); } 60 LayoutUnit x() const { return m_frameRect.x(); }
61 LayoutUnit y() const { return m_frameRect.y(); } 61 LayoutUnit y() const { return m_frameRect.y(); }
62 LayoutUnit width() const { return m_frameRect.width(); } 62 LayoutUnit width() const { return m_frameRect.width(); }
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
584 virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject*) con st 584 virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject*) con st
585 { 585 {
586 ASSERT_NOT_REACHED(); 586 ASSERT_NOT_REACHED();
587 return 0; 587 return 0;
588 } 588 }
589 589
590 bool hasSameDirectionAs(const RenderBox* object) const { return style()->dir ection() == object->style()->direction(); } 590 bool hasSameDirectionAs(const RenderBox* object) const { return style()->dir ection() == object->style()->direction(); }
591 591
592 ShapeOutsideInfo* shapeOutsideInfo() const 592 ShapeOutsideInfo* shapeOutsideInfo() const
593 { 593 {
594 return isFloatingWithShapeOutside() && ShapeOutsideInfo::isEnabledFor(th is) ? ShapeOutsideInfo::info(this) : 0; 594 return ShapeOutsideInfo::isEnabledFor(this) ? ShapeOutsideInfo::info(thi s) : 0;
595 } 595 }
596 596
597 protected: 597 protected:
598 virtual void willBeDestroyed(); 598 virtual void willBeDestroyed();
599 599
600 virtual void styleWillChange(StyleDifference, const RenderStyle* newStyle); 600 virtual void styleWillChange(StyleDifference, const RenderStyle* newStyle);
601 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle); 601 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle);
602 virtual void updateFromStyle() OVERRIDE; 602 virtual void updateFromStyle() OVERRIDE;
603 603
604 LayoutRect backgroundPaintedExtent() const; 604 LayoutRect backgroundPaintedExtent() const;
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 if (UNLIKELY(m_inlineBoxWrapper != 0)) 758 if (UNLIKELY(m_inlineBoxWrapper != 0))
759 deleteLineBoxWrapper(); 759 deleteLineBoxWrapper();
760 } 760 }
761 761
762 m_inlineBoxWrapper = boxWrapper; 762 m_inlineBoxWrapper = boxWrapper;
763 } 763 }
764 764
765 } // namespace WebCore 765 } // namespace WebCore
766 766
767 #endif // RenderBox_h 767 #endif // RenderBox_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698