| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2010 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 // FIXME: We should not modify the structure of the render tree during | 165 // FIXME: We should not modify the structure of the render tree during |
| 166 // layout. crbug.com/370459 | 166 // layout. crbug.com/370459 |
| 167 DeprecatedDisableModifyRenderTreeStructureAsserts disabler; | 167 DeprecatedDisableModifyRenderTreeStructureAsserts disabler; |
| 168 | 168 |
| 169 if (parent()) { | 169 if (parent()) { |
| 170 for (LayoutObject* child = firstChild(); child; child = firstChild()) { | 170 for (LayoutObject* child = firstChild(); child; child = firstChild()) { |
| 171 // We have to clear the override size, because as a flexbox, we | 171 // We have to clear the override size, because as a flexbox, we |
| 172 // may have set one on the child, and we don't want to leave that | 172 // may have set one on the child, and we don't want to leave that |
| 173 // lying around on the child. | 173 // lying around on the child. |
| 174 if (child->isBox()) | 174 if (child->isBox()) |
| 175 toRenderBox(child)->clearOverrideSize(); | 175 toLayoutBox(child)->clearOverrideSize(); |
| 176 child->remove(); | 176 child->remove(); |
| 177 parent()->addChild(child, this); | 177 parent()->addChild(child, this); |
| 178 parent()->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation(
); | 178 parent()->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation(
); |
| 179 } | 179 } |
| 180 } | 180 } |
| 181 if (placeholder()) | 181 if (placeholder()) |
| 182 placeholder()->remove(); | 182 placeholder()->remove(); |
| 183 remove(); | 183 remove(); |
| 184 destroy(); | 184 destroy(); |
| 185 } | 185 } |
| (...skipping 13 matching lines...) Expand all Loading... |
| 199 if (!m_placeholder) { | 199 if (!m_placeholder) { |
| 200 m_placeholder = new RenderFullScreenPlaceholder(this); | 200 m_placeholder = new RenderFullScreenPlaceholder(this); |
| 201 m_placeholder->setStyle(style); | 201 m_placeholder->setStyle(style); |
| 202 if (parent()) { | 202 if (parent()) { |
| 203 parent()->addChild(m_placeholder, this); | 203 parent()->addChild(m_placeholder, this); |
| 204 parent()->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation(
); | 204 parent()->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation(
); |
| 205 } | 205 } |
| 206 } else | 206 } else |
| 207 m_placeholder->setStyle(style); | 207 m_placeholder->setStyle(style); |
| 208 } | 208 } |
| OLD | NEW |