OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/browser/renderer_host/render_widget_host_view_gtk.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_gtk.h" |
6 | 6 |
7 // If this gets included after the gtk headers, then a bunch of compiler | 7 // If this gets included after the gtk headers, then a bunch of compiler |
8 // errors happen because of a "#define Status int" in Xlib.h, which interacts | 8 // errors happen because of a "#define Status int" in Xlib.h, which interacts |
9 // badly with net::URLRequestStatus::Status. | 9 // badly with net::URLRequestStatus::Status. |
10 #include "content/common/view_messages.h" | 10 #include "content/common/view_messages.h" |
(...skipping 1039 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1050 memcpy(pixels, image->data, bitmap_size); | 1050 memcpy(pixels, image->data, bitmap_size); |
1051 | 1051 |
1052 scoped_callback_runner.Release(); | 1052 scoped_callback_runner.Release(); |
1053 callback.Run(true); | 1053 callback.Run(true); |
1054 } | 1054 } |
1055 | 1055 |
1056 void RenderWidgetHostViewGtk::AcceleratedSurfaceBuffersSwapped( | 1056 void RenderWidgetHostViewGtk::AcceleratedSurfaceBuffersSwapped( |
1057 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params, | 1057 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params, |
1058 int gpu_host_id) { | 1058 int gpu_host_id) { |
1059 RenderWidgetHostImpl::AcknowledgeBufferPresent( | 1059 RenderWidgetHostImpl::AcknowledgeBufferPresent( |
1060 params.route_id, gpu_host_id, true, 0); | 1060 params.route_id, gpu_host_id, params.surface_handle, 0); |
1061 } | 1061 } |
1062 | 1062 |
1063 void RenderWidgetHostViewGtk::AcceleratedSurfacePostSubBuffer( | 1063 void RenderWidgetHostViewGtk::AcceleratedSurfacePostSubBuffer( |
1064 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, | 1064 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, |
1065 int gpu_host_id) { | 1065 int gpu_host_id) { |
1066 RenderWidgetHostImpl::AcknowledgeBufferPresent( | 1066 RenderWidgetHostImpl::AcknowledgeBufferPresent( |
1067 params.route_id, gpu_host_id, true, 0); | 1067 params.route_id, gpu_host_id, params.surface_handle, 0); |
1068 } | 1068 } |
1069 | 1069 |
1070 void RenderWidgetHostViewGtk::AcceleratedSurfaceSuspend() { | 1070 void RenderWidgetHostViewGtk::AcceleratedSurfaceSuspend() { |
1071 } | 1071 } |
1072 | 1072 |
1073 bool RenderWidgetHostViewGtk::HasAcceleratedSurface( | 1073 bool RenderWidgetHostViewGtk::HasAcceleratedSurface( |
1074 const gfx::Size& desired_size) { | 1074 const gfx::Size& desired_size) { |
1075 // TODO(jbates) Implement this so this view can use GetBackingStore for both | 1075 // TODO(jbates) Implement this so this view can use GetBackingStore for both |
1076 // software and GPU frames. Defaulting to false just makes GetBackingStore | 1076 // software and GPU frames. Defaulting to false just makes GetBackingStore |
1077 // only useable for software frames. | 1077 // only useable for software frames. |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1545 this)); | 1545 this)); |
1546 } | 1546 } |
1547 BrowserAccessibilityGtk* root = | 1547 BrowserAccessibilityGtk* root = |
1548 browser_accessibility_manager_->GetRoot()->ToBrowserAccessibilityGtk(); | 1548 browser_accessibility_manager_->GetRoot()->ToBrowserAccessibilityGtk(); |
1549 | 1549 |
1550 atk_object_set_role(root->GetAtkObject(), ATK_ROLE_HTML_CONTAINER); | 1550 atk_object_set_role(root->GetAtkObject(), ATK_ROLE_HTML_CONTAINER); |
1551 return root->GetAtkObject(); | 1551 return root->GetAtkObject(); |
1552 } | 1552 } |
1553 | 1553 |
1554 } // namespace content | 1554 } // namespace content |
OLD | NEW |