avm2: Implement XMLList.toJSON()

This commit is contained in:
Nathan Adams 2023-08-03 12:32:29 +02:00
parent c199316ad3
commit 2330a45348
1 changed files with 8 additions and 0 deletions

View File

@ -26,6 +26,10 @@ package {
// but still exist
AS3 native function name(): Object;
AS3 function toJSON(k:String) : * {
return this.toJSON(k);
}
AS3 function valueOf():XMLList {
return this;
}
@ -99,6 +103,10 @@ package {
return self.AS3::text();
}
prototype.toJSON = function(k:String):* {
return "XMLList";
};
public static const length:int = 1;
}
}