OLD | NEW |
1 // Copyright (c) 2008, Google Inc. | 1 // Copyright (c) 2008, Google Inc. |
2 // All rights reserved. | 2 // 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 1423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1434 desc->InstanceTemplate()->SetNamedPropertyHandler( | 1434 desc->InstanceTemplate()->SetNamedPropertyHandler( |
1435 USE_NAMED_PROPERTY_GETTER(NamedNodeMap)); | 1435 USE_NAMED_PROPERTY_GETTER(NamedNodeMap)); |
1436 desc->InstanceTemplate()->SetIndexedPropertyHandler( | 1436 desc->InstanceTemplate()->SetIndexedPropertyHandler( |
1437 USE_INDEXED_PROPERTY_GETTER(NamedNodeMap), | 1437 USE_INDEXED_PROPERTY_GETTER(NamedNodeMap), |
1438 0, | 1438 0, |
1439 0, | 1439 0, |
1440 0, | 1440 0, |
1441 collectionIndexedPropertyEnumerator<NamedNodeMap>, | 1441 collectionIndexedPropertyEnumerator<NamedNodeMap>, |
1442 v8::Integer::New(V8ClassIndex::NODE)); | 1442 v8::Integer::New(V8ClassIndex::NODE)); |
1443 break; | 1443 break; |
| 1444 #if ENABLE(DOM_STORAGE) |
| 1445 case V8ClassIndex::STORAGE: |
| 1446 desc->InstanceTemplate()->SetNamedPropertyHandler( |
| 1447 USE_NAMED_PROPERTY_GETTER(Storage), |
| 1448 USE_NAMED_PROPERTY_SETTER(Storage), |
| 1449 0, |
| 1450 USE_NAMED_PROPERTY_DELETER(Storage), |
| 1451 V8Custom::v8StorageNamedPropertyEnumerator); |
| 1452 desc->InstanceTemplate()->SetIndexedPropertyHandler( |
| 1453 USE_INDEXED_PROPERTY_GETTER(Storage), |
| 1454 USE_INDEXED_PROPERTY_SETTER(Storage), |
| 1455 0, |
| 1456 USE_INDEXED_PROPERTY_DELETER(Storage)); |
| 1457 break; |
| 1458 #endif |
1444 case V8ClassIndex::NODELIST: | 1459 case V8ClassIndex::NODELIST: |
1445 setCollectionIndexedGetter<NodeList, Node>(desc, V8ClassIndex::NODE); | 1460 setCollectionIndexedGetter<NodeList, Node>(desc, V8ClassIndex::NODE); |
1446 desc->InstanceTemplate()->SetNamedPropertyHandler( | 1461 desc->InstanceTemplate()->SetNamedPropertyHandler( |
1447 USE_NAMED_PROPERTY_GETTER(NodeList)); | 1462 USE_NAMED_PROPERTY_GETTER(NodeList)); |
1448 break; | 1463 break; |
1449 case V8ClassIndex::PLUGIN: | 1464 case V8ClassIndex::PLUGIN: |
1450 setCollectionIndexedAndNamedGetters<Plugin, MimeType>( | 1465 setCollectionIndexedAndNamedGetters<Plugin, MimeType>( |
1451 desc, | 1466 desc, |
1452 V8ClassIndex::MIMETYPE); | 1467 V8ClassIndex::MIMETYPE); |
1453 break; | 1468 break; |
(...skipping 1937 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3391 } | 3406 } |
3392 | 3407 |
3393 void V8Proxy::RegisterExtension(v8::Extension* extension, | 3408 void V8Proxy::RegisterExtension(v8::Extension* extension, |
3394 const String& schemeRestriction) { | 3409 const String& schemeRestriction) { |
3395 v8::RegisterExtension(extension); | 3410 v8::RegisterExtension(extension); |
3396 V8ExtensionInfo info = {schemeRestriction, extension}; | 3411 V8ExtensionInfo info = {schemeRestriction, extension}; |
3397 m_extensions.push_back(info); | 3412 m_extensions.push_back(info); |
3398 } | 3413 } |
3399 | 3414 |
3400 } // namespace WebCore | 3415 } // namespace WebCore |
OLD | NEW |