Index: chrome/browser/background/background_contents_service.cc |
=================================================================== |
--- chrome/browser/background/background_contents_service.cc (revision 145001) |
+++ chrome/browser/background/background_contents_service.cc (working copy) |
@@ -23,6 +23,7 @@ |
#include "chrome/browser/profiles/profile.h" |
#include "chrome/browser/ui/browser.h" |
#include "chrome/browser/ui/browser_finder.h" |
+#include "chrome/browser/ui/browser_tabstrip.h" |
#include "chrome/common/chrome_notification_types.h" |
#include "chrome/common/chrome_switches.h" |
#include "chrome/common/extensions/extension.h" |
@@ -613,7 +614,8 @@ |
bool user_gesture) { |
Browser* browser = browser::FindLastActiveWithProfile( |
Profile::FromBrowserContext(new_contents->GetBrowserContext())); |
- if (!browser) |
- return; |
- browser->AddWebContents(new_contents, disposition, initial_pos, user_gesture); |
+ if (browser) { |
+ chrome::AddWebContents(browser, NULL, new_contents, disposition, |
+ initial_pos, user_gesture); |
+ } |
} |