OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 OnInstance = 1 << 0, | 56 OnInstance = 1 << 0, |
57 OnPrototype = 1 << 1, | 57 OnPrototype = 1 << 1, |
58 OnInterface = 1 << 2, | 58 OnInterface = 1 << 2, |
59 }; | 59 }; |
60 | 60 |
61 enum HolderCheckConfiguration { | 61 enum HolderCheckConfiguration { |
62 CheckHolder, | 62 CheckHolder, |
63 DoNotCheckHolder, | 63 DoNotCheckHolder, |
64 }; | 64 }; |
65 | 65 |
66 // AttributeConfiguration translates into calls to SetNativeDataProperty() on
either | 66 // AttributeConfiguration translates into calls to SetNativeDataProperty() on |
67 // the instance or the prototype ObjectTemplate, based on |instanceOrPrototype
Configuration|. | 67 // either the instance or the prototype ObjectTemplate, based on |
| 68 // |instanceOrPrototypeConfiguration|. |
68 struct AttributeConfiguration { | 69 struct AttributeConfiguration { |
69 AttributeConfiguration& operator=(const AttributeConfiguration&) = delete; | 70 AttributeConfiguration& operator=(const AttributeConfiguration&) = delete; |
70 DISALLOW_NEW(); | 71 DISALLOW_NEW(); |
71 const char* const name; | 72 const char* const name; |
72 v8::AccessorNameGetterCallback getter; | 73 v8::AccessorNameGetterCallback getter; |
73 v8::AccessorNameSetterCallback setter; | 74 v8::AccessorNameSetterCallback setter; |
74 v8::AccessorNameGetterCallback getterForMainWorld; | 75 v8::AccessorNameGetterCallback getterForMainWorld; |
75 v8::AccessorNameSetterCallback setterForMainWorld; | 76 v8::AccessorNameSetterCallback setterForMainWorld; |
76 const WrapperTypeInfo* data; | 77 const WrapperTypeInfo* data; |
77 unsigned settings : 8; // v8::AccessControl | 78 unsigned settings : 8; // v8::AccessControl |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 const char* interfaceName, | 282 const char* interfaceName, |
282 v8::Local<v8::FunctionTemplate> parentInterfaceTemplate, | 283 v8::Local<v8::FunctionTemplate> parentInterfaceTemplate, |
283 size_t v8InternalFieldCount); | 284 size_t v8InternalFieldCount); |
284 | 285 |
285 static v8::Local<v8::FunctionTemplate> domClassTemplate( | 286 static v8::Local<v8::FunctionTemplate> domClassTemplate( |
286 v8::Isolate*, | 287 v8::Isolate*, |
287 const DOMWrapperWorld&, | 288 const DOMWrapperWorld&, |
288 WrapperTypeInfo*, | 289 WrapperTypeInfo*, |
289 InstallTemplateFunction); | 290 InstallTemplateFunction); |
290 | 291 |
291 // Sets the class string of platform objects, interface prototype objects, etc
. | 292 // Sets the class string of platform objects, interface prototype objects, |
292 // See also http://heycam.github.io/webidl/#dfn-class-string | 293 // etc. See also http://heycam.github.io/webidl/#dfn-class-string |
293 static void setClassString(v8::Isolate*, | 294 static void setClassString(v8::Isolate*, |
294 v8::Local<v8::ObjectTemplate>, | 295 v8::Local<v8::ObjectTemplate>, |
295 const char* classString); | 296 const char* classString); |
296 }; | 297 }; |
297 | 298 |
298 } // namespace blink | 299 } // namespace blink |
299 | 300 |
300 #endif // V8DOMConfiguration_h | 301 #endif // V8DOMConfiguration_h |
OLD | NEW |