OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
424 v8::Local<v8::Value> v8Value; | 424 v8::Local<v8::Value> v8Value; |
425 if (!getKey(key, v8Value)) | 425 if (!getKey(key, v8Value)) |
426 return false; | 426 return false; |
427 | 427 |
428 value = V8Uint8Array::toNativeWithTypeCheck(m_isolate, v8Value); | 428 value = V8Uint8Array::toNativeWithTypeCheck(m_isolate, v8Value); |
429 return true; | 429 return true; |
430 } | 430 } |
431 | 431 |
432 bool Dictionary::get(const String& key, RefPtr<ArrayBufferView>& value) const | 432 bool Dictionary::get(const String& key, RefPtr<ArrayBufferView>& value) const |
433 { | 433 { |
434 bool unused; | |
435 return get(key, value, unused); | |
436 } | |
437 | |
438 bool Dictionary::get(const String& key, RefPtr<ArrayBufferView>& value, bool& ha sValue) const | |
439 { | |
434 v8::Local<v8::Value> v8Value; | 440 v8::Local<v8::Value> v8Value; |
435 if (!getKey(key, v8Value)) | 441 if (!getKey(key, v8Value)) { |
442 hasValue = false; | |
sof
2014/02/25 22:01:45
Hmm, this extra reference argument seems to end up
eroman
2014/02/25 22:23:29
You are right, my mistake.
Will remove
eroman
2014/02/25 22:31:00
Thanks sof! updated.
| |
436 return false; | 443 return false; |
444 } | |
437 | 445 |
446 hasValue = true; | |
438 value = V8ArrayBufferView::toNativeWithTypeCheck(m_isolate, v8Value); | 447 value = V8ArrayBufferView::toNativeWithTypeCheck(m_isolate, v8Value); |
439 return true; | 448 return true; |
440 } | 449 } |
441 | 450 |
442 bool Dictionary::get(const String& key, RefPtr<MIDIPort>& value) const | 451 bool Dictionary::get(const String& key, RefPtr<MIDIPort>& value) const |
443 { | 452 { |
444 v8::Local<v8::Value> v8Value; | 453 v8::Local<v8::Value> v8Value; |
445 if (!getKey(key, v8Value)) | 454 if (!getKey(key, v8Value)) |
446 return false; | 455 return false; |
447 | 456 |
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
752 { | 761 { |
753 if (forConstructor()) { | 762 if (forConstructor()) { |
754 exceptionState().throwTypeError(detail); | 763 exceptionState().throwTypeError(detail); |
755 } else { | 764 } else { |
756 ASSERT(!methodName().isEmpty()); | 765 ASSERT(!methodName().isEmpty()); |
757 exceptionState().throwTypeError(ExceptionMessages::failedToExecute(inter faceName(), methodName(), detail)); | 766 exceptionState().throwTypeError(ExceptionMessages::failedToExecute(inter faceName(), methodName(), detail)); |
758 } | 767 } |
759 } | 768 } |
760 | 769 |
761 } // namespace WebCore | 770 } // namespace WebCore |
OLD | NEW |