| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 DEFINE_STATIC_LOCAL(ArrayBufferAllocator, arrayBufferAllocator, ()); | 120 DEFINE_STATIC_LOCAL(ArrayBufferAllocator, arrayBufferAllocator, ()); |
| 121 return &arrayBufferAllocator; | 121 return &arrayBufferAllocator; |
| 122 } | 122 } |
| 123 | 123 |
| 124 PassRefPtrWillBeRawPtr<NodeFilter> toNodeFilter(v8::Handle<v8::Value> callback,
v8::Handle<v8::Object> creationContext, ScriptState* scriptState) | 124 PassRefPtrWillBeRawPtr<NodeFilter> toNodeFilter(v8::Handle<v8::Value> callback,
v8::Handle<v8::Object> creationContext, ScriptState* scriptState) |
| 125 { | 125 { |
| 126 if (callback->IsNull()) | 126 if (callback->IsNull()) |
| 127 return nullptr; | 127 return nullptr; |
| 128 RefPtrWillBeRawPtr<NodeFilter> filter = NodeFilter::create(); | 128 RefPtrWillBeRawPtr<NodeFilter> filter = NodeFilter::create(); |
| 129 | 129 |
| 130 v8::Handle<v8::Object> filterWrapper = toV8(filter, creationContext, scriptS
tate->isolate()).As<v8::Object>(); | 130 v8::Handle<v8::Object> filterWrapper = toV8(filter.get(), creationContext, s
criptState->isolate()).As<v8::Object>(); |
| 131 | 131 |
| 132 RefPtrWillBeRawPtr<NodeFilterCondition> condition = V8NodeFilterCondition::c
reate(callback, filterWrapper, scriptState); | 132 RefPtrWillBeRawPtr<NodeFilterCondition> condition = V8NodeFilterCondition::c
reate(callback, filterWrapper, scriptState); |
| 133 filter->setCondition(condition.release()); | 133 filter->setCondition(condition.release()); |
| 134 | 134 |
| 135 return filter.release(); | 135 return filter.release(); |
| 136 } | 136 } |
| 137 | 137 |
| 138 const int32_t kMaxInt32 = 0x7fffffff; | 138 const int32_t kMaxInt32 = 0x7fffffff; |
| 139 const int32_t kMinInt32 = -kMaxInt32 - 1; | 139 const int32_t kMinInt32 = -kMaxInt32 - 1; |
| 140 const uint32_t kMaxUInt32 = 0xffffffff; | 140 const uint32_t kMaxUInt32 = 0xffffffff; |
| (...skipping 853 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 994 | 994 |
| 995 v8::Local<v8::Value> v8IteratorResult(v8::Isolate* isolate, v8::Handle<v8::Value
> value) | 995 v8::Local<v8::Value> v8IteratorResult(v8::Isolate* isolate, v8::Handle<v8::Value
> value) |
| 996 { | 996 { |
| 997 v8::Local<v8::Object> result = v8::Object::New(isolate); | 997 v8::Local<v8::Object> result = v8::Object::New(isolate); |
| 998 result->Set(v8String(isolate, "value"), value); | 998 result->Set(v8String(isolate, "value"), value); |
| 999 result->Set(v8String(isolate, "done"), v8Boolean(false, isolate)); | 999 result->Set(v8String(isolate, "done"), v8Boolean(false, isolate)); |
| 1000 return result; | 1000 return result; |
| 1001 } | 1001 } |
| 1002 | 1002 |
| 1003 } // namespace blink | 1003 } // namespace blink |
| OLD | NEW |