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

Side by Side Diff: chrome/browser/background/background_mode_manager.cc

Issue 1349613003: [Extensions] Un-refcount PermissionSet (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 3 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 unified diff | Download patch
OLDNEW
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_mode_manager.h" 5 #include "chrome/browser/background/background_mode_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 #include "grit/chrome_unscaled_resources.h" 60 #include "grit/chrome_unscaled_resources.h"
61 #include "ui/base/l10n/l10n_util.h" 61 #include "ui/base/l10n/l10n_util.h"
62 #include "ui/base/resource/resource_bundle.h" 62 #include "ui/base/resource/resource_bundle.h"
63 63
64 #if defined(OS_WIN) 64 #if defined(OS_WIN)
65 #include "components/browser_watcher/exit_funnel_win.h" 65 #include "components/browser_watcher/exit_funnel_win.h"
66 #endif 66 #endif
67 67
68 using base::UserMetricsAction; 68 using base::UserMetricsAction;
69 using extensions::Extension; 69 using extensions::Extension;
70 using extensions::UpdatedExtensionPermissionsInfo;
71 70
72 namespace { 71 namespace {
73 72
74 // Records histogram about which auto-launch pattern (if any) was used to launch 73 // Records histogram about which auto-launch pattern (if any) was used to launch
75 // the current process based on |command_line|. 74 // the current process based on |command_line|.
76 void RecordAutoLaunchState(const base::CommandLine& command_line) { 75 void RecordAutoLaunchState(const base::CommandLine& command_line) {
77 enum AutoLaunchState { 76 enum AutoLaunchState {
78 AUTO_LAUNCH_NONE = 0, 77 AUTO_LAUNCH_NONE = 0,
79 AUTO_LAUNCH_BACKGROUND = 1, 78 AUTO_LAUNCH_BACKGROUND = 1,
80 AUTO_LAUNCH_FOREGROUND = 2, 79 AUTO_LAUNCH_FOREGROUND = 2,
(...skipping 963 matching lines...) Expand 10 before | Expand all | Expand 10 after
1044 } 1043 }
1045 } 1044 }
1046 return profile_it; 1045 return profile_it;
1047 } 1046 }
1048 1047
1049 bool BackgroundModeManager::IsBackgroundModePrefEnabled() const { 1048 bool BackgroundModeManager::IsBackgroundModePrefEnabled() const {
1050 PrefService* service = g_browser_process->local_state(); 1049 PrefService* service = g_browser_process->local_state();
1051 DCHECK(service); 1050 DCHECK(service);
1052 return service->GetBoolean(prefs::kBackgroundModeEnabled); 1051 return service->GetBoolean(prefs::kBackgroundModeEnabled);
1053 } 1052 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698