summaryrefslogtreecommitdiffstats
path: root/chrome/browser/password_manager
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-30 19:28:44 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-30 19:28:44 +0000
commit528c56de01bbbd38788ed6cf8d2eea4c56cbe19e (patch)
treeac4f7a001affd772c4ab89701d3d46109b5f9e19 /chrome/browser/password_manager
parent5c86ada8d84f6e67d17b027d347052ef451241c4 (diff)
downloadchromium_src-528c56de01bbbd38788ed6cf8d2eea4c56cbe19e.zip
chromium_src-528c56de01bbbd38788ed6cf8d2eea4c56cbe19e.tar.gz
chromium_src-528c56de01bbbd38788ed6cf8d2eea4c56cbe19e.tar.bz2
Move the number conversions from string_util to a new file.
Use the base namespace in the new file. Update callers. I removed all wstring variants and also the string->number ones that ignore the return value. That encourages people to write code and forget about error handling. TEST=included unit tests BUG=none Review URL: http://codereview.chromium.org/3056029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54355 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/password_manager')
-rw-r--r--chrome/browser/password_manager/login_database_unittest.cc5
-rw-r--r--chrome/browser/password_manager/native_backend_gnome_x.cc3
2 files changed, 5 insertions, 3 deletions
diff --git a/chrome/browser/password_manager/login_database_unittest.cc b/chrome/browser/password_manager/login_database_unittest.cc
index e650042..2d8a061 100644
--- a/chrome/browser/password_manager/login_database_unittest.cc
+++ b/chrome/browser/password_manager/login_database_unittest.cc
@@ -7,7 +7,8 @@
#include "base/basictypes.h"
#include "base/file_util.h"
#include "base/path_service.h"
-#include "base/string_util.h"
+#include "base/string_number_conversions.h"
+#include "base/string_util.h" // TODO(brettw) remove when ASCIIToUTF16 moves.
#include "base/time.h"
#include "chrome/browser/password_manager/login_database.h"
#include "chrome/common/chrome_paths.h"
@@ -21,7 +22,7 @@ class LoginDatabaseTest : public testing::Test {
PathService::Get(chrome::DIR_TEST_DATA, &file_);
const std::string test_db =
"TestMetadataStoreMacDatabase" +
- Int64ToString(base::Time::Now().ToInternalValue()) + ".db";
+ base::Int64ToString(base::Time::Now().ToInternalValue()) + ".db";
file_ = file_.AppendASCII(test_db);
file_util::Delete(file_, false);
}
diff --git a/chrome/browser/password_manager/native_backend_gnome_x.cc b/chrome/browser/password_manager/native_backend_gnome_x.cc
index 667611e..aeaf40d 100644
--- a/chrome/browser/password_manager/native_backend_gnome_x.cc
+++ b/chrome/browser/password_manager/native_backend_gnome_x.cc
@@ -13,6 +13,7 @@
#include <vector>
#include "base/logging.h"
+#include "base/string_number_conversions.h"
#include "base/string_util.h"
#include "base/time.h"
#include "base/utf_string_conversions.h"
@@ -321,7 +322,7 @@ void GKRMethod::AddLogin(const PasswordForm& form) {
"signon_realm", form.signon_realm.c_str(),
"ssl_valid", form.ssl_valid,
"preferred", form.preferred,
- "date_created", Int64ToString(form.date_created.ToTimeT()).c_str(),
+ "date_created", base::Int64ToString(form.date_created.ToTimeT()).c_str(),
"blacklisted_by_user", form.blacklisted_by_user,
"scheme", form.scheme,
"application", GNOME_KEYRING_APPLICATION_CHROME,