| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/background/background_contents_service.h" | 5 #include "chrome/browser/background/background_contents_service.h" |
| 6 | 6 |
| 7 #include "apps/app_load_service.h" | 7 #include "apps/app_load_service.h" |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 #include "chrome/browser/notifications/notification.h" | 26 #include "chrome/browser/notifications/notification.h" |
| 27 #include "chrome/browser/notifications/notification_delegate.h" | 27 #include "chrome/browser/notifications/notification_delegate.h" |
| 28 #include "chrome/browser/notifications/notification_ui_manager.h" | 28 #include "chrome/browser/notifications/notification_ui_manager.h" |
| 29 #include "chrome/browser/profiles/profile.h" | 29 #include "chrome/browser/profiles/profile.h" |
| 30 #include "chrome/browser/profiles/profile_manager.h" | 30 #include "chrome/browser/profiles/profile_manager.h" |
| 31 #include "chrome/browser/ui/browser.h" | 31 #include "chrome/browser/ui/browser.h" |
| 32 #include "chrome/browser/ui/browser_finder.h" | 32 #include "chrome/browser/ui/browser_finder.h" |
| 33 #include "chrome/browser/ui/browser_tabstrip.h" | 33 #include "chrome/browser/ui/browser_tabstrip.h" |
| 34 #include "chrome/browser/ui/host_desktop.h" | 34 #include "chrome/browser/ui/host_desktop.h" |
| 35 #include "chrome/common/chrome_switches.h" | 35 #include "chrome/common/chrome_switches.h" |
| 36 #include "chrome/common/extensions/background_info.h" | |
| 37 #include "chrome/common/extensions/extension.h" | 36 #include "chrome/common/extensions/extension.h" |
| 38 #include "chrome/common/extensions/extension_constants.h" | 37 #include "chrome/common/extensions/extension_constants.h" |
| 39 #include "chrome/common/extensions/extension_icon_set.h" | 38 #include "chrome/common/extensions/extension_icon_set.h" |
| 40 #include "chrome/common/extensions/manifest_handlers/icons_handler.h" | 39 #include "chrome/common/extensions/manifest_handlers/icons_handler.h" |
| 41 #include "chrome/common/pref_names.h" | 40 #include "chrome/common/pref_names.h" |
| 42 #include "content/public/browser/notification_service.h" | 41 #include "content/public/browser/notification_service.h" |
| 43 #include "content/public/browser/site_instance.h" | 42 #include "content/public/browser/site_instance.h" |
| 44 #include "content/public/browser/web_contents.h" | 43 #include "content/public/browser/web_contents.h" |
| 44 #include "extensions/common/manifest_handlers/background_info.h" |
| 45 #include "grit/generated_resources.h" | 45 #include "grit/generated_resources.h" |
| 46 #include "grit/theme_resources.h" | 46 #include "grit/theme_resources.h" |
| 47 #include "ipc/ipc_message.h" | 47 #include "ipc/ipc_message.h" |
| 48 #include "ui/base/l10n/l10n_util.h" | 48 #include "ui/base/l10n/l10n_util.h" |
| 49 #include "ui/base/resource/resource_bundle.h" | 49 #include "ui/base/resource/resource_bundle.h" |
| 50 #include "ui/gfx/image/image.h" | 50 #include "ui/gfx/image/image.h" |
| 51 | 51 |
| 52 using content::SiteInstance; | 52 using content::SiteInstance; |
| 53 using content::WebContents; | 53 using content::WebContents; |
| 54 using extensions::BackgroundInfo; | 54 using extensions::BackgroundInfo; |
| (...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 743 bool user_gesture, | 743 bool user_gesture, |
| 744 bool* was_blocked) { | 744 bool* was_blocked) { |
| 745 Browser* browser = chrome::FindLastActiveWithProfile( | 745 Browser* browser = chrome::FindLastActiveWithProfile( |
| 746 Profile::FromBrowserContext(new_contents->GetBrowserContext()), | 746 Profile::FromBrowserContext(new_contents->GetBrowserContext()), |
| 747 chrome::GetActiveDesktop()); | 747 chrome::GetActiveDesktop()); |
| 748 if (browser) { | 748 if (browser) { |
| 749 chrome::AddWebContents(browser, NULL, new_contents, disposition, | 749 chrome::AddWebContents(browser, NULL, new_contents, disposition, |
| 750 initial_pos, user_gesture, was_blocked); | 750 initial_pos, user_gesture, was_blocked); |
| 751 } | 751 } |
| 752 } | 752 } |
| OLD | NEW |