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 885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
896 gfx::NativeViewId RenderWidgetHostViewMac::GetNativeViewId() const { | 896 gfx::NativeViewId RenderWidgetHostViewMac::GetNativeViewId() const { |
897 return reinterpret_cast<gfx::NativeViewId>(GetNativeView()); | 897 return reinterpret_cast<gfx::NativeViewId>(GetNativeView()); |
898 } | 898 } |
899 | 899 |
900 gfx::NativeViewAccessible RenderWidgetHostViewMac::GetNativeViewAccessible() { | 900 gfx::NativeViewAccessible RenderWidgetHostViewMac::GetNativeViewAccessible() { |
901 NOTIMPLEMENTED(); | 901 NOTIMPLEMENTED(); |
902 return static_cast<gfx::NativeViewAccessible>(NULL); | 902 return static_cast<gfx::NativeViewAccessible>(NULL); |
903 } | 903 } |
904 | 904 |
905 void RenderWidgetHostViewMac::MovePluginWindows( | 905 void RenderWidgetHostViewMac::MovePluginWindows( |
906 const gfx::Vector2d& scroll_offset, | |
907 const std::vector<WebPluginGeometry>& moves) { | 906 const std::vector<WebPluginGeometry>& moves) { |
908 // Must be overridden, but unused on this platform. Core Animation | 907 // Must be overridden, but unused on this platform. Core Animation |
909 // plugins are drawn by the GPU process (through the compositor), | 908 // plugins are drawn by the GPU process (through the compositor), |
910 // and Core Graphics plugins are drawn by the renderer process. | 909 // and Core Graphics plugins are drawn by the renderer process. |
911 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 910 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
912 } | 911 } |
913 | 912 |
914 void RenderWidgetHostViewMac::Focus() { | 913 void RenderWidgetHostViewMac::Focus() { |
915 [[cocoa_view_ window] makeFirstResponder:cocoa_view_]; | 914 [[cocoa_view_ window] makeFirstResponder:cocoa_view_]; |
916 } | 915 } |
(...skipping 3394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4311 } | 4310 } |
4312 | 4311 |
4313 - (void)disableRendering { | 4312 - (void)disableRendering { |
4314 // Disable the fade-out animation as the layer is removed. | 4313 // Disable the fade-out animation as the layer is removed. |
4315 ScopedCAActionDisabler disabler; | 4314 ScopedCAActionDisabler disabler; |
4316 [self removeFromSuperlayer]; | 4315 [self removeFromSuperlayer]; |
4317 renderWidgetHostView_ = nil; | 4316 renderWidgetHostView_ = nil; |
4318 } | 4317 } |
4319 | 4318 |
4320 @end // implementation SoftwareLayer | 4319 @end // implementation SoftwareLayer |
OLD | NEW |