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 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 | 253 |
254 template <> | 254 template <> |
255 bool DictionaryHelper::get(const Dictionary& dictionary, const String& key, RefP
trWillBeMember<DOMWindow>& value) | 255 bool DictionaryHelper::get(const Dictionary& dictionary, const String& key, RefP
trWillBeMember<DOMWindow>& value) |
256 { | 256 { |
257 v8::Local<v8::Value> v8Value; | 257 v8::Local<v8::Value> v8Value; |
258 if (!dictionary.get(key, v8Value)) | 258 if (!dictionary.get(key, v8Value)) |
259 return false; | 259 return false; |
260 | 260 |
261 // We need to handle a DOMWindow specially, because a DOMWindow wrapper | 261 // We need to handle a DOMWindow specially, because a DOMWindow wrapper |
262 // exists on a prototype chain of v8Value. | 262 // exists on a prototype chain of v8Value. |
263 value = toDOMWindow(v8Value, dictionary.isolate()); | 263 value = toDOMWindow(dictionary.isolate(), v8Value); |
264 return true; | 264 return true; |
265 } | 265 } |
266 | 266 |
267 template <> | 267 template <> |
268 bool DictionaryHelper::get(const Dictionary& dictionary, const String& key, Hash
Set<AtomicString>& value) | 268 bool DictionaryHelper::get(const Dictionary& dictionary, const String& key, Hash
Set<AtomicString>& value) |
269 { | 269 { |
270 v8::Local<v8::Value> v8Value; | 270 v8::Local<v8::Value> v8Value; |
271 if (!dictionary.get(key, v8Value)) | 271 if (!dictionary.get(key, v8Value)) |
272 return false; | 272 return false; |
273 | 273 |
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
677 | 677 |
678 value = toRefPtrWillBeMemberNativeArray<MessagePort, V8MessagePort>(v8Value,
key, dictionary.isolate(), context.exceptionState()); | 678 value = toRefPtrWillBeMemberNativeArray<MessagePort, V8MessagePort>(v8Value,
key, dictionary.isolate(), context.exceptionState()); |
679 | 679 |
680 if (context.exceptionState().throwIfNeeded()) | 680 if (context.exceptionState().throwIfNeeded()) |
681 return false; | 681 return false; |
682 | 682 |
683 return true; | 683 return true; |
684 } | 684 } |
685 | 685 |
686 } // namespace blink | 686 } // namespace blink |
OLD | NEW |