Changeset 48712 in webkit
- Timestamp:
- Sep 24, 2009 3:42:45 AM (15 years ago)
- Location:
- trunk
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r48701 r48712 1 2009-09-24 Benjamin Poulain <benjamin.poulain@nokia.com> 2 3 Reviewed by Eric Seidel. 4 5 The indices of RuntimeArray should be enumerated like for a regular array. 6 https://bugs.webkit.org/show_bug.cgi?id=29005 7 8 * platform/mac/fast/dom/wrapper-classes-objc-expected.txt: 9 * platform/mac/fast/dom/wrapper-classes-objc.html: 10 1 11 2009-09-23 Geoffrey Garen <ggaren@apple.com> 2 12 -
trunk/LayoutTests/platform/mac/fast/dom/wrapper-classes-objc-expected.txt
r47901 r48712 193 193 PASS typeof objCObjectOfClass('WebScriptObject') is 'object' 194 194 PASS objCObjectOfClass('NSArray') instanceof Array is true 195 PASS concatenateArray(objCArrayOfString()) is 'onetwothree' 195 196 -
trunk/LayoutTests/platform/mac/fast/dom/wrapper-classes-objc.html
r47901 r48712 33 33 return "only works under DumpRenderTree"; 34 34 return objCController.objectOfClass(name); 35 } 36 37 function objCArrayOfString() 38 { 39 if (!window.objCController) 40 return "only works under DumpRenderTree"; 41 return objCController.arrayOfString(); 42 } 43 44 function concatenateArray(array) 45 { 46 var result = ''; 47 for (i in array) 48 result += array[i]; 49 return result; 35 50 } 36 51 … … 273 288 shouldBeTrue("objCObjectOfClass('NSArray') instanceof Array"); 274 289 290 shouldBe("concatenateArray(objCArrayOfString())", "'onetwothree'"); 291 275 292 // Not yet tested: 276 293 -
trunk/WebCore/ChangeLog
r48710 r48712 1 2009-09-24 Benjamin Poulain <benjamin.poulain@nokia.com> 2 3 Reviewed by Eric Seidel. 4 5 The indices of RuntimeArray should be enumerated like for a regular array. 6 https://bugs.webkit.org/show_bug.cgi?id=29005 7 8 * bridge/runtime_array.cpp: 9 (JSC::RuntimeArray::getPropertyNames): 10 * bridge/runtime_array.h: 11 1 12 2009-09-23 Alexander Pavlov <apavlov@chromium.org> 2 13 -
trunk/WebCore/bridge/runtime_array.cpp
r47780 r48712 29 29 #include <runtime/ArrayPrototype.h> 30 30 #include <runtime/Error.h> 31 #include <runtime/PropertyNameArray.h> 31 32 #include "JSDOMBinding.h" 32 33 … … 146 147 } 147 148 149 void RuntimeArray::getPropertyNames(ExecState* exec, PropertyNameArray& propertyNames) 150 { 151 const unsigned int length = getLength(); 152 for (unsigned i = 0; i < length; ++i) 153 propertyNames.add(Identifier::from(exec, i)); 154 155 JSObject::getPropertyNames(exec, propertyNames); 148 156 } 157 158 } -
trunk/WebCore/bridge/runtime_array.h
r47780 r48712 44 44 virtual bool deleteProperty(ExecState *exec, const Identifier &propertyName); 45 45 virtual bool deleteProperty(ExecState *exec, unsigned propertyName); 46 virtual void getPropertyNames(ExecState*, PropertyNameArray&); 46 47 47 48 virtual const ClassInfo *classInfo() const { return &s_info; } -
trunk/WebKitTools/ChangeLog
r48700 r48712 1 2009-09-24 Benjamin Poulain <benjamin.poulain@nokia.com> 2 3 Reviewed by Eric Seidel. 4 5 https://bugs.webkit.org/show_bug.cgi?id=29005 6 The indices of RuntimeArray should be enumerated like for a regular array. 7 8 * DumpRenderTree/mac/ObjCController.m: 9 (+[ObjCController isSelectorExcludedFromWebScript:]): 10 (+[ObjCController webScriptNameForSelector:]): 11 (-[ObjCController arrayOfString]): 12 1 13 2009-09-23 David Kilzer <ddkilzer@apple.com> 2 14 -
trunk/WebKitTools/DumpRenderTree/mac/ObjCController.m
r46340 r48712 59 59 || aSelector == @selector(classNameOf:) 60 60 || aSelector == @selector(objectOfClass:) 61 || aSelector == @selector(arrayOfString) 61 62 || aSelector == @selector(identityIsEqual::) 62 63 || aSelector == @selector(longLongRoundTrip:) … … 78 79 if (aSelector == @selector(objectOfClass:)) 79 80 return @"objectOfClass"; 81 if (aSelector == @selector(arrayOfString)) 82 return @"arrayOfString"; 80 83 if (aSelector == @selector(identityIsEqual::)) 81 84 return @"identityIsEqual"; … … 123 126 } 124 127 128 - (NSArray *)arrayOfString 129 { 130 NSString *strings[3]; 131 strings[0] = @"one"; 132 strings[1] = @"two"; 133 strings[2] = @"three"; 134 NSArray *array = [NSArray arrayWithObjects:strings count:3]; 135 return array; 136 } 137 125 138 - (BOOL)identityIsEqual:(WebScriptObject *)a :(WebScriptObject *)b 126 139 {
Note: See TracChangeset
for help on using the changeset viewer.