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

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

Issue 100543005: Update all users of base::Version to explicitly specify the namespace, and clean up the header. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: someday it will work Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/component_updater/pepper_flash_component_installer.cc
diff --git a/chrome/browser/component_updater/pepper_flash_component_installer.cc b/chrome/browser/component_updater/pepper_flash_component_installer.cc
index f91af27563d86dd50a2295673235bd8b9e6c2fb2..18b2095502fbffca7bebd9b5fa8c68e6bc53419d 100644
--- a/chrome/browser/component_updater/pepper_flash_component_installer.cc
+++ b/chrome/browser/component_updater/pepper_flash_component_installer.cc
@@ -96,7 +96,7 @@ base::FilePath GetPepperFlashBaseDirectory() {
// |latest_version| returns the corresponding version number. |older_dirs|
// returns directories of all older versions.
bool GetPepperFlashDirectory(base::FilePath* latest_dir,
- Version* latest_version,
+ base::Version* latest_version,
std::vector<base::FilePath>* older_dirs) {
base::FilePath base_dir = GetPepperFlashBaseDirectory();
bool found = false;
@@ -104,7 +104,7 @@ bool GetPepperFlashDirectory(base::FilePath* latest_dir,
file_enumerator(base_dir, false, base::FileEnumerator::DIRECTORIES);
for (base::FilePath path = file_enumerator.Next(); !path.value().empty();
path = file_enumerator.Next()) {
- Version version(path.BaseName().MaybeAsASCII());
+ base::Version version(path.BaseName().MaybeAsASCII());
if (!version.IsValid())
continue;
if (found) {
@@ -138,7 +138,7 @@ bool SupportsPepperInterface(const char* interface_name) {
}
bool MakePepperFlashPluginInfo(const base::FilePath& flash_path,
- const Version& flash_version,
+ const base::Version& flash_version,
bool out_of_process,
content::PepperPluginInfo* plugin_info) {
if (!flash_version.IsValid())
@@ -179,7 +179,7 @@ bool IsPepperFlash(const content::WebPluginInfo& plugin) {
}
void RegisterPepperFlashWithChrome(const base::FilePath& path,
- const Version& version) {
+ const base::Version& version) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
content::PepperPluginInfo plugin_info;
if (!MakePepperFlashPluginInfo(path, version, true, &plugin_info))
@@ -193,7 +193,7 @@ void RegisterPepperFlashWithChrome(const base::FilePath& path,
continue;
// Do it only if the version we're trying to register is newer.
- Version registered_version(UTF16ToUTF8(it->version));
+ base::Version registered_version(UTF16ToUTF8(it->version));
if (registered_version.IsValid() &&
version.CompareTo(registered_version) <= 0) {
return;
@@ -245,7 +245,7 @@ bool CheckPepperFlashInterfaces(const base::DictionaryValue& manifest) {
class PepperFlashComponentInstaller : public ComponentInstaller {
public:
- explicit PepperFlashComponentInstaller(const Version& version);
+ explicit PepperFlashComponentInstaller(const base::Version& version);
virtual ~PepperFlashComponentInstaller() {}
@@ -258,11 +258,11 @@ class PepperFlashComponentInstaller : public ComponentInstaller {
base::FilePath* installed_file) OVERRIDE;
private:
- Version current_version_;
+ base::Version current_version_;
};
PepperFlashComponentInstaller::PepperFlashComponentInstaller(
- const Version& version) : current_version_(version) {
+ const base::Version& version) : current_version_(version) {
DCHECK(version.IsValid());
}
@@ -273,7 +273,7 @@ void PepperFlashComponentInstaller::OnUpdateError(int error) {
bool PepperFlashComponentInstaller::Install(
const base::DictionaryValue& manifest,
const base::FilePath& unpack_path) {
- Version version;
+ base::Version version;
if (!CheckPepperFlashManifest(manifest, &version))
return false;
if (current_version_.CompareTo(version) > 0)
@@ -305,7 +305,7 @@ bool PepperFlashComponentInstaller::GetInstalledFile(
}
bool CheckPepperFlashManifest(const base::DictionaryValue& manifest,
- Version* version_out) {
+ base::Version* version_out) {
std::string name;
manifest.GetStringASCII("name", &name);
// TODO(viettrungluu): Support WinFlapper for now, while we change the format
@@ -316,7 +316,7 @@ bool CheckPepperFlashManifest(const base::DictionaryValue& manifest,
std::string proposed_version;
manifest.GetStringASCII("version", &proposed_version);
- Version version(proposed_version.c_str());
+ base::Version version(proposed_version.c_str());
if (!version.IsValid())
return false;
@@ -347,7 +347,7 @@ namespace {
#if defined(GOOGLE_CHROME_BUILD) && !defined(OS_LINUX)
void FinishPepperFlashUpdateRegistration(ComponentUpdateService* cus,
- const Version& version) {
+ const base::Version& version) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
CrxComponent pepflash;
pepflash.name = "pepper_flash";
@@ -369,7 +369,7 @@ void StartPepperFlashUpdateRegistration(ComponentUpdateService* cus) {
}
}
- Version version(kNullVersion);
+ base::Version version(kNullVersion);
std::vector<base::FilePath> older_dirs;
if (GetPepperFlashDirectory(&path, &version, &older_dirs)) {
path = path.Append(chrome::kPepperFlashPluginFilename);
@@ -378,7 +378,7 @@ void StartPepperFlashUpdateRegistration(ComponentUpdateService* cus) {
BrowserThread::UI, FROM_HERE,
base::Bind(&RegisterPepperFlashWithChrome, path, version));
} else {
- version = Version(kNullVersion);
+ version = base::Version(kNullVersion);
}
}

Powered by Google App Engine
This is Rietveld 408576698