| OLD | NEW |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2014 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/component_updater/sw_reporter_installer_win.h" | 5 #include "chrome/browser/component_updater/sw_reporter_installer_win.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 void ComponentReady( | 125 void ComponentReady( |
| 126 const base::Version& version, | 126 const base::Version& version, |
| 127 const base::FilePath& install_dir, | 127 const base::FilePath& install_dir, |
| 128 std::unique_ptr<base::DictionaryValue> manifest) override { | 128 std::unique_ptr<base::DictionaryValue> manifest) override { |
| 129 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); | 129 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); |
| 130 safe_browsing::RunSwReporter(install_dir.Append(kSwReporterExeName), | 130 safe_browsing::RunSwReporter(install_dir.Append(kSwReporterExeName), |
| 131 version, base::ThreadTaskRunnerHandle::Get(), | 131 version, base::ThreadTaskRunnerHandle::Get(), |
| 132 base::WorkerPool::GetTaskRunner(true)); | 132 base::WorkerPool::GetTaskRunner(true)); |
| 133 } | 133 } |
| 134 | 134 |
| 135 base::FilePath GetBaseDirectory() const override { return install_dir(); } | 135 std::string GetASCIIDirectoryName() const override { return "SwReporter"; } |
| 136 | 136 |
| 137 void GetHash(std::vector<uint8_t>* hash) const override { GetPkHash(hash); } | 137 void GetHash(std::vector<uint8_t>* hash) const override { GetPkHash(hash); } |
| 138 | 138 |
| 139 std::string GetName() const override { return "Software Reporter Tool"; } | 139 std::string GetName() const override { return "Software Reporter Tool"; } |
| 140 | 140 |
| 141 std::string GetAp() const override { return std::string(); } | 141 std::string GetAp() const override { return std::string(); } |
| 142 | 142 |
| 143 static base::FilePath install_dir() { | 143 static base::FilePath install_dir() { |
| 144 // The base directory on windows looks like: | 144 // The base directory on windows looks like: |
| 145 // <profile>\AppData\Local\Google\Chrome\User Data\SwReporter\. | 145 // <profile>\AppData\Local\Google\Chrome\User Data\SwReporter\. |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 } | 256 } |
| 257 | 257 |
| 258 void RegisterProfilePrefsForSwReporter( | 258 void RegisterProfilePrefsForSwReporter( |
| 259 user_prefs::PrefRegistrySyncable* registry) { | 259 user_prefs::PrefRegistrySyncable* registry) { |
| 260 registry->RegisterStringPref(prefs::kSwReporterPromptVersion, ""); | 260 registry->RegisterStringPref(prefs::kSwReporterPromptVersion, ""); |
| 261 | 261 |
| 262 registry->RegisterStringPref(prefs::kSwReporterPromptSeed, ""); | 262 registry->RegisterStringPref(prefs::kSwReporterPromptSeed, ""); |
| 263 } | 263 } |
| 264 | 264 |
| 265 } // namespace component_updater | 265 } // namespace component_updater |
| OLD | NEW |