summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxhwang@chromium.org <xhwang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-22 07:35:50 +0000
committerxhwang@chromium.org <xhwang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-22 07:35:50 +0000
commit1f04ef4db936365c0cc1990f1a2b8a7bbbe37653 (patch)
tree571f9feea8ed976c01a7bd1cf56cee9894d5c005
parent9246e364afd394dd3a7cc2bf838c7ea0b4fc1133 (diff)
downloadchromium_src-1f04ef4db936365c0cc1990f1a2b8a7bbbe37653.zip
chromium_src-1f04ef4db936365c0cc1990f1a2b8a7bbbe37653.tar.gz
chromium_src-1f04ef4db936365c0cc1990f1a2b8a7bbbe37653.tar.bz2
Move Version to base namespace.
Adds "using base::Version" to the header to avoid having to update everything at once. All forward declares and the locations where the forward declares are used are updated. Review URL: https://chromiumcodereview.appspot.com/14099010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@195456 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--base/version.cc14
-rw-r--r--base/version.h8
-rw-r--r--chrome/browser/component_updater/flash_component_installer.h4
-rw-r--r--chrome/browser/component_updater/pnacl/pnacl_component_installer.h10
-rw-r--r--chrome/browser/extensions/api/runtime/runtime_api.h5
-rw-r--r--chrome/browser/extensions/extension_service.h4
-rw-r--r--chrome/browser/extensions/external_provider_impl.h9
-rw-r--r--chrome/browser/extensions/external_provider_interface.h11
-rw-r--r--chrome/browser/extensions/pending_extension_manager.h7
-rw-r--r--chrome/browser/extensions/updater/extension_downloader.h8
-rw-r--r--chrome/common/extensions/extension.h6
-rw-r--r--chrome/installer/setup/install_worker.h26
-rw-r--r--chrome/installer/setup/setup_util.h4
-rw-r--r--chrome/installer/test/alternate_version_generator.h5
-rw-r--r--chrome/installer/util/install_util.h9
-rw-r--r--chrome/installer/util/installation_state.h7
-rw-r--r--chrome/installer/util/installer_state.h17
-rw-r--r--chrome_frame/dll_redirector.h11
-rw-r--r--webkit/plugins/npapi/plugin_utils.h6
19 files changed, 98 insertions, 73 deletions
diff --git a/base/version.cc b/base/version.cc
index f758733..eb1806e 100644
--- a/base/version.cc
+++ b/base/version.cc
@@ -11,6 +11,8 @@
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
+namespace base {
+
namespace {
// Parses the |numbers| vector representing the different numbers
@@ -21,14 +23,14 @@ namespace {
bool ParseVersionNumbers(const std::string& version_str,
std::vector<uint16>* parsed) {
std::vector<std::string> numbers;
- base::SplitString(version_str, '.', &numbers);
+ SplitString(version_str, '.', &numbers);
if (numbers.empty())
return false;
for (std::vector<std::string>::const_iterator it = numbers.begin();
it != numbers.end(); ++it) {
int num;
- if (!base::StringToInt(*it, &num))
+ if (!StringToInt(*it, &num))
return false;
if (num < 0)
@@ -39,7 +41,7 @@ bool ParseVersionNumbers(const std::string& version_str,
return false;
// This throws out things like +3, or 032.
- if (base::IntToString(num) != *it)
+ if (IntToString(num) != *it)
return false;
parsed->push_back(static_cast<uint16>(num));
@@ -164,9 +166,11 @@ const std::string Version::GetString() const {
std::string version_str;
size_t count = components_.size();
for (size_t i = 0; i < count - 1; ++i) {
- version_str.append(base::IntToString(components_[i]));
+ version_str.append(IntToString(components_[i]));
version_str.append(".");
}
- version_str.append(base::IntToString(components_[count - 1]));
+ version_str.append(IntToString(components_[count - 1]));
return version_str;
}
+
+} // namespace base
diff --git a/base/version.h b/base/version.h
index ab7145e..b3012eb 100644
--- a/base/version.h
+++ b/base/version.h
@@ -11,6 +11,8 @@
#include "base/base_export.h"
#include "base/basictypes.h"
+namespace base {
+
// Version represents a dotted version number, like "1.2.3.4", supporting
// parsing and comparison.
class BASE_EXPORT Version {
@@ -61,4 +63,10 @@ class BASE_EXPORT Version {
std::vector<uint16> components_;
};
+} // namespace base
+
+// TODO(xhwang) remove this when all users are updated to explicitly use the
+// namespace
+using base::Version;
+
#endif // BASE_VERSION_H_
diff --git a/chrome/browser/component_updater/flash_component_installer.h b/chrome/browser/component_updater/flash_component_installer.h
index 45fe22f..aef90a6 100644
--- a/chrome/browser/component_updater/flash_component_installer.h
+++ b/chrome/browser/component_updater/flash_component_installer.h
@@ -6,10 +6,10 @@
#define CHROME_BROWSER_COMPONENT_UPDATER_FLASH_COMPONENT_INSTALLER_H_
class ComponentUpdateService;
-class Version;
namespace base {
class DictionaryValue;
+class Version;
}
// Our job is to 1) find what Pepper flash is installed (if any) and 2) register
@@ -20,6 +20,6 @@ void RegisterPepperFlashComponent(ComponentUpdateService* cus);
// Returns true if this browser is compatible with the given Pepper Flash
// manifest, with the version specified in the manifest in |version_out|.
bool CheckPepperFlashManifest(base::DictionaryValue* manifest,
- Version* version_out);
+ base::Version* version_out);
#endif // CHROME_BROWSER_COMPONENT_UPDATER_FLASH_COMPONENT_INSTALLER_H_
diff --git a/chrome/browser/component_updater/pnacl/pnacl_component_installer.h b/chrome/browser/component_updater/pnacl/pnacl_component_installer.h
index 5d58402..fd143ba 100644
--- a/chrome/browser/component_updater/pnacl/pnacl_component_installer.h
+++ b/chrome/browser/component_updater/pnacl/pnacl_component_installer.h
@@ -7,11 +7,11 @@
#include "base/files/file_path.h"
#include "base/memory/scoped_ptr.h"
+#include "base/version.h"
#include "chrome/browser/component_updater/component_updater_service.h"
#include "chrome/browser/component_updater/pnacl/pnacl_profile_observer.h"
class CommandLine;
-class Version;
namespace base {
class DictionaryValue;
@@ -47,9 +47,9 @@ class PnaclComponentInstaller : public ComponentInstaller {
// Determine the base directory for storing each version of PNaCl.
base::FilePath GetPnaclBaseDirectory();
- Version current_version() const { return current_version_; }
+ base::Version current_version() const { return current_version_; }
- void set_current_version(const Version& v) { current_version_ = v; }
+ void set_current_version(const base::Version& v) { current_version_ = v; }
ComponentUpdateService* cus() const { return cus_; }
@@ -57,7 +57,7 @@ class PnaclComponentInstaller : public ComponentInstaller {
bool per_user_;
scoped_ptr<PnaclProfileObserver> profile_observer_;
base::FilePath current_profile_path_;
- Version current_version_;
+ base::Version current_version_;
ComponentUpdateService* cus_;
DISALLOW_COPY_AND_ASSIGN(PnaclComponentInstaller);
};
@@ -65,6 +65,6 @@ class PnaclComponentInstaller : public ComponentInstaller {
// Returns true if this browser is compatible with the given Pnacl component
// manifest, with the version specified in the manifest in |version_out|.
bool CheckPnaclComponentManifest(base::DictionaryValue* manifest,
- Version* version_out);
+ base::Version* version_out);
#endif // CHROME_BROWSER_COMPONENT_UPDATER_PNACL_PNACL_COMPONENT_INSTALLER_H_
diff --git a/chrome/browser/extensions/api/runtime/runtime_api.h b/chrome/browser/extensions/api/runtime/runtime_api.h
index a9fedc8..97bc65de 100644
--- a/chrome/browser/extensions/api/runtime/runtime_api.h
+++ b/chrome/browser/extensions/api/runtime/runtime_api.h
@@ -10,7 +10,10 @@
#include "content/public/browser/notification_registrar.h"
class Profile;
+
+namespace base {
class Version;
+}
namespace extensions {
class Extension;
@@ -25,7 +28,7 @@ class RuntimeEventRouter {
// Dispatches the onInstalled event to the given extension.
static void DispatchOnInstalledEvent(Profile* profile,
const std::string& extension_id,
- const Version& old_version,
+ const base::Version& old_version,
bool chrome_updated);
// Dispatches the onUpdateAvailable event to the given extension.
diff --git a/chrome/browser/extensions/extension_service.h b/chrome/browser/extensions/extension_service.h
index 4fe8020..ea0e814 100644
--- a/chrome/browser/extensions/extension_service.h
+++ b/chrome/browser/extensions/extension_service.h
@@ -48,10 +48,10 @@ class ExtensionSyncData;
class ExtensionToolbarModel;
class GURL;
class Profile;
-class Version;
namespace base {
class SequencedTaskRunner;
+class Version;
}
namespace extensions {
@@ -573,7 +573,7 @@ class ExtensionService
// ExternalProvider::Visitor implementation.
virtual bool OnExternalExtensionFileFound(
const std::string& id,
- const Version* version,
+ const base::Version* version,
const base::FilePath& path,
extensions::Manifest::Location location,
int creation_flags,
diff --git a/chrome/browser/extensions/external_provider_impl.h b/chrome/browser/extensions/external_provider_impl.h
index 32d3763..6c31b90 100644
--- a/chrome/browser/extensions/external_provider_impl.h
+++ b/chrome/browser/extensions/external_provider_impl.h
@@ -14,10 +14,10 @@
#include "chrome/common/extensions/manifest.h"
class Profile;
-class Version;
namespace base {
class DictionaryValue;
+class Version;
}
namespace extensions {
@@ -58,9 +58,10 @@ class ExternalProviderImpl : public ExternalProviderInterface {
virtual void ServiceShutdown() OVERRIDE;
virtual void VisitRegisteredExtension() OVERRIDE;
virtual bool HasExtension(const std::string& id) const OVERRIDE;
- virtual bool GetExtensionDetails(const std::string& id,
- Manifest::Location* location,
- scoped_ptr<Version>* version) const OVERRIDE;
+ virtual bool GetExtensionDetails(
+ const std::string& id,
+ Manifest::Location* location,
+ scoped_ptr<base::Version>* version) const OVERRIDE;
virtual bool IsReady() const OVERRIDE;
diff --git a/chrome/browser/extensions/external_provider_interface.h b/chrome/browser/extensions/external_provider_interface.h
index 2017386..d82e0b1 100644
--- a/chrome/browser/extensions/external_provider_interface.h
+++ b/chrome/browser/extensions/external_provider_interface.h
@@ -11,10 +11,10 @@
#include "chrome/common/extensions/manifest.h"
class GURL;
-class Version;
namespace base {
class FilePath;
+class Version;
}
namespace extensions {
@@ -35,7 +35,7 @@ class ExternalProviderInterface {
// location.
virtual bool OnExternalExtensionFileFound(
const std::string& id,
- const Version* version,
+ const base::Version* version,
const base::FilePath& path,
Manifest::Location location,
int creation_flags,
@@ -78,9 +78,10 @@ class ExternalProviderInterface {
// if they are not NULL. If an output parameter is not specified by the
// provider type, it will not be changed.
// This function is no longer used outside unit tests.
- virtual bool GetExtensionDetails(const std::string& id,
- Manifest::Location* location,
- scoped_ptr<Version>* version) const = 0;
+ virtual bool GetExtensionDetails(
+ const std::string& id,
+ Manifest::Location* location,
+ scoped_ptr<base::Version>* version) const = 0;
// Determines if this provider had loaded the list of external extensions
// from its source.
diff --git a/chrome/browser/extensions/pending_extension_manager.h b/chrome/browser/extensions/pending_extension_manager.h
index df36d65..d275adf 100644
--- a/chrome/browser/extensions/pending_extension_manager.h
+++ b/chrome/browser/extensions/pending_extension_manager.h
@@ -15,7 +15,10 @@
class ExtensionServiceInterface;
class GURL;
class PendingExtensionManager;
+
+namespace base {
class Version;
+}
FORWARD_DECLARE_TEST(ExtensionServiceTest,
UpdatePendingExtensionAlreadyInstalled);
@@ -89,7 +92,7 @@ class PendingExtensionManager {
bool AddFromExternalFile(
const std::string& id,
Manifest::Location location,
- const Version& version);
+ const base::Version& version);
// Get the list of pending IDs that should be installed from an update URL.
// Pending extensions that will be installed from local files will not be
@@ -105,7 +108,7 @@ class PendingExtensionManager {
bool AddExtensionImpl(
const std::string& id,
const GURL& update_url,
- const Version& version,
+ const base::Version& version,
PendingExtensionInfo::ShouldAllowInstallPredicate should_allow_install,
bool is_from_sync,
bool install_silently,
diff --git a/chrome/browser/extensions/updater/extension_downloader.h b/chrome/browser/extensions/updater/extension_downloader.h
index 302a74b..29c2fc5 100644
--- a/chrome/browser/extensions/updater/extension_downloader.h
+++ b/chrome/browser/extensions/updater/extension_downloader.h
@@ -26,8 +26,6 @@
#include "googleurl/src/gurl.h"
#include "net/url_request/url_fetcher_delegate.h"
-class Version;
-
namespace net {
class URLFetcher;
class URLRequestContextGetter;
@@ -37,11 +35,11 @@ class URLRequestStatus;
namespace extensions {
struct UpdateDetails {
- UpdateDetails(const std::string& id, const Version& version);
+ UpdateDetails(const std::string& id, const base::Version& version);
~UpdateDetails();
std::string id;
- Version version;
+ base::Version version;
};
class ExtensionUpdaterTest;
@@ -134,7 +132,7 @@ class ExtensionDownloader : public net::URLFetcherDelegate {
// Helper for AddExtension() and AddPendingExtension().
bool AddExtensionData(const std::string& id,
- const Version& version,
+ const base::Version& version,
Manifest::Type extension_type,
const GURL& extension_update_url,
const std::string& update_url_data,
diff --git a/chrome/common/extensions/extension.h b/chrome/common/extensions/extension.h
index d24e2ab..10b1430 100644
--- a/chrome/common/extensions/extension.h
+++ b/chrome/common/extensions/extension.h
@@ -35,11 +35,11 @@
class ExtensionAction;
class SkBitmap;
-class Version;
namespace base {
class DictionaryValue;
class ListValue;
+class Version;
}
namespace gfx {
@@ -393,7 +393,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> {
const GURL& url() const { return extension_url_; }
Manifest::Location location() const;
const std::string& id() const;
- const Version* version() const { return version_.get(); }
+ const base::Version* version() const { return version_.get(); }
const std::string VersionString() const;
const std::string& name() const { return name_; }
const std::string& non_localized_name() const { return non_localized_name_; }
@@ -611,7 +611,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> {
GURL extension_url_;
// The extension's version.
- scoped_ptr<Version> version_;
+ scoped_ptr<base::Version> version_;
// An optional longer description of the extension.
std::string description_;
diff --git a/chrome/installer/setup/install_worker.h b/chrome/installer/setup/install_worker.h
index b4497c7..8f2edb0 100644
--- a/chrome/installer/setup/install_worker.h
+++ b/chrome/installer/setup/install_worker.h
@@ -14,11 +14,11 @@
class BrowserDistribution;
class CommandLine;
-class Version;
class WorkItemList;
namespace base {
class FilePath;
+class Version;
}
namespace installer {
@@ -32,7 +32,7 @@ class Product;
// state key if running under an MSI installer.
void AddUninstallShortcutWorkItems(const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* install_list);
@@ -41,7 +41,7 @@ void AddUninstallShortcutWorkItems(const InstallerState& installer_state,
// "lang" value is also set according to the currently selected translation.
void AddVersionKeyWorkItems(HKEY root,
BrowserDistribution* dist,
- const Version& new_version,
+ const base::Version& new_version,
bool add_language_identifier,
WorkItemList* list);
@@ -83,8 +83,8 @@ void AddUsageStatsWorkItems(const InstallationState& original_state,
// |current_version| can be NULL to indicate no Chrome is currently installed.
bool AppendPostInstallTasks(const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version* current_version,
- const Version& new_version,
+ const base::Version* current_version,
+ const base::Version& new_version,
const base::FilePath& temp_path,
WorkItemList* post_install_task_list);
@@ -106,8 +106,8 @@ void AddInstallWorkItems(const InstallationState& original_state,
const base::FilePath& archive_path,
const base::FilePath& src_path,
const base::FilePath& temp_path,
- const Version* current_version,
- const Version& new_version,
+ const base::Version* current_version,
+ const base::Version& new_version,
WorkItemList* install_list);
// Appends registration or unregistration work items to |work_item_list| for the
@@ -137,7 +137,7 @@ void AddSetMsiMarkerWorkItem(const InstallerState& installer_state,
void AddChromeFrameWorkItems(const InstallationState& original_state,
const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* list);
@@ -147,7 +147,7 @@ void AddChromeFrameWorkItems(const InstallationState& original_state,
// delegate_execute.exe directly in |target_path|.
void AddDelegateExecuteWorkItems(const InstallerState& installer_state,
const base::FilePath& target_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* list);
@@ -158,7 +158,7 @@ void AddDelegateExecuteWorkItems(const InstallerState& installer_state,
// anything other than system-level Chrome/Chromium.
void AddActiveSetupWorkItems(const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* list);
@@ -186,7 +186,7 @@ void RefreshElevationPolicy();
// currently being installed -- can be empty on uninstall.
void AddOsUpgradeWorkItems(const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* install_list);
@@ -196,7 +196,7 @@ void AddOsUpgradeWorkItems(const InstallerState& installer_state,
// currently being installed -- can be empty on uninstall.
void AddQueryEULAAcceptanceWorkItems(const InstallerState& installer_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
const Product& product,
WorkItemList* work_item_list);
@@ -210,7 +210,7 @@ void AddQueryEULAAcceptanceWorkItems(const InstallerState& installer_state,
void AddQuickEnableChromeFrameWorkItems(const InstallerState& installer_state,
const InstallationState& machine_state,
const base::FilePath& setup_path,
- const Version& new_version,
+ const base::Version& new_version,
WorkItemList* work_item_list);
} // namespace installer
diff --git a/chrome/installer/setup/setup_util.h b/chrome/installer/setup/setup_util.h
index 1d817ce..cfd993f 100644
--- a/chrome/installer/setup/setup_util.h
+++ b/chrome/installer/setup/setup_util.h
@@ -16,10 +16,10 @@
#include "chrome/installer/util/util_constants.h"
class CommandLine;
-class Version;
namespace base {
class FilePath;
+class Version;
}
namespace installer {
@@ -57,7 +57,7 @@ bool DeleteFileFromTempProcess(const base::FilePath& path,
// (|installer_version|).
bool GetExistingHigherInstaller(const InstallationState& original_state,
bool system_install,
- const Version& installer_version,
+ const base::Version& installer_version,
base::FilePath* setup_exe);
// Invokes the pre-existing |setup_exe| to handle the current operation (as
diff --git a/chrome/installer/test/alternate_version_generator.h b/chrome/installer/test/alternate_version_generator.h
index fe60a6a..b75b381 100644
--- a/chrome/installer/test/alternate_version_generator.h
+++ b/chrome/installer/test/alternate_version_generator.h
@@ -9,10 +9,9 @@
#include <string>
-class Version;
-
namespace base {
class FilePath;
+class Version;
}
namespace upgrade_test {
@@ -48,7 +47,7 @@ bool GenerateAlternatePEFileVersion(const base::FilePath& original_file,
// Note that |target_file| may still be mutated on failure.
bool GenerateSpecificPEFileVersion(const base::FilePath& original_file,
const base::FilePath& target_file,
- const Version& version);
+ const base::Version& version);
} // namespace upgrade_test
diff --git a/chrome/installer/util/install_util.h b/chrome/installer/util/install_util.h
index 55071fc..0c1a253 100644
--- a/chrome/installer/util/install_util.h
+++ b/chrome/installer/util/install_util.h
@@ -20,9 +20,12 @@
#include "chrome/installer/util/browser_distribution.h"
#include "chrome/installer/util/util_constants.h"
-class Version;
class WorkItemList;
+namespace base {
+class Version;
+}
+
// This is a utility class that provides common installation related
// utility methods that can be used by installer and also unit tested
// independently.
@@ -53,7 +56,7 @@ class InstallUtil {
// otherwise looks under the HKCU.
static void GetChromeVersion(BrowserDistribution* dist,
bool system_install,
- Version* version);
+ base::Version* version);
// Find the last critical update (version) of Chrome. Fills |version| with the
// version or a default-constructed Version if no version is found. A critical
@@ -63,7 +66,7 @@ class InstallUtil {
// otherwise looks under the HKCU.
static void GetCriticalUpdateVersion(BrowserDistribution* dist,
bool system_install,
- Version* version);
+ base::Version* version);
// This function checks if the current OS is supported for Chromium.
static bool IsOSSupported();
diff --git a/chrome/installer/util/installation_state.h b/chrome/installer/util/installation_state.h
index 30097d5..153760d2 100644
--- a/chrome/installer/util/installation_state.h
+++ b/chrome/installer/util/installation_state.h
@@ -15,9 +15,8 @@
#include "chrome/installer/util/browser_distribution.h"
#include "chrome/installer/util/channel_info.h"
-class Version;
-
namespace base {
+class Version;
namespace win {
class RegKey;
}
@@ -49,12 +48,12 @@ class ProductState {
// Returns the product's version. This method may only be called on an
// instance that has been initialized for an installed product.
- const Version& version() const;
+ const base::Version& version() const;
// Returns the current version of the product if a new version is awaiting
// update; may be NULL. Ownership of a returned value is not passed to the
// caller.
- const Version* old_version() const { return old_version_.get(); }
+ const base::Version* old_version() const { return old_version_.get(); }
// Returns the brand code the product is currently installed with.
const std::wstring& brand() const { return brand_; }
diff --git a/chrome/installer/util/installer_state.h b/chrome/installer/util/installer_state.h
index 47df2b4..46f5b5d 100644
--- a/chrome/installer/util/installer_state.h
+++ b/chrome/installer/util/installer_state.h
@@ -24,7 +24,6 @@
#endif
class CommandLine;
-class Version;
namespace installer {
@@ -155,15 +154,17 @@ class InstallerState {
// Returns the currently installed version in |target_path|, or NULL if no
// products are installed. Ownership is passed to the caller.
- Version* GetCurrentVersion(const InstallationState& machine_state) const;
+ base::Version* GetCurrentVersion(
+ const InstallationState& machine_state) const;
// Returns the critical update version if all of the following are true:
// * --critical-update-version=CUV was specified on the command-line.
// * current_version == NULL or current_version < CUV.
// * new_version >= CUV.
// Otherwise, returns an invalid version.
- Version DetermineCriticalVersion(const Version* current_version,
- const Version& new_version) const;
+ base::Version DetermineCriticalVersion(
+ const base::Version* current_version,
+ const base::Version& new_version) const;
// Returns whether or not there is currently a Chrome Frame instance running.
// Note that there isn't a mechanism to lock Chrome Frame in place, so Chrome
@@ -172,13 +173,13 @@ class InstallerState {
// Returns the path to the installer under Chrome version folder
// (for example <target_path>\Google\Chrome\Application\<Version>\Installer)
- base::FilePath GetInstallerDirectory(const Version& version) const;
+ base::FilePath GetInstallerDirectory(const base::Version& version) const;
// Try to delete all directories under |temp_path| whose versions are less
// than |new_version| and not equal to |existing_version|. |existing_version|
// may be NULL.
- void RemoveOldVersionDirectories(const Version& new_version,
- Version* existing_version,
+ void RemoveOldVersionDirectories(const base::Version& new_version,
+ base::Version* existing_version,
const base::FilePath& temp_path) const;
// Adds to |com_dll_list| the list of COM DLLs that are to be registered
@@ -243,7 +244,7 @@ class InstallerState {
BrowserDistribution::Type state_type_;
ScopedVector<Product> products_;
BrowserDistribution* multi_package_distribution_;
- Version critical_update_version_;
+ base::Version critical_update_version_;
Level level_;
PackageType package_type_;
#if defined(OS_WIN)
diff --git a/chrome_frame/dll_redirector.h b/chrome_frame/dll_redirector.h
index ee6d942..81c882b 100644
--- a/chrome_frame/dll_redirector.h
+++ b/chrome_frame/dll_redirector.h
@@ -18,7 +18,10 @@
namespace ATL {
class CSecurityAttributes;
}
+
+namespace base {
class Version;
+}
// A singleton class that provides a facility to register the version of the
// current module as the only version that should be loaded system-wide. If
@@ -69,14 +72,14 @@ class DllRedirector {
virtual HMODULE GetFirstModule();
// Returns the version of the current module or NULL if none can be found.
- // The caller must free the Version.
- virtual Version* GetCurrentModuleVersion();
+ // The caller must free the returned version.
+ virtual base::Version* GetCurrentModuleVersion();
// Attempt to load the specified version dll. Finds it by walking up one
// directory from our current module's location, then appending the newly
// found version number. The Version class in base will have ensured that we
// actually have a valid version and not e.g. ..\..\..\..\MyEvilFolder\.
- virtual HMODULE LoadVersionedModule(Version* version);
+ virtual HMODULE LoadVersionedModule(base::Version* version);
// Builds the necessary SECURITY_ATTRIBUTES to allow low integrity access
// to an object. Returns true on success, false otherwise.
@@ -91,7 +94,7 @@ class DllRedirector {
scoped_ptr<base::SharedMemory> shared_memory_;
// The current version of the DLL to be loaded.
- scoped_ptr<Version> dll_version_;
+ scoped_ptr<base::Version> dll_version_;
// The handle to the first version of this module that was loaded. This
// may refer to the current module, or another version of the same module
diff --git a/webkit/plugins/npapi/plugin_utils.h b/webkit/plugins/npapi/plugin_utils.h
index 438e879..8fe1b13 100644
--- a/webkit/plugins/npapi/plugin_utils.h
+++ b/webkit/plugins/npapi/plugin_utils.h
@@ -8,16 +8,18 @@
#include "base/string16.h"
#include "webkit/plugins/webkit_plugins_export.h"
+namespace base {
class Version;
+}
namespace webkit {
namespace npapi {
// Parse a version string as used by a plug-in. This method is more lenient
-// in accepting weird version strings than Version::GetFromString()
+// in accepting weird version strings than base::Version::GetFromString()
WEBKIT_PLUGINS_EXPORT void CreateVersionFromString(
const base::string16& version_string,
- Version* parsed_version);
+ base::Version* parsed_version);
// Returns true iff NPAPI plugins are supported on the current platform.
WEBKIT_PLUGINS_EXPORT bool NPAPIPluginsSupported();