| 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 // Small DLL shim to register and unregister all CEEE components. | 5 // Small DLL shim to register and unregister all CEEE components. |
| 6 | 6 |
| 7 #include "ceee/installer_dll/installer_helper.h" | 7 #include "ceee/installer_dll/installer_helper.h" |
| 8 | 8 |
| 9 #include "base/at_exit.h" | 9 #include "base/at_exit.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 HRESULT SetCeeeChannelModifier(bool new_value) { | 256 HRESULT SetCeeeChannelModifier(bool new_value) { |
| 257 std::wstring reg_key(ceee_module_util::GetCromeFrameClientStateKey()); | 257 std::wstring reg_key(ceee_module_util::GetCromeFrameClientStateKey()); |
| 258 | 258 |
| 259 base::win::RegKey key; | 259 base::win::RegKey key; |
| 260 if (!key.Open(HKEY_LOCAL_MACHINE, reg_key.c_str(), KEY_ALL_ACCESS)) { | 260 if (!key.Open(HKEY_LOCAL_MACHINE, reg_key.c_str(), KEY_ALL_ACCESS)) { |
| 261 // Omaha didn't install the key. Perhaps no Omaha? That's ok. | 261 // Omaha didn't install the key. Perhaps no Omaha? That's ok. |
| 262 return S_OK; | 262 return S_OK; |
| 263 } | 263 } |
| 264 | 264 |
| 265 // We create the "ap" value if it doesn't exist. | 265 // We create the "ap" value if it doesn't exist. |
| 266 installer::ChannelInfo channel_info; | 266 installer_util::ChannelInfo channel_info; |
| 267 channel_info.Initialize(key); | 267 channel_info.Initialize(key); |
| 268 | 268 |
| 269 if (channel_info.SetCeee(new_value) && !channel_info.Write(&key)) { | 269 if (channel_info.SetCeee(new_value) && !channel_info.Write(&key)) { |
| 270 return E_FAIL; | 270 return E_FAIL; |
| 271 } | 271 } |
| 272 | 272 |
| 273 // Everything we need is already done! | 273 // Everything we need is already done! |
| 274 return S_OK; | 274 return S_OK; |
| 275 } | 275 } |
| 276 | 276 |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 396 LOG(WARNING) << "Call to unimplemented DllRegisterUserServer."; | 396 LOG(WARNING) << "Call to unimplemented DllRegisterUserServer."; |
| 397 return S_OK; | 397 return S_OK; |
| 398 } | 398 } |
| 399 | 399 |
| 400 // No-op entry point to keep user-level unregistration happy. | 400 // No-op entry point to keep user-level unregistration happy. |
| 401 // TODO(robertshield): Remove this as part of registration re-org. | 401 // TODO(robertshield): Remove this as part of registration re-org. |
| 402 STDAPI DllUnregisterUserServer() { | 402 STDAPI DllUnregisterUserServer() { |
| 403 LOG(WARNING) << "Call to unimplemented DllUnregisterUserServer."; | 403 LOG(WARNING) << "Call to unimplemented DllUnregisterUserServer."; |
| 404 return S_OK; | 404 return S_OK; |
| 405 } | 405 } |
| OLD | NEW |