| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 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 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 { | 388 { |
| 389 WebLayer* contentsLayer = contentsLayerIfRegistered(); | 389 WebLayer* contentsLayer = contentsLayerIfRegistered(); |
| 390 if (!contentsLayer) | 390 if (!contentsLayer) |
| 391 return; | 391 return; |
| 392 | 392 |
| 393 contentsLayer->setPosition(FloatPoint(m_contentsRect.x(), m_contentsRect.y()
)); | 393 contentsLayer->setPosition(FloatPoint(m_contentsRect.x(), m_contentsRect.y()
)); |
| 394 contentsLayer->setBounds(IntSize(m_contentsRect.width(), m_contentsRect.heig
ht())); | 394 contentsLayer->setBounds(IntSize(m_contentsRect.width(), m_contentsRect.heig
ht())); |
| 395 | 395 |
| 396 if (m_contentsClippingMaskLayer) { | 396 if (m_contentsClippingMaskLayer) { |
| 397 if (m_contentsClippingMaskLayer->size() != m_contentsRect.size()) { | 397 if (m_contentsClippingMaskLayer->size() != m_contentsRect.size()) { |
| 398 m_contentsClippingMaskLayer->setSize(m_contentsRect.size()); | 398 m_contentsClippingMaskLayer->setSize(FloatSize(m_contentsRect.size()
)); |
| 399 m_contentsClippingMaskLayer->setNeedsDisplay(); | 399 m_contentsClippingMaskLayer->setNeedsDisplay(); |
| 400 } | 400 } |
| 401 m_contentsClippingMaskLayer->setPosition(FloatPoint()); | 401 m_contentsClippingMaskLayer->setPosition(FloatPoint()); |
| 402 m_contentsClippingMaskLayer->setOffsetFromLayoutObject(offsetFromLayoutO
bject() + IntSize(m_contentsRect.location().x(), m_contentsRect.location().y()))
; | 402 m_contentsClippingMaskLayer->setOffsetFromLayoutObject(offsetFromLayoutO
bject() + IntSize(m_contentsRect.location().x(), m_contentsRect.location().y()))
; |
| 403 } | 403 } |
| 404 } | 404 } |
| 405 | 405 |
| 406 static HashSet<int>* s_registeredLayerSet; | 406 static HashSet<int>* s_registeredLayerSet; |
| 407 | 407 |
| 408 void GraphicsLayer::registerContentsLayer(WebLayer* layer) | 408 void GraphicsLayer::registerContentsLayer(WebLayer* layer) |
| (...skipping 796 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1205 { | 1205 { |
| 1206 if (!layer) { | 1206 if (!layer) { |
| 1207 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n"); | 1207 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n"); |
| 1208 return; | 1208 return; |
| 1209 } | 1209 } |
| 1210 | 1210 |
| 1211 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo); | 1211 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo); |
| 1212 fprintf(stderr, "%s\n", output.utf8().data()); | 1212 fprintf(stderr, "%s\n", output.utf8().data()); |
| 1213 } | 1213 } |
| 1214 #endif | 1214 #endif |
| OLD | NEW |