Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(57)

Side by Side Diff: third_party/WebKit/Source/core/dom/Document.cpp

Issue 2693433002: Migrate WTF::HashMap::add() to ::insert() [final] (Closed)
Patch Set: more platform-specific references Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All
7 * rights reserved. 7 * rights reserved.
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
9 * (http://www.torchmobile.com/) 9 * (http://www.torchmobile.com/)
10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
(...skipping 6233 matching lines...) Expand 10 before | Expand all | Expand 10 after
6244 return m_styleEngine->haveRenderBlockingStylesheetsLoaded(); 6244 return m_styleEngine->haveRenderBlockingStylesheetsLoaded();
6245 return m_styleEngine->haveScriptBlockingStylesheetsLoaded(); 6245 return m_styleEngine->haveScriptBlockingStylesheetsLoaded();
6246 } 6246 }
6247 6247
6248 Locale& Document::getCachedLocale(const AtomicString& locale) { 6248 Locale& Document::getCachedLocale(const AtomicString& locale) {
6249 AtomicString localeKey = locale; 6249 AtomicString localeKey = locale;
6250 if (locale.isEmpty() || 6250 if (locale.isEmpty() ||
6251 !RuntimeEnabledFeatures::langAttributeAwareFormControlUIEnabled()) 6251 !RuntimeEnabledFeatures::langAttributeAwareFormControlUIEnabled())
6252 return Locale::defaultLocale(); 6252 return Locale::defaultLocale();
6253 LocaleIdentifierToLocaleMap::AddResult result = 6253 LocaleIdentifierToLocaleMap::AddResult result =
6254 m_localeCache.add(localeKey, nullptr); 6254 m_localeCache.insert(localeKey, nullptr);
6255 if (result.isNewEntry) 6255 if (result.isNewEntry)
6256 result.storedValue->value = Locale::create(localeKey); 6256 result.storedValue->value = Locale::create(localeKey);
6257 return *(result.storedValue->value); 6257 return *(result.storedValue->value);
6258 } 6258 }
6259 6259
6260 AnimationClock& Document::animationClock() { 6260 AnimationClock& Document::animationClock() {
6261 DCHECK(page()); 6261 DCHECK(page());
6262 return page()->animator().clock(); 6262 return page()->animator().clock();
6263 } 6263 }
6264 6264
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after
6587 } 6587 }
6588 6588
6589 void showLiveDocumentInstances() { 6589 void showLiveDocumentInstances() {
6590 WeakDocumentSet& set = liveDocumentSet(); 6590 WeakDocumentSet& set = liveDocumentSet();
6591 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); 6591 fprintf(stderr, "There are %u documents currently alive:\n", set.size());
6592 for (blink::Document* document : set) 6592 for (blink::Document* document : set)
6593 fprintf(stderr, "- Document %p URL: %s\n", document, 6593 fprintf(stderr, "- Document %p URL: %s\n", document,
6594 document->url().getString().utf8().data()); 6594 document->url().getString().utf8().data());
6595 } 6595 }
6596 #endif 6596 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698