0
Commit Graph

24 Commits

Author SHA1 Message Date
tc@google.com
6dce8adece Remove the locale parameter from the StringToDouble and
DoubleToString methods and only leave the
locale independent methods.  It turns out this code is
only used in the json code and if people want locale
formatting, they should use ICU.

Review URL: http://codereview.chromium.org/11423


git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5585 0039d316-1c4b-4281-b951-d872f2087c98
2008-11-18 00:14:28 +00:00
tony@chromium.org
f126fb9075 Fix the mac build to add dmg_fp to the libbase.a.
Remove third_party/dmg_fp complete since nothing else depends on it.

Review URL: http://codereview.chromium.org/10963


git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5525 0039d316-1c4b-4281-b951-d872f2087c98
2008-11-15 01:40:31 +00:00
tc@google.com
1fbb43878f fix bug in locale dependence check
this caused us to always go down the language independent path

Review URL: http://codereview.chromium.org/10713


git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5479 0039d316-1c4b-4281-b951-d872f2087c98
2008-11-14 16:59:20 +00:00
tc@google.com
4f2ad3f5ab Make unit_tests pass with pt_BR.UTF-8 locale.
BUG=3675

Patch from Paweł Hajdan jr <phajdan.jr@gmail.com>
original issue: http://codereview.chromium.org/9509

Review URL: http://codereview.chromium.org/11002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5319 0039d316-1c4b-4281-b951-d872f2087c98
2008-11-12 23:19:30 +00:00
jcampan@chromium.org
89ac46c97e This CL adds the autofill UI in forms.
When the user types text in a text field in a form, the renderer queries the browser for suggestion based on the entered text and displays the suggestions in a popup.

Listeners are set on the form text field in a similar fashion than for password save.

The popup showing the suggestion uses the same mechanism as the select popup. Note that a difference between the select and the autofill popup is that the autofill should not take focus, so the page still has focus and the user can still type in while it shows.
The creation of the render widget was modified for that purpose so we can specify the popup should not be focused when shown.
Review URL: http://codereview.chromium.org/8885

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4804 0039d316-1c4b-4281-b951-d872f2087c98
2008-11-05 19:28:08 +00:00
jcampan@chromium.org
9ccbb370aa This CL adds prompting for dangerous types of files (executable) when they are automatically downloaded.
The file is saved with a temporary name (dangerous_download_xxxx.download) in the download directory and the user is presented (in the download shelf and the download tab if opened) with a warning message and buttons to save/discard the download.
If discarded the download is removed (and its file deleted).
If saved, download goes as usual.
Dangerous downloads not confirmed by the user are deleted on shutdown.

TEST=Download a small exe file, try using the save/discard button from the download shelf and from the download tab (the intent is that the file has been entirely downloaded by the time you take action). Try again with a slow/big download (that time the download is expected not to be finished when approved/discarded).


Review URL: http://codereview.chromium.org/6043

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3228 0039d316-1c4b-4281-b951-d872f2087c98
2008-10-10 18:50:32 +00:00
jungshik@google.com
c9ec45429c Add UTF-8 check for JSON deserializer.
Add tests for IsStringUTF8
Make IsStringUTF8 accept std::string/std::wstring rather than char*/wchar_t*



Review URL: http://codereview.chromium.org/4268

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2610 0039d316-1c4b-4281-b951-d872f2087c98
2008-09-25 21:42:00 +00:00
mmentovai@google.com
7459794d5e Use COMPILE_ASSERT instead of DCHECK for compile-time constant checks
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1418 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-27 01:44:26 +00:00
license.bot
bf09a5036c Use a more compact license header in source files.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-24 00:55:55 +00:00
dkegel@google.com
8c026e7a5a crosstool's gcc gives lots of warnings like
"warning: suggest parentheses around && within ||"
For base/string_util.cc, just add the suggested parentheses.


git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1175 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-21 20:29:49 +00:00
evanm@google.com
48617e8037 Fix some more warnings.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1130 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-20 23:41:20 +00:00
mmentovai@google.com
44cd16fcc8 DCHECK vswprintf format string cross-platform portability. Use %ls, not %s, for wchar_t* fields.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@849 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-14 01:25:32 +00:00
deanm@google.com
954d58c4d2 Implement an interface compatible wcslcpy and strlcpy. Possibly slightly
slower than the OpenBSD implementation, but a bit clearer and fits our style.

Move file_util_posix to use it now that we have it everywhere.



git-svn-id: svn://svn.chromium.org/chrome/trunk/src@798 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-13 14:33:40 +00:00
deanm@google.com
21d610fb26 Implement IntToString-type methods without using a format string. I'm not sure if this will actually be more efficient. Also will make Int64ToString work on other platforms, since the old code used msvc-only %I64. Added a bunch of methods to have the whole Int/Int64 String/WString suite.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@784 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-13 11:09:33 +00:00
mmentovai@google.com
703f427ed4 Fix string_util and its tests for the Mac, GCC, UTF-32 wchar_t platforms, and POSIX systems generally.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@771 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-13 01:17:18 +00:00
mmentovai@google.com
604a7bee4d Back out r736 due to breakage
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@738 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-12 19:23:14 +00:00
mmentovai@google.com
6063202355 Fix string_util and its tests for the Mac, GCC, UTF-32 wchar_t platforms, and POSIX systems generally.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@736 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-12 18:48:58 +00:00
mmentovai@google.com
169da8f5bb Fix ToUnsigned for 4-byte wchar_t platforms.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@712 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-12 15:06:52 +00:00
evanm@google.com
a191e01106 Rename and remove a bunch of string functions.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@527 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-07 19:26:37 +00:00
mmentovai@google.com
d9023abb77 Cross-platform portability fixes for JSONReader. Adds generic string-to-double parsing and tests in string_util.
There is one behavior change here: numbers which "look" like integers by virtue of being free of '.', 'e', and 'E' are no longer rejected if they're not within the [INT_MIN .. INT_MAX] range.  Instead, they'll be parsed and stored internally as doubles.

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@519 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-07 17:15:41 +00:00
mmentovai@google.com
a218f15b20 Allow string-to-int conversions to provide a return value indicating success. Implement them consistently on all platforms. Fill in a couple of necessary missing pieces. Eliminate the need for many uses of sscanf. Add tests.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@405 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-05 22:46:15 +00:00
brettw@google.com
856080bd99 Revert my UTF change until we can figure out what to do with the sandbox.
BUG=1201008

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@215 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-01 00:49:29 +00:00
brettw@google.com
656e3b3857 Write our own utf8<->wide conversion functions. This gives us more control over error handling instead of getting a blank string for invalid encodings. It also allows us to decrease the amount of platform-specific code.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@211 0039d316-1c4b-4281-b951-d872f2087c98
2008-08-01 00:13:10 +00:00
initial.commit
d7cae12696 Add base to the repository.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8 0039d316-1c4b-4281-b951-d872f2087c98
2008-07-26 21:49:38 +00:00