Index: chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc |
diff --git a/chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc b/chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc |
index a1550c09775cde4998457d47bd4aede6d41ffb89..2ef8e425aae9b0d90d4eae898042f33ce922a6c2 100644 |
--- a/chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc |
+++ b/chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc |
@@ -11,6 +11,7 @@ |
#include "chrome/browser/ui/views/tab_contents/tab_contents_drag_win.h" |
#include "content/browser/tab_contents/tab_contents.h" |
#include "content/browser/tab_contents/tab_contents_view.h" |
+#include "views/views_delegate.h" |
#include "views/widget/widget.h" |
namespace { |
@@ -342,7 +343,8 @@ bool NativeTabContentsViewWin::ScrollZoom(int scroll_type) { |
// static |
NativeTabContentsView* NativeTabContentsView::CreateNativeTabContentsView( |
internal::NativeTabContentsViewDelegate* delegate) { |
- if (views::Widget::IsPureViews()) |
+ if (views::Widget::IsPureViews() && |
+ views::ViewsDelegate::views_delegate->GetDefaultParentView()) |
return new NativeTabContentsViewViews(delegate); |
return new NativeTabContentsViewWin(delegate); |
} |