summaryrefslogtreecommitdiffstats
path: root/base
Commit message (Collapse)AuthorAgeFilesLines
* Add defines for the size of wchar_t to build_config.h. Use this in places ↵brettw@google.com2008-08-0713-218/+210
| | | | | | | | | | where we currently have an OS-specific check. Remove all WIN32 ifdefs from base and replace them with proper defined(OS...). I also fixed random style bits when I encountered them. I made major style fixes to string16. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@524 0039d316-1c4b-4281-b951-d872f2087c98
* Cross-platform portability fixes for JSONReader. Adds generic ↵mmentovai@google.com2008-08-078-54/+214
| | | | | | | | 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
* Reapply 508 to determine if it was indeed the cause of the ↵maruel@google.com2008-08-072-15/+10
| | | | | | webkit-release-playback failure. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@518 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the old NativeMB functions from string util, and use the new ones in ↵brettw@google.com2008-08-075-184/+316
| | | | | | sys_strings.h. I also removed duplicated code from the sandbox that can now use this, and fixed one case in the bug reporter that should not have been using the native multibyte encoding. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@515 0039d316-1c4b-4281-b951-d872f2087c98
* Revert part of r508, it may have broken webkit-release-playback.deanm@google.com2008-08-072-10/+15
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@514 0039d316-1c4b-4281-b951-d872f2087c98
* Make base/SConstruct just like chrome/SConstruct for linux building.deanm@google.com2008-08-071-1/+38
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@513 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the old atomic operations interface.deanm@google.com2008-08-075-183/+0
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@511 0039d316-1c4b-4281-b951-d872f2087c98
* ICU isn't packaged on the Mac as it is on Windows.avi@google.com2008-08-071-1/+12
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1092 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@509 0039d316-1c4b-4281-b951-d872f2087c98
* Some cross platform changes and general cleanups to Pickle.deanm@google.com2008-08-073-25/+26
| | | | | | | | | | | - Clean up TrimWriteData, and remove the unneeded VariableLengthBuffer struct. Modify a test to slightly test TrimWriteData, but it probably deserves more. - Remove unneeded includes in pickle_unittest, including windows.h. - According to 3.5 of the C++ standard, CustomHeader could not be used as a template argument, because it had no linkage. This now builds on GCC. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@508 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the LOCKED_EXPRESSION macro, it's clumbsy and unused.deanm@google.com2008-08-072-23/+0
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@506 0039d316-1c4b-4281-b951-d872f2087c98
* Use 0 instead of NULL, since AtomicWord is intptr_t which is not a pointer ↵deanm@google.com2008-08-071-1/+1
| | | | | | type. GCC warns when converting NULL to a non-pointer type. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@505 0039d316-1c4b-4281-b951-d872f2087c98
* Fix cut-and-paste error so we only try to build mac files on, gee, the mac...sgk@google.com2008-08-071-1/+1
| | | | | | TBR: mmentovai git-svn-id: svn://svn.chromium.org/chrome/trunk/src@482 0039d316-1c4b-4281-b951-d872f2087c98
* Add new sys_string_conversions_*.cc files to the SCons build.sgk@google.com2008-08-071-0/+11
| | | | | | TBR: brettw git-svn-id: svn://svn.chromium.org/chrome/trunk/src@481 0039d316-1c4b-4281-b951-d872f2087c98
* This is the addition of the system-dependent string conversions. This is ↵brettw@google.com2008-08-077-23/+412
| | | | | | just the new code and changing logging to use it. I will change other things to use this and delete the code in string_util in a subsequent pass. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@479 0039d316-1c4b-4281-b951-d872f2087c98
* We were passing -1 (indicating NULL terminated) to the UTF8->wide conversion ↵brettw@google.com2008-08-061-4/+6
| | | | | | | | function. The wide->UTF8 version is fine. This patch is just for branch. I'm reworking a lot of this code now. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@463 0039d316-1c4b-4281-b951-d872f2087c98
* Apparently, our WndProc can get called for other HWNDs :(darin@google.com2008-08-061-15/+17
| | | | | | TBR=brettw git-svn-id: svn://svn.chromium.org/chrome/trunk/src@461 0039d316-1c4b-4281-b951-d872f2087c98
* just some hopefully non-contentious stuff to get out of the way before doing ↵darin@google.com2008-08-066-81/+85
| | | | | | the real MessageLoop changes. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@459 0039d316-1c4b-4281-b951-d872f2087c98
* Drop FixedString. It's only used in two places, one where it doesn't really ↵evanm@google.com2008-08-065-169/+0
| | | | | | matter and the other where it was incorrect. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@458 0039d316-1c4b-4281-b951-d872f2087c98
* Revert base/base_path.cc (r450) since it caused large scale unit test failure.maruel@google.com2008-08-061-33/+3
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@456 0039d316-1c4b-4281-b951-d872f2087c98
* Add missing file_util_win.cc file.sgk@google.com2008-08-061-0/+1
| | | | | | TBR: bradnelson git-svn-id: svn://svn.chromium.org/chrome/trunk/src@454 0039d316-1c4b-4281-b951-d872f2087c98
* Fixing up the basic set of geometry.avi@google.com2008-08-067-12/+91
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1211 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@453 0039d316-1c4b-4281-b951-d872f2087c98
* We use intptr_t in various points in the code.evanm@google.com2008-08-061-0/+5
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@451 0039d316-1c4b-4281-b951-d872f2087c98
* Fix base::DIR_SOURCE_ROOT path calculation.maruel@google.com2008-08-068-16/+92
| | | | | | | | | Add missing header files to base.vcproj. Fix thread local storage implicit destructor call on Windows x64. Fix build compilation issues in x64 with third party headers. Fix Pickle for x64, the header doesn't need to be size_t, uint32 ought to be sufficient for the object. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@450 0039d316-1c4b-4281-b951-d872f2087c98
* Revert change 430 because it breaks the build.nsylvain@google.com2008-08-062-168/+27
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@437 0039d316-1c4b-4281-b951-d872f2087c98
* Refactoring file_util into file_util and file_util_win. Also fix windows ↵erikkay@google.com2008-08-067-597/+684
| | | | | | | | dependencies in path_service.cc. One questionable decision here was to put GetCurrentDirectory and SetCurrentDirectory into file_util_win.cc. I could have kept the logic in path_service.cc with #ifdefs or I could have split up path_service.cc into path_service_win.cc, etc. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@436 0039d316-1c4b-4281-b951-d872f2087c98
* Mac changes to the path service.avi@google.com2008-08-062-19/+45
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1107 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@435 0039d316-1c4b-4281-b951-d872f2087c98
* Portability fix for Value. The MSVC CRT doesn't complain about memcpy_s ↵mmentovai@google.com2008-08-062-2/+3
| | | | | | unless _CRT_SECURE_DEPRECATE_MEMORY is defined (and it isn't); there are no other callers of memcpy_s in base. (And seriously, what's an extra count argument supposed to solve, anyway?) current_entry_type is dropped because it's unused. A virtual destructor is added to ValueSerializer to conform to the style guide and quiet gcc's helpful warning. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@434 0039d316-1c4b-4281-b951-d872f2087c98
* Portability fix for JSONWriter. gcc warns when the declaration order ↵mmentovai@google.com2008-08-062-6/+7
| | | | | | doesn't match the initialization order. Tossed in a couple of changes for better style guide conformance for good measure. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@433 0039d316-1c4b-4281-b951-d872f2087c98
* Fix incorrect OS_APPLE to OS_MACOSX and drop COMPILER_GCC since the codedeanm@google.com2008-08-061-1/+1
| | | | | | | | uses the Apple APIs for atomic operations and not inline assembly. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@432 0039d316-1c4b-4281-b951-d872f2087c98
* Use our own hash function that supports embedded NULLs for both char and ↵pinkerton@google.com2008-08-061-15/+11
| | | | | | wchar strings git-svn-id: svn://svn.chromium.org/chrome/trunk/src@431 0039d316-1c4b-4281-b951-d872f2087c98
* Changes for POSIX support. Yay for ifdefs!pinkerton@google.com2008-08-062-27/+168
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@430 0039d316-1c4b-4281-b951-d872f2087c98
* Compiler changes to work with GCCpinkerton@google.com2008-08-062-7/+16
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@428 0039d316-1c4b-4281-b951-d872f2087c98
* Move base/timer from deprecated atomic interface to AtomicSequenceNumber.deanm@google.com2008-08-062-8/+5
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@427 0039d316-1c4b-4281-b951-d872f2087c98
* Move ref_counted to the new atomic_ref_count interface.deanm@google.com2008-08-061-8/+5
| | | | | | | | BUG=1112286 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@425 0039d316-1c4b-4281-b951-d872f2087c98
* Cross platform and cleanup of Singleton classdeanm@google.com2008-08-064-198/+52
| | | | | | | | | - Move away from windows-specific atomic operations to cross platform atopmicops - Remove double new semantics on windows git-svn-id: svn://svn.chromium.org/chrome/trunk/src@424 0039d316-1c4b-4281-b951-d872f2087c98
* Add YieldCurrentThread to PlatformThread, for giving up the current thread's ↵deanm@google.com2008-08-062-0/+16
| | | | | | timeslice. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@423 0039d316-1c4b-4281-b951-d872f2087c98
* Bring in more files from the mac july branch.paulg@google.com2008-08-062-12/+19
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@412 0039d316-1c4b-4281-b951-d872f2087c98
* ObjectWatcher needs to know when the current thread's MessageLoop is being ↵darin@google.com2008-08-055-6/+94
| | | | | | destroyed. This might also be generically useful, so I added a new API on ML to observe when the ML is being destroyed. The notification is sent to observers just prior to ML::current() being modified to return NULL. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@407 0039d316-1c4b-4281-b951-d872f2087c98
* Allow string-to-int conversions to provide a return value indicating ↵mmentovai@google.com2008-08-055-17/+421
| | | | | | 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
* Add base_paths_win.cc to SCons build.sgk@google.com2008-08-051-4/+9
| | | | | | | Use the occasion to collect the other *_win.cc source files in a Windows-specific block. TBR: erikkay git-svn-id: svn://svn.chromium.org/chrome/trunk/src@400 0039d316-1c4b-4281-b951-d872f2087c98
* Bring over the changes from the Mac branch.paulg@google.com2008-08-052-0/+23
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@392 0039d316-1c4b-4281-b951-d872f2087c98
* refactor base_paths so that windows-specific paths are pulled out into their ↵erikkay@google.com2008-08-056-102/+232
| | | | | | own file. Note that some of the same path key names will exist in other platform-specific files. For example, base_paths_mac.mm will have FILE_EXE and DIR_APP_DATA (among others). git-svn-id: svn://svn.chromium.org/chrome/trunk/src@389 0039d316-1c4b-4281-b951-d872f2087c98
* Fix an issue where U_WCHAR_IS_UTF16 would not be defined systematically. ↵maruel@google.com2008-08-051-3/+1
| | | | | | This would result in WordIterator definition not being consistent and random crashes would occur. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@387 0039d316-1c4b-4281-b951-d872f2087c98
* Revert base\gfx changes because it breaks the buildnsylvain@google.com2008-08-057-112/+7
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@386 0039d316-1c4b-4281-b951-d872f2087c98
* Unix line-endings.evanm@google.com2008-08-052-283/+283
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@384 0039d316-1c4b-4281-b951-d872f2087c98
* Fix for missing build info.avi@google.com2008-08-052-0/+4
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1128 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@383 0039d316-1c4b-4281-b951-d872f2087c98
* Fix basic geometric types.avi@google.com2008-08-057-7/+108
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1106 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@381 0039d316-1c4b-4281-b951-d872f2087c98
* Reworking unit test target to start all over, with gtest static library and ↵pinkerton@google.com2008-08-051-212/+144
| | | | | | pulling in only files we know compile. Define UNIT_TEST as some tests rely on that. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@375 0039d316-1c4b-4281-b951-d872f2087c98
* Import base::LINKER_INITIALIZED from google-perftools / tcmalloc. This is ↵deanm@google.com2008-08-051-0/+17
| | | | | | effectively just an annotation; a class can describe that it's ok to be used as a global static object because it will be zero initialized, so construction order doesn't matter. This also makes it clear from someone using it as a global object that it's safe. This will be used for spinlocks. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@374 0039d316-1c4b-4281-b951-d872f2087c98
* UTF16 vs 32 issues.avi@google.com2008-08-052-0/+23
| | | | | | Review URL: http://chrome-reviews.prom.corp.google.com/1091 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@373 0039d316-1c4b-4281-b951-d872f2087c98