| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "cc/blink/web_content_layer_impl.h" | 5 #include "cc/blink/web_content_layer_impl.h" |
| 6 | 6 |
| 7 #include "cc/blink/web_display_item_list_impl.h" | 7 #include "cc/blink/web_display_item_list_impl.h" |
| 8 #include "cc/layers/content_layer.h" | 8 #include "cc/layers/content_layer.h" |
| 9 #include "cc/layers/picture_layer.h" | 9 #include "cc/layers/picture_layer.h" |
| 10 #include "third_party/WebKit/public/platform/WebContentLayerClient.h" | 10 #include "third_party/WebKit/public/platform/WebContentLayerClient.h" |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 } | 65 } |
| 66 | 66 |
| 67 scoped_refptr<cc::DisplayItemList> | 67 scoped_refptr<cc::DisplayItemList> |
| 68 WebContentLayerImpl::PaintContentsToDisplayList( | 68 WebContentLayerImpl::PaintContentsToDisplayList( |
| 69 const gfx::Rect& clip, | 69 const gfx::Rect& clip, |
| 70 ContentLayerClient::GraphicsContextStatus graphics_context_status) { | 70 ContentLayerClient::GraphicsContextStatus graphics_context_status) { |
| 71 if (!client_) | 71 if (!client_) |
| 72 return cc::DisplayItemList::Create(); | 72 return cc::DisplayItemList::Create(); |
| 73 | 73 |
| 74 WebDisplayItemListImpl list; | 74 WebDisplayItemListImpl list; |
| 75 #if WEB_DISPLAY_ITEM_LIST_IS_DEFINED | |
| 76 bool can_use_lcd_text = true; | 75 bool can_use_lcd_text = true; |
| 77 client_->paintContents( | 76 client_->paintContents( |
| 78 &list, clip, can_use_lcd_text, | 77 &list, clip, can_use_lcd_text, |
| 79 graphics_context_status == ContentLayerClient::GRAPHICS_CONTEXT_ENABLED | 78 graphics_context_status == ContentLayerClient::GRAPHICS_CONTEXT_ENABLED |
| 80 ? blink::WebContentLayerClient::GraphicsContextEnabled | 79 ? blink::WebContentLayerClient::GraphicsContextEnabled |
| 81 : blink::WebContentLayerClient::GraphicsContextDisabled); | 80 : blink::WebContentLayerClient::GraphicsContextDisabled); |
| 82 #endif | |
| 83 return list.ToDisplayItemList(); | 81 return list.ToDisplayItemList(); |
| 84 } | 82 } |
| 85 | 83 |
| 86 bool WebContentLayerImpl::FillsBoundsCompletely() const { | 84 bool WebContentLayerImpl::FillsBoundsCompletely() const { |
| 87 return false; | 85 return false; |
| 88 } | 86 } |
| 89 | 87 |
| 90 } // namespace cc_blink | 88 } // namespace cc_blink |
| OLD | NEW |