diff options
author | erg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-18 17:52:50 +0000 |
---|---|---|
committer | erg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-18 17:52:50 +0000 |
commit | a223028a2c2d8113c9dbad9681e65268a8229b9a (patch) | |
tree | d373afb061ef288a94dd632a9fcbed9c7805141f /base | |
parent | 53ae7c4c5f08e73d66ef8b2303691d893f5d9e47 (diff) | |
download | chromium_src-a223028a2c2d8113c9dbad9681e65268a8229b9a.zip chromium_src-a223028a2c2d8113c9dbad9681e65268a8229b9a.tar.gz chromium_src-a223028a2c2d8113c9dbad9681e65268a8229b9a.tar.bz2 |
Revert 50257 - Reland r50057. This is exactly the same except with two lines cherrypicked from
tony's CL 2814009 that tell make about the net_internals_resources_map.{cc,h}
files.
Load net-internals from the newly created resources.pak file.
This patch also forces the loading of the optional DataPack for const correctness reasons
Original Review: http://codereview.chromium.org/2855003
BUG=35793,42770
TEST=none
TBR=tony
Review URL: http://codereview.chromium.org/2800014
TBR=erg@chromium.org
Review URL: http://codereview.chromium.org/2811016
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50260 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base')
-rw-r--r-- | base/data_pack.cc | 4 | ||||
-rw-r--r-- | base/data_pack.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/base/data_pack.cc b/base/data_pack.cc index 06f2308..4e5a569 100644 --- a/base/data_pack.cc +++ b/base/data_pack.cc @@ -96,7 +96,7 @@ bool DataPack::Load(const FilePath& path) { return true; } -bool DataPack::GetStringPiece(uint32 resource_id, StringPiece* data) const { +bool DataPack::GetStringPiece(uint32 resource_id, StringPiece* data) { // It won't be hard to make this endian-agnostic, but it's not worth // bothering to do right now. #if defined(__BYTE_ORDER) @@ -119,7 +119,7 @@ bool DataPack::GetStringPiece(uint32 resource_id, StringPiece* data) const { return true; } -RefCountedStaticMemory* DataPack::GetStaticMemory(uint32 resource_id) const { +RefCountedStaticMemory* DataPack::GetStaticMemory(uint32 resource_id) { base::StringPiece piece; if (!GetStringPiece(resource_id, &piece)) return NULL; diff --git a/base/data_pack.h b/base/data_pack.h index f3f8481..8938491 100644 --- a/base/data_pack.h +++ b/base/data_pack.h @@ -35,12 +35,12 @@ class DataPack { // Get resource by id |resource_id|, filling in |data|. // The data is owned by the DataPack object and should not be modified. // Returns false if the resource id isn't found. - bool GetStringPiece(uint32 resource_id, StringPiece* data) const; + bool GetStringPiece(uint32 resource_id, StringPiece* data); // Like GetStringPiece(), but returns a reference to memory. This interface // is used for image data, while the StringPiece interface is usually used // for localization strings. - RefCountedStaticMemory* GetStaticMemory(uint32 resource_id) const; + RefCountedStaticMemory* GetStaticMemory(uint32 resource_id); // Writes a pack file containing |resources| to |path|. static bool WritePack(const FilePath& path, |