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_mac.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_mac.h" |
6 | 6 |
7 #import <objc/runtime.h> | 7 #import <objc/runtime.h> |
8 #include <QuartzCore/QuartzCore.h> | 8 #include <QuartzCore/QuartzCore.h> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 2205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2216 ack_params.renderer_id = pending_swap_ack_->renderer_id; | 2216 ack_params.renderer_id = pending_swap_ack_->renderer_id; |
2217 RenderWidgetHostImpl::AcknowledgeBufferPresent(pending_swap_ack_->route_id, | 2217 RenderWidgetHostImpl::AcknowledgeBufferPresent(pending_swap_ack_->route_id, |
2218 pending_swap_ack_->gpu_host_id, | 2218 pending_swap_ack_->gpu_host_id, |
2219 ack_params); | 2219 ack_params); |
2220 if (render_widget_host_) | 2220 if (render_widget_host_) |
2221 render_widget_host_->AcknowledgeSwapBuffersToRenderer(); | 2221 render_widget_host_->AcknowledgeSwapBuffersToRenderer(); |
2222 | 2222 |
2223 pending_swap_ack_.reset(); | 2223 pending_swap_ack_.reset(); |
2224 } | 2224 } |
2225 | 2225 |
| 2226 SkBitmap::Config RenderWidgetHostViewMac::PreferredReadbackFormat() { |
| 2227 return SkBitmap::kARGB_8888_Config; |
| 2228 } |
| 2229 |
2226 } // namespace content | 2230 } // namespace content |
2227 | 2231 |
2228 // RenderWidgetHostViewCocoa --------------------------------------------------- | 2232 // RenderWidgetHostViewCocoa --------------------------------------------------- |
2229 | 2233 |
2230 @implementation RenderWidgetHostViewCocoa | 2234 @implementation RenderWidgetHostViewCocoa |
2231 @synthesize selectedRange = selectedRange_; | 2235 @synthesize selectedRange = selectedRange_; |
2232 @synthesize suppressNextEscapeKeyUp = suppressNextEscapeKeyUp_; | 2236 @synthesize suppressNextEscapeKeyUp = suppressNextEscapeKeyUp_; |
2233 @synthesize markedRange = markedRange_; | 2237 @synthesize markedRange = markedRange_; |
2234 | 2238 |
2235 - (id)initWithRenderWidgetHostViewMac:(RenderWidgetHostViewMac*)r { | 2239 - (id)initWithRenderWidgetHostViewMac:(RenderWidgetHostViewMac*)r { |
(...skipping 2026 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4262 CGColorGetConstantColor(kCGColorWhite)); | 4266 CGColorGetConstantColor(kCGColorWhite)); |
4263 CGContextFillRect(context, clipRect); | 4267 CGContextFillRect(context, clipRect); |
4264 } | 4268 } |
4265 } | 4269 } |
4266 | 4270 |
4267 - (void)disableRendering { | 4271 - (void)disableRendering { |
4268 renderWidgetHostView_ = NULL; | 4272 renderWidgetHostView_ = NULL; |
4269 } | 4273 } |
4270 | 4274 |
4271 @end // implementation SoftwareLayer | 4275 @end // implementation SoftwareLayer |
OLD | NEW |