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

Side by Side Diff: chrome/installer/setup/setup_util.h

Issue 2507753002: Install the chrome event log provider together with the browser. (Closed)
Patch Set: Address comments. Created 4 years 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 // This file declares util functions for setup project. It also declares a 5 // This file declares util functions for setup project. It also declares a
6 // few functions that the Chrome component updater uses for patching binary 6 // few functions that the Chrome component updater uses for patching binary
7 // deltas. 7 // deltas.
8 8
9 #ifndef CHROME_INSTALLER_SETUP_SETUP_UTIL_H_ 9 #ifndef CHROME_INSTALLER_SETUP_SETUP_UTIL_H_
10 #define CHROME_INSTALLER_SETUP_SETUP_UTIL_H_ 10 #define CHROME_INSTALLER_SETUP_SETUP_UTIL_H_
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 bool IsDowngradeAllowed(const MasterPreferences& prefs); 136 bool IsDowngradeAllowed(const MasterPreferences& prefs);
137 137
138 // Returns true if Chrome has been run within the last 28 days. 138 // Returns true if Chrome has been run within the last 28 days.
139 bool IsChromeActivelyUsed(const InstallerState& installer_state); 139 bool IsChromeActivelyUsed(const InstallerState& installer_state);
140 140
141 // Records UMA metrics for unpack result. 141 // Records UMA metrics for unpack result.
142 void RecordUnPackMetrics(UnPackStatus unpack_status, 142 void RecordUnPackMetrics(UnPackStatus unpack_status,
143 int32_t status, 143 int32_t status,
144 UnPackConsumer consumer); 144 UnPackConsumer consumer);
145 145
146 // Register Chrome's EventLog message provider dll.
147 void RegisterEventLogProvider(const base::FilePath& install_directory,
148 const base::Version& version);
149
150 // De-register Chrome's EventLog message provider dll.
151 void DeRegisterEventLogProvider();
152
146 // This class will enable the privilege defined by |privilege_name| on the 153 // This class will enable the privilege defined by |privilege_name| on the
147 // current process' token. The privilege will be disabled upon the 154 // current process' token. The privilege will be disabled upon the
148 // ScopedTokenPrivilege's destruction (unless it was already enabled when the 155 // ScopedTokenPrivilege's destruction (unless it was already enabled when the
149 // ScopedTokenPrivilege object was constructed). 156 // ScopedTokenPrivilege object was constructed).
150 // Some privileges might require admin rights to be enabled (check is_enabled() 157 // Some privileges might require admin rights to be enabled (check is_enabled()
151 // to know whether |privilege_name| was successfully enabled). 158 // to know whether |privilege_name| was successfully enabled).
152 class ScopedTokenPrivilege { 159 class ScopedTokenPrivilege {
153 public: 160 public:
154 explicit ScopedTokenPrivilege(const wchar_t* privilege_name); 161 explicit ScopedTokenPrivilege(const wchar_t* privilege_name);
155 ~ScopedTokenPrivilege(); 162 ~ScopedTokenPrivilege();
(...skipping 12 matching lines...) Expand all
168 // The previous state of the privilege this object is responsible for. As set 175 // The previous state of the privilege this object is responsible for. As set
169 // by AdjustTokenPrivileges() upon construction. 176 // by AdjustTokenPrivileges() upon construction.
170 TOKEN_PRIVILEGES previous_privileges_; 177 TOKEN_PRIVILEGES previous_privileges_;
171 178
172 DISALLOW_IMPLICIT_CONSTRUCTORS(ScopedTokenPrivilege); 179 DISALLOW_IMPLICIT_CONSTRUCTORS(ScopedTokenPrivilege);
173 }; 180 };
174 181
175 } // namespace installer 182 } // namespace installer
176 183
177 #endif // CHROME_INSTALLER_SETUP_SETUP_UTIL_H_ 184 #endif // CHROME_INSTALLER_SETUP_SETUP_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698