[Mono-list] Javascript and Mono
Jeroen Janssen
japj@xs4all.nl
Sat, 04 Jan 2003 00:17:13 +0100
This is a multi-part message in MIME format.
--------------090401050501000904060800
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Andrew Stopford wrote:
>Hi,
>
>I would be interested in helping out on this, who else would like to
>help out?
>
>
Is there a central place where development is going to take place?
(I attached a small patch, since it didn't work 'out of the box' for me).
---
Jeroen Janssen
--------------090401050501000904060800
Content-Type: text/plain;
name="JANET.patch.txt"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="JANET.patch.txt"
diff -u -r src2/JObjects.cs src/JObjects.cs
--- src2/JObjects.cs 2001-10-18 03:16:46.000000000 +0200
+++ src/JObjects.cs 2003-01-04 00:11:36.000000000 +0100
@@ -1004,7 +1004,7 @@
// If the given string is an ECMAScript numerical array index, fill in
// arrayIndex and return true. Otherwise set arrayIndex to 0 and return
// false.
- private bool IsArrayIndex(string propName, out UInt32 arrayIndex)
+ public bool IsArrayIndex(string propName, out UInt32 arrayIndex)
{
arrayIndex = 0;
diff -u -r src2/JRuntime.cs src/JRuntime.cs
--- src2/JRuntime.cs 2003-01-04 00:13:50.000000000 +0100
+++ src/JRuntime.cs 2003-01-04 00:13:20.000000000 +0100
@@ -220,7 +220,7 @@
if (!members.ContainsKey(name))
{
UInt32 arrayIndex;
- if ( !useStatic_ && JArrayObject.IsArrayIndex(name, out arrayIndex) &&
+ if ( !useStatic_ && ((JArrayObject)target).IsArrayIndex(name, out arrayIndex) &&
targetType_.IsArray )
{
return InvokeMethod(target, "GetValue", new object[]{arrayIndex});
Only in src: test.cs
--------------090401050501000904060800--