Index: views/controls/native/native_view_host.cc |
=================================================================== |
--- views/controls/native/native_view_host.cc (revision 110826) |
+++ views/controls/native/native_view_host.cc (working copy) |
@@ -6,7 +6,6 @@ |
#include "base/logging.h" |
#include "ui/gfx/canvas.h" |
-#include "views/controls/native/native_view_host_views.h" |
#include "views/controls/native/native_view_host_wrapper.h" |
#include "views/widget/widget.h" |
@@ -29,7 +28,6 @@ |
NativeViewHost::NativeViewHost() |
: native_view_(NULL), |
- views_view_(NULL), |
fast_resize_(false), |
fast_resize_at_last_layout_(false), |
focus_view_(NULL) { |
@@ -41,7 +39,6 @@ |
void NativeViewHost::Attach(gfx::NativeView native_view) { |
DCHECK(native_view); |
DCHECK(!native_view_); |
- DCHECK(!views_view_); |
native_view_ = native_view; |
// If set_focus_view() has not been invoked, this view is the one that should |
// be seen as focused when the native view receives focus. |
@@ -50,21 +47,6 @@ |
native_wrapper_->NativeViewAttached(); |
} |
-void NativeViewHost::AttachToView(View* view) { |
- if (view == views_view_) |
- return; |
- DCHECK(view); |
- DCHECK(!native_view_); |
- DCHECK(!views_view_); |
- native_wrapper_.reset(new NativeViewHostViews(this)); |
- views_view_ = view; |
- // If set_focus_view() has not been invoked, this view is the one that should |
- // be seen as focused when the native view receives focus. |
- if (!focus_view_) |
- focus_view_ = this; |
- native_wrapper_->NativeViewAttached(); |
-} |
- |
void NativeViewHost::Detach() { |
Detach(false); |
} |
@@ -88,7 +70,7 @@ |
} |
void NativeViewHost::Layout() { |
- if ((!native_view_ && !views_view_) || !native_wrapper_.get()) |
+ if (!native_view_ || !native_wrapper_.get()) |
return; |
gfx::Rect vis_bounds = GetVisibleBounds(); |
@@ -197,10 +179,9 @@ |
// NativeViewHost, private: |
void NativeViewHost::Detach(bool destroyed) { |
- if (native_view_ || views_view_) { |
+ if (native_view_) { |
native_wrapper_->NativeViewDetaching(destroyed); |
native_view_ = NULL; |
- views_view_ = NULL; |
} |
} |