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

Side by Side Diff: chrome/browser/component_updater/cld_component_installer.cc

Issue 1740333002: Allow fallback from https to http for component update checks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 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/cld_component_installer.h" 5 #include "chrome/browser/component_updater/cld_component_installer.h"
6 6
7 #include <string> 7 #include <string>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 49
50 const char kCldManifestName[] = "CLD2 Data"; 50 const char kCldManifestName[] = "CLD2 Data";
51 51
52 CldComponentInstallerTraits::CldComponentInstallerTraits() { 52 CldComponentInstallerTraits::CldComponentInstallerTraits() {
53 } 53 }
54 54
55 bool CldComponentInstallerTraits::CanAutoUpdate() const { 55 bool CldComponentInstallerTraits::CanAutoUpdate() const {
56 return true; 56 return true;
57 } 57 }
58 58
59 bool CldComponentInstallerTraits::RequiresNetworkEncryption() const {
60 return false;
61 }
62
59 bool CldComponentInstallerTraits::OnCustomInstall( 63 bool CldComponentInstallerTraits::OnCustomInstall(
60 const base::DictionaryValue& manifest, 64 const base::DictionaryValue& manifest,
61 const base::FilePath& install_dir) { 65 const base::FilePath& install_dir) {
62 return true; // Nothing custom here. 66 return true; // Nothing custom here.
63 } 67 }
64 68
65 base::FilePath CldComponentInstallerTraits::GetInstalledPath( 69 base::FilePath CldComponentInstallerTraits::GetInstalledPath(
66 const base::FilePath& base) { 70 const base::FilePath& base) {
67 // Currently, all platforms have the file at the same location because there 71 // Currently, all platforms have the file at the same location because there
68 // is no binary difference in the generated file on any supported platform. 72 // is no binary difference in the generated file on any supported platform.
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 VLOG(1) << "Setting CLD data file location: " << path.value(); 138 VLOG(1) << "Setting CLD data file location: " << path.value();
135 g_latest_cld_data_file.Get() = path; 139 g_latest_cld_data_file.Get() = path;
136 translate::CldDataSource::Get()->SetCldDataFilePath(path); 140 translate::CldDataSource::Get()->SetCldDataFilePath(path);
137 } 141 }
138 142
139 base::FilePath CldComponentInstallerTraits::GetLatestCldDataFile() { 143 base::FilePath CldComponentInstallerTraits::GetLatestCldDataFile() {
140 return g_latest_cld_data_file.Get(); 144 return g_latest_cld_data_file.Get();
141 } 145 }
142 146
143 } // namespace component_updater 147 } // namespace component_updater
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698