summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordeanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-01-13 12:37:19 +0000
committerdeanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-01-13 12:37:19 +0000
commit82bf9d4dd4815aafc67c2dc9f5e825f5246d9f6c (patch)
tree9755d380fbc0a3a5565beeab1f443f45725148bb
parentde1f44a0d55309165a21afede7b84fbd01df258b (diff)
downloadchromium_src-82bf9d4dd4815aafc67c2dc9f5e825f5246d9f6c.zip
chromium_src-82bf9d4dd4815aafc67c2dc9f5e825f5246d9f6c.tar.gz
chromium_src-82bf9d4dd4815aafc67c2dc9f5e825f5246d9f6c.tar.bz2
Remove two static initializers in webkit glue entity map.
Review URL: http://codereview.chromium.org/17360 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7924 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--webkit/glue/entity_map.cc13
1 files changed, 5 insertions, 8 deletions
diff --git a/webkit/glue/entity_map.cc b/webkit/glue/entity_map.cc
index 6ed6c82..77a58fe 100644
--- a/webkit/glue/entity_map.cc
+++ b/webkit/glue/entity_map.cc
@@ -74,15 +74,12 @@ static const Entity xml_built_in_entity_codes[] = {
{"quot", 0x0022}
};
-static const int xml_entity_codes_length =
- arraysize(xml_built_in_entity_codes);
-
-static EntityMapData html_entity_map_singleton(
- wordlist, sizeof(wordlist) / sizeof(Entity), true);
-static EntityMapData xml_entity_map_singleton(
- xml_built_in_entity_codes, xml_entity_codes_length, false);
-
const char* EntityMap::GetEntityNameByCode(char16 code, bool is_html) {
+ static EntityMapData html_entity_map_singleton(
+ wordlist, sizeof(wordlist) / sizeof(Entity), true);
+ static EntityMapData xml_entity_map_singleton(
+ xml_built_in_entity_codes, arraysize(xml_built_in_entity_codes), false);
+
const EntityMapType* entity_map;
if (is_html)
entity_map = html_entity_map_singleton.GetEntityMapData();