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

Side by Side Diff: Source/core/css/CSSStyleDeclaration.cpp

Issue 1120253002: [bindings] Remove usage of custom binding for namedPropertyQuery of CSSStyleDeclaration (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « Source/core/css/CSSStyleDeclaration.h ('k') | Source/core/css/CSSStyleDeclaration.idl » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/css/CSSStyleDeclaration.h" 6 #include "core/css/CSSStyleDeclaration.h"
7 7
8 #include "bindings/core/v8/V8Binding.h" 8 #include "bindings/core/v8/V8Binding.h"
9 #include "core/css/CSSPropertyMetadata.h" 9 #include "core/css/CSSPropertyMetadata.h"
10 #include "core/css/parser/CSSParser.h" 10 #include "core/css/parser/CSSParser.h"
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 std::sort(propertyNames.begin(), propertyNames.end(), codePointCompareLe ssThan); 139 std::sort(propertyNames.begin(), propertyNames.end(), codePointCompareLe ssThan);
140 propertyNamesLength = propertyNames.size(); 140 propertyNamesLength = propertyNames.size();
141 } 141 }
142 for (unsigned i = 0; i < propertyNamesLength; ++i) { 142 for (unsigned i = 0; i < propertyNamesLength; ++i) {
143 String key = propertyNames.at(i); 143 String key = propertyNames.at(i);
144 ASSERT(!key.isNull()); 144 ASSERT(!key.isNull());
145 names.append(key); 145 names.append(key);
146 } 146 }
147 } 147 }
148 148
149 bool CSSStyleDeclaration::namedPropertyQuery(ScriptState* scriptState, const Ato micString& name, ExceptionState&)
150 {
151 // NOTE: cssPropertyInfo lookups incur several mallocs.
152 // Successful lookups have the same cost the first time, but are cached.
153 if (cssPropertyInfo(name, scriptState->isolate()))
154 return true;
155 return false;
149 } 156 }
157
158 }
OLDNEW
« no previous file with comments | « Source/core/css/CSSStyleDeclaration.h ('k') | Source/core/css/CSSStyleDeclaration.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698