OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 <string> | 5 #include <string> |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | |
9 #include "base/base_paths.h" | 8 #include "base/base_paths.h" |
10 #include "base/command_line.h" | 9 #include "base/command_line.h" |
11 #include "base/logging.h" | 10 #include "base/logging.h" |
12 #include "base/utf_string_conversions.h" | 11 #include "base/utf_string_conversions.h" |
13 #include "chrome/app/chrome_command_ids.h" | 12 #include "chrome/app/chrome_command_ids.h" |
14 #include "chrome/browser/background_application_list_model.h" | 13 #include "chrome/browser/background_application_list_model.h" |
15 #include "chrome/browser/background_mode_manager.h" | 14 #include "chrome/browser/background_mode_manager.h" |
16 #include "chrome/browser/browser_list.h" | 15 #include "chrome/browser/browser_list.h" |
17 #include "chrome/browser/extensions/extension_service.h" | 16 #include "chrome/browser/extensions/extension_service.h" |
18 #include "chrome/browser/metrics/user_metrics.h" | 17 #include "chrome/browser/metrics/user_metrics.h" |
19 #include "chrome/browser/profiles/profile.h" | 18 #include "chrome/browser/profiles/profile.h" |
20 #include "chrome/browser/status_icons/status_icon.h" | 19 #include "chrome/browser/status_icons/status_icon.h" |
21 #include "chrome/browser/status_icons/status_tray.h" | 20 #include "chrome/browser/status_icons/status_tray.h" |
22 #include "chrome/common/chrome_switches.h" | 21 #include "chrome/common/chrome_switches.h" |
23 #include "chrome/common/extensions/extension.h" | 22 #include "chrome/common/extensions/extension.h" |
24 #include "chrome/common/notification_service.h" | 23 #include "chrome/common/notification_service.h" |
25 #include "chrome/common/notification_type.h" | 24 #include "chrome/common/notification_type.h" |
26 #include "chrome/common/pref_names.h" | 25 #include "chrome/common/pref_names.h" |
27 #include "grit/chromium_strings.h" | 26 #include "grit/chromium_strings.h" |
28 #include "grit/generated_resources.h" | 27 #include "grit/generated_resources.h" |
29 #include "grit/theme_resources.h" | 28 #include "grit/theme_resources.h" |
| 29 #include "ui/base/resource/resource_bundle.h" |
30 | 30 |
31 void BackgroundModeManager::OnApplicationDataChanged( | 31 void BackgroundModeManager::OnApplicationDataChanged( |
32 const Extension* extension) { | 32 const Extension* extension) { |
33 UpdateContextMenuEntryIcon(extension); | 33 UpdateContextMenuEntryIcon(extension); |
34 } | 34 } |
35 | 35 |
36 void BackgroundModeManager::OnApplicationListChanged() { | 36 void BackgroundModeManager::OnApplicationListChanged() { |
37 UpdateStatusTrayIconContextMenu(); | 37 UpdateStatusTrayIconContextMenu(); |
38 } | 38 } |
39 | 39 |
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
370 // is always running on that platform, making it superfluous. | 370 // is always running on that platform, making it superfluous. |
371 #if defined(OS_CHROMEOS) | 371 #if defined(OS_CHROMEOS) |
372 return false; | 372 return false; |
373 #else | 373 #else |
374 bool background_mode_enabled = | 374 bool background_mode_enabled = |
375 !command_line->HasSwitch(switches::kDisableBackgroundMode) && | 375 !command_line->HasSwitch(switches::kDisableBackgroundMode) && |
376 !command_line->HasSwitch(switches::kDisableExtensions); | 376 !command_line->HasSwitch(switches::kDisableExtensions); |
377 return background_mode_enabled; | 377 return background_mode_enabled; |
378 #endif | 378 #endif |
379 } | 379 } |
OLD | NEW |