OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google 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 * | 7 * |
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 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 return m_clipLayer.get(); | 101 return m_clipLayer.get(); |
102 } | 102 } |
103 | 103 |
104 void LinkHighlight::releaseResources() | 104 void LinkHighlight::releaseResources() |
105 { | 105 { |
106 m_node.clear(); | 106 m_node.clear(); |
107 } | 107 } |
108 | 108 |
109 void LinkHighlight::attachLinkHighlightToCompositingLayer(const RenderLayerModel
Object* paintInvalidationContainer) | 109 void LinkHighlight::attachLinkHighlightToCompositingLayer(const RenderLayerModel
Object* paintInvalidationContainer) |
110 { | 110 { |
111 GraphicsLayer* newGraphicsLayer = paintInvalidationContainer->layer()->graph
icsLayerBackingForScrolling(); | 111 GraphicsLayer* newGraphicsLayer = paintInvalidationContainer->layer()->graph
icsLayerBacking(); |
| 112 if (!newGraphicsLayer->drawsContent()) |
| 113 newGraphicsLayer = paintInvalidationContainer->layer()->graphicsLayerBac
kingForScrolling(); |
112 if (!newGraphicsLayer) | 114 if (!newGraphicsLayer) |
113 return; | 115 return; |
114 | 116 |
115 m_clipLayer->setTransform(SkMatrix44(SkMatrix44::kIdentity_Constructor)); | 117 m_clipLayer->setTransform(SkMatrix44(SkMatrix44::kIdentity_Constructor)); |
116 | 118 |
117 if (m_currentGraphicsLayer != newGraphicsLayer) { | 119 if (m_currentGraphicsLayer != newGraphicsLayer) { |
118 if (m_currentGraphicsLayer) | 120 if (m_currentGraphicsLayer) |
119 clearGraphicsLayerLinkHighlightPointer(); | 121 clearGraphicsLayerLinkHighlightPointer(); |
120 | 122 |
121 m_currentGraphicsLayer = newGraphicsLayer; | 123 m_currentGraphicsLayer = newGraphicsLayer; |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 // Make sure we update geometry on the next callback from WebViewImpl::layou
t(). | 346 // Make sure we update geometry on the next callback from WebViewImpl::layou
t(). |
345 m_geometryNeedsUpdate = true; | 347 m_geometryNeedsUpdate = true; |
346 } | 348 } |
347 | 349 |
348 WebLayer* LinkHighlight::layer() | 350 WebLayer* LinkHighlight::layer() |
349 { | 351 { |
350 return clipLayer(); | 352 return clipLayer(); |
351 } | 353 } |
352 | 354 |
353 } // namespace blink | 355 } // namespace blink |
OLD | NEW |