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/web_contents/web_contents_view_aura.h" | 5 #include "content/browser/web_contents/web_contents_view_aura.h" |
6 | 6 |
7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
9 #include "content/browser/renderer_host/dip_util.h" | 9 #include "content/browser/renderer_host/dip_util.h" |
10 #include "content/browser/renderer_host/overscroll_controller.h" | 10 #include "content/browser/renderer_host/overscroll_controller.h" |
(...skipping 662 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
673 | 673 |
674 RenderWidgetHostImpl* host_impl = | 674 RenderWidgetHostImpl* host_impl = |
675 RenderWidgetHostImpl::From(render_widget_host); | 675 RenderWidgetHostImpl::From(render_widget_host); |
676 if (host_impl->overscroll_controller() && web_contents_->GetDelegate() && | 676 if (host_impl->overscroll_controller() && web_contents_->GetDelegate() && |
677 web_contents_->GetDelegate()->CanOverscrollContent()) | 677 web_contents_->GetDelegate()->CanOverscrollContent()) |
678 host_impl->overscroll_controller()->set_delegate(this); | 678 host_impl->overscroll_controller()->set_delegate(this); |
679 | 679 |
680 return view; | 680 return view; |
681 } | 681 } |
682 | 682 |
| 683 RenderWidgetHostView* WebContentsViewAura::CreateViewForPopupWidget( |
| 684 RenderWidgetHost* render_widget_host) { |
| 685 return RenderWidgetHostViewPort::CreateViewForWidget(render_widget_host); |
| 686 } |
| 687 |
683 gfx::NativeView WebContentsViewAura::GetNativeView() const { | 688 gfx::NativeView WebContentsViewAura::GetNativeView() const { |
684 return window_.get(); | 689 return window_.get(); |
685 } | 690 } |
686 | 691 |
687 gfx::NativeView WebContentsViewAura::GetContentNativeView() const { | 692 gfx::NativeView WebContentsViewAura::GetContentNativeView() const { |
688 RenderWidgetHostView* rwhv = web_contents_->GetRenderWidgetHostView(); | 693 RenderWidgetHostView* rwhv = web_contents_->GetRenderWidgetHostView(); |
689 return rwhv ? rwhv->GetNativeView() : NULL; | 694 return rwhv ? rwhv->GetNativeView() : NULL; |
690 } | 695 } |
691 | 696 |
692 gfx::NativeWindow WebContentsViewAura::GetTopLevelNativeWindow() const { | 697 gfx::NativeWindow WebContentsViewAura::GetTopLevelNativeWindow() const { |
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1105 event.location(), | 1110 event.location(), |
1106 gfx::Screen::GetScreenFor(GetNativeView())->GetCursorScreenPoint(), | 1111 gfx::Screen::GetScreenFor(GetNativeView())->GetCursorScreenPoint(), |
1107 ConvertAuraEventFlagsToWebInputEventModifiers(event.flags())); | 1112 ConvertAuraEventFlagsToWebInputEventModifiers(event.flags())); |
1108 if (drag_dest_delegate_) | 1113 if (drag_dest_delegate_) |
1109 drag_dest_delegate_->OnDrop(); | 1114 drag_dest_delegate_->OnDrop(); |
1110 current_drop_data_.reset(); | 1115 current_drop_data_.reset(); |
1111 return current_drag_op_; | 1116 return current_drag_op_; |
1112 } | 1117 } |
1113 | 1118 |
1114 } // namespace content | 1119 } // namespace content |
OLD | NEW |