diff options
Diffstat (limited to 'chrome/browser/web_contents_view_win.cc')
-rw-r--r-- | chrome/browser/web_contents_view_win.cc | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/chrome/browser/web_contents_view_win.cc b/chrome/browser/web_contents_view_win.cc index dcf8136..7c369f7 100644 --- a/chrome/browser/web_contents_view_win.cc +++ b/chrome/browser/web_contents_view_win.cc @@ -52,10 +52,9 @@ WebContents* WebContentsViewWin::GetWebContents() { return web_contents_; } -void WebContentsViewWin::CreateView(HWND parent_hwnd, - const gfx::Rect& initial_bounds) { +void WebContentsViewWin::CreateView() { set_delete_on_destroy(false); - ContainerWin::Init(parent_hwnd, initial_bounds, false); + ContainerWin::Init(GetDesktopWindow(), gfx::Rect(), false); // Remove the root view drop target so we can register our own. RevokeDragDrop(GetHWND()); @@ -365,13 +364,7 @@ WebContents* WebContentsViewWin::CreateNewWindowInternal( new_contents->SetupController(web_contents_->profile()); WebContentsView* new_view = new_contents->view(); - // TODO(beng) - // The intention here is to create background tabs, which should ideally - // be parented to NULL. However doing that causes the corresponding view - // container windows to show up as overlapped windows, which causes - // other issues. We should fix this. - HWND new_view_parent_window = ::GetAncestor(GetContainerHWND(), GA_ROOT); - new_view->CreateView(new_view_parent_window, gfx::Rect()); + new_view->CreateView(); // TODO(brettw) it seems bogus that we have to call this function on the // newly created object and give it one of its own member variables. |