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

Unified Diff: chrome/browser/component_updater/widevine_cdm_component_installer.cc

Issue 17556002: Implement GetInstalledFile() in WidevineCdmComponentInstaller. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/component_updater/widevine_cdm_component_installer.cc
diff --git a/chrome/browser/component_updater/widevine_cdm_component_installer.cc b/chrome/browser/component_updater/widevine_cdm_component_installer.cc
index 8bc3feff3eb36b62cbff0a79e7057ef370cc35b2..a9c084c27c50dc4877788227ce9f44406bb215cf 100644
--- a/chrome/browser/component_updater/widevine_cdm_component_installer.cc
+++ b/chrome/browser/component_updater/widevine_cdm_component_installer.cc
@@ -251,7 +251,17 @@ bool WidevineCdmComponentInstaller::Install(
bool WidevineCdmComponentInstaller::GetInstalledFile(
const std::string& file, base::FilePath* installed_file) {
- return false;
+ // Only the CDM is component-updated.
+ if (file != kWidevineCdmFileName)
+ return false;
+
+ if (current_version_.Equals(base::Version(kNullVersion)))
+ return false; // No CDM has been installed yet.
+
+ *installed_file =
+ GetWidevineCdmBaseDirectory().AppendASCII(current_version_.GetString())
+ .AppendASCII(kWidevineCdmFileName);
+ return true;
}
void FinishWidevineCdmUpdateRegistration(ComponentUpdateService* cus,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698