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

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

Issue 2651253003: Revert of Fix shouldPaint issue when a composited floating iframe becomes non-self-painting (Closed)
Patch Set: Created 3 years, 10 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) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
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 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 const LayoutRect& frameRect() const { 106 const LayoutRect& frameRect() const {
107 ASSERT(isPlaced()); 107 ASSERT(isPlaced());
108 return m_frameRect; 108 return m_frameRect;
109 } 109 }
110 110
111 #if DCHECK_IS_ON() 111 #if DCHECK_IS_ON()
112 bool isInPlacedTree() const { return m_isInPlacedTree; } 112 bool isInPlacedTree() const { return m_isInPlacedTree; }
113 void setIsInPlacedTree(bool value) { m_isInPlacedTree = value; } 113 void setIsInPlacedTree(bool value) { m_isInPlacedTree = value; }
114 #endif 114 #endif
115 115
116 bool shouldPaint() const { return m_shouldPaint; } 116 bool shouldPaint() const;
117 void setShouldPaint(bool shouldPaint) { m_shouldPaint = shouldPaint; } 117 void setShouldPaint(bool shouldPaint) { m_shouldPaint = shouldPaint; }
118 bool isDescendant() const { return m_isDescendant; } 118 bool isDescendant() const { return m_isDescendant; }
119 void setIsDescendant(bool isDescendant) { m_isDescendant = isDescendant; } 119 void setIsDescendant(bool isDescendant) { m_isDescendant = isDescendant; }
120 bool isLowestNonOverhangingFloatInChild() const { 120 bool isLowestNonOverhangingFloatInChild() const {
121 return m_isLowestNonOverhangingFloatInChild; 121 return m_isLowestNonOverhangingFloatInChild;
122 } 122 }
123 void setIsLowestNonOverhangingFloatInChild( 123 void setIsLowestNonOverhangingFloatInChild(
124 bool isLowestNonOverhangingFloatInChild) { 124 bool isLowestNonOverhangingFloatInChild) {
125 m_isLowestNonOverhangingFloatInChild = isLowestNonOverhangingFloatInChild; 125 m_isLowestNonOverhangingFloatInChild = isLowestNonOverhangingFloatInChild;
126 } 126 }
127 127
128 // FIXME: Callers of these methods are dangerous and should be whitelisted 128 // FIXME: Callers of these methods are dangerous and should be whitelisted
129 // explicitly or removed. 129 // explicitly or removed.
130 RootInlineBox* originatingLine() const { return m_originatingLine; } 130 RootInlineBox* originatingLine() const { return m_originatingLine; }
131 void setOriginatingLine(RootInlineBox* line) { m_originatingLine = line; } 131 void setOriginatingLine(RootInlineBox* line) { m_originatingLine = line; }
132 132
133 private: 133 private:
134 explicit FloatingObject(LayoutBox*); 134 explicit FloatingObject(LayoutBox*);
135 FloatingObject(LayoutBox*, 135 FloatingObject(LayoutBox*,
136 Type, 136 Type,
137 const LayoutRect&, 137 const LayoutRect&,
138 bool shouldPaint, 138 bool shouldPaint,
139 bool isDescendant, 139 bool isDescendant,
140 bool isLowestNonOverhangingFloatInChild); 140 bool isLowestNonOverhangingFloatInChild);
141 141
142 bool shouldPaintForCompositedLayoutPart();
143
142 LayoutBox* m_layoutObject; 144 LayoutBox* m_layoutObject;
143 RootInlineBox* m_originatingLine; 145 RootInlineBox* m_originatingLine;
144 LayoutRect m_frameRect; 146 LayoutRect m_frameRect;
145 147
146 unsigned m_type : 2; // Type (left or right aligned) 148 unsigned m_type : 2; // Type (left or right aligned)
147 unsigned m_shouldPaint : 1; 149 unsigned m_shouldPaint : 1;
148 unsigned m_isDescendant : 1; 150 unsigned m_isDescendant : 1;
149 unsigned m_isPlaced : 1; 151 unsigned m_isPlaced : 1;
150 unsigned m_isLowestNonOverhangingFloatInChild : 1; 152 unsigned m_isLowestNonOverhangingFloatInChild : 1;
151 #if DCHECK_IS_ON() 153 #if DCHECK_IS_ON()
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 }; 282 };
281 template <> 283 template <>
282 struct ValueToString<FloatingObject*> { 284 struct ValueToString<FloatingObject*> {
283 static String toString(const FloatingObject*); 285 static String toString(const FloatingObject*);
284 }; 286 };
285 #endif 287 #endif
286 288
287 } // namespace blink 289 } // namespace blink
288 290
289 #endif // FloatingObjects_h 291 #endif // FloatingObjects_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698