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

Side by Side Diff: Source/bindings/core/v8/V8Binding.h

Issue 644473006: Rename 'ScalarValueString' to 'USVString' to match Web IDL (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2012 Ericsson AB. All rights reserved. 3 * Copyright (C) 2012 Ericsson AB. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after
535 return static_cast<float>(value->NumberValue()); 535 return static_cast<float>(value->NumberValue());
536 } 536 }
537 537
538 // Convert a value to a double precision float, which might fail. 538 // Convert a value to a double precision float, which might fail.
539 double toDouble(v8::Handle<v8::Value>, ExceptionState&); 539 double toDouble(v8::Handle<v8::Value>, ExceptionState&);
540 540
541 // Converts a value to a String, throwing if any code unit is outside 0-255. 541 // Converts a value to a String, throwing if any code unit is outside 0-255.
542 String toByteString(v8::Handle<v8::Value>, ExceptionState&); 542 String toByteString(v8::Handle<v8::Value>, ExceptionState&);
543 543
544 // Converts a value to a String, replacing unmatched UTF-16 surrogates with repl acement characters. 544 // Converts a value to a String, replacing unmatched UTF-16 surrogates with repl acement characters.
545 String toScalarValueString(v8::Handle<v8::Value>, ExceptionState&); 545 String toUSVString(v8::Handle<v8::Value>, ExceptionState&);
546 546
547 inline v8::Handle<v8::Boolean> v8Boolean(bool value, v8::Isolate* isolate) 547 inline v8::Handle<v8::Boolean> v8Boolean(bool value, v8::Isolate* isolate)
548 { 548 {
549 return value ? v8::True(isolate) : v8::False(isolate); 549 return value ? v8::True(isolate) : v8::False(isolate);
550 } 550 }
551 551
552 inline double toCoreDate(v8::Handle<v8::Value> object) 552 inline double toCoreDate(v8::Handle<v8::Value> object)
553 { 553 {
554 if (object->IsDate()) 554 if (object->IsDate())
555 return v8::Handle<v8::Date>::Cast(object)->ValueOf(); 555 return v8::Handle<v8::Date>::Cast(object)->ValueOf();
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after
1019 v8::Local<v8::Value> v8IteratorResult(ScriptState* scriptState, const T& value) 1019 v8::Local<v8::Value> v8IteratorResult(ScriptState* scriptState, const T& value)
1020 { 1020 {
1021 return v8IteratorResult(scriptState->isolate(), V8ValueTraits<T>::toV8Value( value, scriptState->context()->Global(), scriptState->isolate())); 1021 return v8IteratorResult(scriptState->isolate(), V8ValueTraits<T>::toV8Value( value, scriptState->context()->Global(), scriptState->isolate()));
1022 } 1022 }
1023 1023
1024 typedef void (*InstallTemplateFunction)(v8::Handle<v8::FunctionTemplate>, v8::Is olate*); 1024 typedef void (*InstallTemplateFunction)(v8::Handle<v8::FunctionTemplate>, v8::Is olate*);
1025 1025
1026 } // namespace blink 1026 } // namespace blink
1027 1027
1028 #endif // V8Binding_h 1028 #endif // V8Binding_h
OLDNEW
« no previous file with comments | « LayoutTests/fast/js/webidl-type-mapping-expected.txt ('k') | Source/bindings/core/v8/V8Binding.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698