| 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_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 | 8 |
| 9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 1089 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1100 void RenderWidgetHostViewAura::CopyFromCompositingSurface( | 1100 void RenderWidgetHostViewAura::CopyFromCompositingSurface( |
| 1101 const gfx::Rect& src_subrect, | 1101 const gfx::Rect& src_subrect, |
| 1102 const gfx::Size& dst_size, | 1102 const gfx::Size& dst_size, |
| 1103 const ReadbackRequestCallback& callback, | 1103 const ReadbackRequestCallback& callback, |
| 1104 const SkColorType preferred_color_type) { | 1104 const SkColorType preferred_color_type) { |
| 1105 delegated_frame_host_->CopyFromCompositingSurface( | 1105 delegated_frame_host_->CopyFromCompositingSurface( |
| 1106 src_subrect, dst_size, callback, preferred_color_type); | 1106 src_subrect, dst_size, callback, preferred_color_type); |
| 1107 } | 1107 } |
| 1108 | 1108 |
| 1109 void RenderWidgetHostViewAura::CopyFromCompositingSurfaceToVideoFrame( | 1109 void RenderWidgetHostViewAura::CopyFromCompositingSurfaceToVideoFrame( |
| 1110 const gfx::Rect& src_subrect, | 1110 const gfx::Rect& src_subrect, |
| 1111 const scoped_refptr<media::VideoFrame>& target, | 1111 const scoped_refptr<media::VideoFrame>& target, |
| 1112 const base::Callback<void(bool)>& callback) { | 1112 const base::Callback<void(gfx::Rect, bool)>& callback) { |
| 1113 delegated_frame_host_->CopyFromCompositingSurfaceToVideoFrame( | 1113 delegated_frame_host_->CopyFromCompositingSurfaceToVideoFrame( |
| 1114 src_subrect, target, callback); | 1114 src_subrect, target, callback); |
| 1115 } | 1115 } |
| 1116 | 1116 |
| 1117 bool RenderWidgetHostViewAura::CanCopyToVideoFrame() const { | 1117 bool RenderWidgetHostViewAura::CanCopyToVideoFrame() const { |
| 1118 return delegated_frame_host_->CanCopyToVideoFrame(); | 1118 return delegated_frame_host_->CanCopyToVideoFrame(); |
| 1119 } | 1119 } |
| 1120 | 1120 |
| 1121 void RenderWidgetHostViewAura::BeginFrameSubscription( | 1121 void RenderWidgetHostViewAura::BeginFrameSubscription( |
| 1122 scoped_ptr<RenderWidgetHostViewFrameSubscriber> subscriber) { | 1122 scoped_ptr<RenderWidgetHostViewFrameSubscriber> subscriber) { |
| (...skipping 1682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2805 } | 2805 } |
| 2806 } | 2806 } |
| 2807 | 2807 |
| 2808 //////////////////////////////////////////////////////////////////////////////// | 2808 //////////////////////////////////////////////////////////////////////////////// |
| 2809 // DelegatedFrameHost, public: | 2809 // DelegatedFrameHost, public: |
| 2810 | 2810 |
| 2811 ui::Layer* RenderWidgetHostViewAura::DelegatedFrameHostGetLayer() const { | 2811 ui::Layer* RenderWidgetHostViewAura::DelegatedFrameHostGetLayer() const { |
| 2812 return window_->layer(); | 2812 return window_->layer(); |
| 2813 } | 2813 } |
| 2814 | 2814 |
| 2815 aura::Window* RenderWidgetHostViewAura::DelegatedFrameHostGetNativeView() |
| 2816 const { |
| 2817 return window_; |
| 2818 } |
| 2819 |
| 2815 bool RenderWidgetHostViewAura::DelegatedFrameHostIsVisible() const { | 2820 bool RenderWidgetHostViewAura::DelegatedFrameHostIsVisible() const { |
| 2816 return !host_->is_hidden(); | 2821 return !host_->is_hidden(); |
| 2817 } | 2822 } |
| 2818 | 2823 |
| 2819 gfx::Size RenderWidgetHostViewAura::DelegatedFrameHostDesiredSizeInDIP() const { | 2824 gfx::Size RenderWidgetHostViewAura::DelegatedFrameHostDesiredSizeInDIP() const { |
| 2820 return window_->bounds().size(); | 2825 return window_->bounds().size(); |
| 2821 } | 2826 } |
| 2822 | 2827 |
| 2823 bool RenderWidgetHostViewAura::DelegatedFrameCanCreateResizeLock() const { | 2828 bool RenderWidgetHostViewAura::DelegatedFrameCanCreateResizeLock() const { |
| 2824 #if !defined(OS_CHROMEOS) | 2829 #if !defined(OS_CHROMEOS) |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2884 | 2889 |
| 2885 //////////////////////////////////////////////////////////////////////////////// | 2890 //////////////////////////////////////////////////////////////////////////////// |
| 2886 // RenderWidgetHostViewBase, public: | 2891 // RenderWidgetHostViewBase, public: |
| 2887 | 2892 |
| 2888 // static | 2893 // static |
| 2889 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) { | 2894 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) { |
| 2890 GetScreenInfoForWindow(results, NULL); | 2895 GetScreenInfoForWindow(results, NULL); |
| 2891 } | 2896 } |
| 2892 | 2897 |
| 2893 } // namespace content | 2898 } // namespace content |
| OLD | NEW |