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

Side by Side Diff: third_party/WebKit/Source/platform/bindings/StringResource.cpp

Issue 2843603002: Move ScriptWrappable and dependencies to platform/bindings (Closed)
Patch Set: Rebase and try again Created 3 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
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "bindings/core/v8/StringResource.h" 5 #include "platform/bindings/StringResource.h"
6 6
7 #include "bindings/core/v8/V8Binding.h" 7 #include "platform/bindings/V8Binding.h"
8 8
9 namespace blink { 9 namespace blink {
10 10
11 template <class StringClass> 11 template <class StringClass>
12 struct StringTraits { 12 struct StringTraits {
13 static const StringClass& FromStringResource(StringResourceBase*); 13 static const StringClass& FromStringResource(StringResourceBase*);
14 template <typename V8StringTrait> 14 template <typename V8StringTrait>
15 static StringClass FromV8String(v8::Local<v8::String>, int); 15 static StringClass FromV8String(v8::Local<v8::String>, int);
16 }; 16 };
17 17
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 157
158 String Int32ToWebCoreString(int value) { 158 String Int32ToWebCoreString(int value) {
159 // If we are on the main thread (this should always true for non-workers), 159 // If we are on the main thread (this should always true for non-workers),
160 // call the faster one. 160 // call the faster one.
161 if (IsMainThread()) 161 if (IsMainThread())
162 return Int32ToWebCoreStringFast(value); 162 return Int32ToWebCoreStringFast(value);
163 return String::Number(value); 163 return String::Number(value);
164 } 164 }
165 165
166 } // namespace blink 166 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698