OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 "content/renderer/gpu/render_widget_compositor.h" | 5 #include "content/renderer/gpu/render_widget_compositor.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <limits> | 8 #include <limits> |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 727 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
738 void RenderWidgetCompositor::registerSelection( | 738 void RenderWidgetCompositor::registerSelection( |
739 const blink::WebSelection& selection) { | 739 const blink::WebSelection& selection) { |
740 layer_tree_host_->RegisterSelection(ConvertWebSelection(selection)); | 740 layer_tree_host_->RegisterSelection(ConvertWebSelection(selection)); |
741 } | 741 } |
742 | 742 |
743 void RenderWidgetCompositor::clearSelection() { | 743 void RenderWidgetCompositor::clearSelection() { |
744 cc::LayerSelection empty_selection; | 744 cc::LayerSelection empty_selection; |
745 layer_tree_host_->RegisterSelection(empty_selection); | 745 layer_tree_host_->RegisterSelection(empty_selection); |
746 } | 746 } |
747 | 747 |
| 748 void RenderWidgetCompositor::setHaveWheelEventHandlers(bool value) { |
| 749 layer_tree_host_->SetHaveWheelEventHandlers(value); |
| 750 } |
| 751 |
748 void CompositeAndReadbackAsyncCallback( | 752 void CompositeAndReadbackAsyncCallback( |
749 blink::WebCompositeAndReadbackAsyncCallback* callback, | 753 blink::WebCompositeAndReadbackAsyncCallback* callback, |
750 scoped_ptr<cc::CopyOutputResult> result) { | 754 scoped_ptr<cc::CopyOutputResult> result) { |
751 if (result->HasBitmap()) { | 755 if (result->HasBitmap()) { |
752 scoped_ptr<SkBitmap> result_bitmap = result->TakeBitmap(); | 756 scoped_ptr<SkBitmap> result_bitmap = result->TakeBitmap(); |
753 callback->didCompositeAndReadback(*result_bitmap); | 757 callback->didCompositeAndReadback(*result_bitmap); |
754 } else { | 758 } else { |
755 callback->didCompositeAndReadback(SkBitmap()); | 759 callback->didCompositeAndReadback(SkBitmap()); |
756 } | 760 } |
757 } | 761 } |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1100 #endif | 1104 #endif |
1101 return actual; | 1105 return actual; |
1102 } | 1106 } |
1103 | 1107 |
1104 void RenderWidgetCompositor::SetPaintedDeviceScaleFactor( | 1108 void RenderWidgetCompositor::SetPaintedDeviceScaleFactor( |
1105 float device_scale) { | 1109 float device_scale) { |
1106 layer_tree_host_->SetPaintedDeviceScaleFactor(device_scale); | 1110 layer_tree_host_->SetPaintedDeviceScaleFactor(device_scale); |
1107 } | 1111 } |
1108 | 1112 |
1109 } // namespace content | 1113 } // namespace content |
OLD | NEW |