Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3622)

Unified Diff: chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc

Issue 7285027: Require a default parent to use some Views implementations on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch to avoid --use-pure-views startup crashes. Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/views/tab_contents/native_tab_contents_container_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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);
}
« no previous file with comments | « chrome/browser/ui/views/tab_contents/native_tab_contents_container_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698