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

Side by Side Diff: third_party/WebKit/Source/core/layout/compositing/GraphicsLayerUpdater.cpp

Issue 2770713004: Fix position of layer with floating ancestor within inline parent layer (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/PaintLayer.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2014 Google Inc. All rights reserved. 3 * Copyright (C) 2014 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 m_compositingAncestor = &layer; 50 m_compositingAncestor = &layer;
51 if (layer.stackingNode()->isStackingContext()) 51 if (layer.stackingNode()->isStackingContext())
52 m_compositingStackingContext = &layer; 52 m_compositingStackingContext = &layer;
53 } 53 }
54 } 54 }
55 55
56 const PaintLayer* compositingContainer(const PaintLayer& layer) const { 56 const PaintLayer* compositingContainer(const PaintLayer& layer) const {
57 if (layer.stackingNode()->isStacked()) 57 if (layer.stackingNode()->isStacked())
58 return m_compositingStackingContext; 58 return m_compositingStackingContext;
59 59
60 // TODO(wangxianzhu, chrishtr): This is incorrect if m_compositingAncestor
61 // is inline and there is any non-layer floating object between layer and
62 // m_compositingAncestor. Should use the logic in PaintLayer::
63 // containingLayer().
60 if (layer.layoutObject().isFloatingWithNonContainingBlockParent()) 64 if (layer.layoutObject().isFloatingWithNonContainingBlockParent())
61 return layer.enclosingLayerWithCompositedLayerMapping(ExcludeSelf); 65 return layer.enclosingLayerWithCompositedLayerMapping(ExcludeSelf);
62 66
63 return m_compositingAncestor; 67 return m_compositingAncestor;
64 } 68 }
65 69
66 const PaintLayer* compositingStackingContext() const { 70 const PaintLayer* compositingStackingContext() const {
67 return m_compositingStackingContext; 71 return m_compositingStackingContext;
68 } 72 }
69 73
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 ->assertNeedsToUpdateGraphicsLayerBitsCleared(); 132 ->assertNeedsToUpdateGraphicsLayerBitsCleared();
129 133
130 for (PaintLayer* child = layer.firstChild(); child; 134 for (PaintLayer* child = layer.firstChild(); child;
131 child = child->nextSibling()) 135 child = child->nextSibling())
132 assertNeedsToUpdateGraphicsLayerBitsCleared(*child); 136 assertNeedsToUpdateGraphicsLayerBitsCleared(*child);
133 } 137 }
134 138
135 #endif 139 #endif
136 140
137 } // namespace blink 141 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/paint/PaintLayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698