| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009, 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 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 243 #if ENABLE(ASSERT) | 243 #if ENABLE(ASSERT) |
| 244 ASSERT(lifecycle().state() == DocumentLifecycle::CompositingClean); | 244 ASSERT(lifecycle().state() == DocumentLifecycle::CompositingClean); |
| 245 assertNoUnresolvedDirtyBits(); | 245 assertNoUnresolvedDirtyBits(); |
| 246 for (Frame* child = m_layoutView.frameView()->frame().tree().firstChild(); c
hild; child = child->tree().nextSibling()) { | 246 for (Frame* child = m_layoutView.frameView()->frame().tree().firstChild(); c
hild; child = child->tree().nextSibling()) { |
| 247 if (child->isLocalFrame()) | 247 if (child->isLocalFrame()) |
| 248 toLocalFrame(child)->contentLayoutObject()->compositor()->assertNoUn
resolvedDirtyBits(); | 248 toLocalFrame(child)->contentLayoutObject()->compositor()->assertNoUn
resolvedDirtyBits(); |
| 249 } | 249 } |
| 250 #endif | 250 #endif |
| 251 } | 251 } |
| 252 | 252 |
| 253 void DeprecatedPaintLayerCompositor::updateLifecycleToCompositingClean() |
| 254 { |
| 255 for (Frame* child = m_layoutView.frameView()->frame().tree().firstChild(); c
hild; child = child->tree().nextSibling()) { |
| 256 if (!child->isLocalFrame()) |
| 257 continue; |
| 258 LocalFrame* localFrame = toLocalFrame(child); |
| 259 if (localFrame->document()->isActive()) |
| 260 localFrame->contentLayoutObject()->compositor()->updateLifecycleToCo
mpositingClean(); |
| 261 } |
| 262 |
| 263 enableCompositingModeIfNeeded(); |
| 264 |
| 265 if (m_needsUpdateDescendantDependentFlags) { |
| 266 updateDescendantDependentFlagsForEntireSubtree(*rootLayer()); |
| 267 m_needsUpdateDescendantDependentFlags = false; |
| 268 } |
| 269 |
| 270 m_layoutView.commitPendingSelection(); |
| 271 |
| 272 lifecycle().advanceTo(DocumentLifecycle::InCompositingUpdate); |
| 273 updateIfNeeded(); |
| 274 lifecycle().advanceTo(DocumentLifecycle::CompositingClean); |
| 275 } |
| 276 |
| 253 void DeprecatedPaintLayerCompositor::setNeedsCompositingUpdate(CompositingUpdate
Type updateType) | 277 void DeprecatedPaintLayerCompositor::setNeedsCompositingUpdate(CompositingUpdate
Type updateType) |
| 254 { | 278 { |
| 255 ASSERT(updateType != CompositingUpdateNone); | 279 ASSERT(updateType != CompositingUpdateNone); |
| 256 m_pendingUpdateType = std::max(m_pendingUpdateType, updateType); | 280 m_pendingUpdateType = std::max(m_pendingUpdateType, updateType); |
| 257 page()->animator().scheduleVisualUpdate(m_layoutView.frame()); | 281 page()->animator().scheduleVisualUpdate(m_layoutView.frame()); |
| 258 lifecycle().ensureStateAtMost(DocumentLifecycle::LayoutClean); | 282 lifecycle().ensureStateAtMost(DocumentLifecycle::LayoutClean); |
| 259 } | 283 } |
| 260 | 284 |
| 261 void DeprecatedPaintLayerCompositor::didLayout() | 285 void DeprecatedPaintLayerCompositor::didLayout() |
| 262 { | 286 { |
| (...skipping 943 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1206 } else if (graphicsLayer == m_scrollLayer.get()) { | 1230 } else if (graphicsLayer == m_scrollLayer.get()) { |
| 1207 name = "LocalFrame Scrolling Layer"; | 1231 name = "LocalFrame Scrolling Layer"; |
| 1208 } else { | 1232 } else { |
| 1209 ASSERT_NOT_REACHED(); | 1233 ASSERT_NOT_REACHED(); |
| 1210 } | 1234 } |
| 1211 | 1235 |
| 1212 return name; | 1236 return name; |
| 1213 } | 1237 } |
| 1214 | 1238 |
| 1215 } // namespace blink | 1239 } // namespace blink |
| OLD | NEW |