avm1: set contentType on xml; fix initial contentType on load_vars.

This commit is contained in:
Chris Midgley 2021-04-15 19:24:29 +01:00 committed by Mike Welsh
parent 3f718e508e
commit f1b07bd75b
2 changed files with 7 additions and 1 deletions

View File

@ -86,7 +86,7 @@ pub fn create_proto<'gc>(
object.define_value( object.define_value(
gc_context, gc_context,
"contentType", "contentType",
"application/x-www-form-url-encoded".into(), "application/x-www-form-urlencoded".into(),
Attribute::DONT_DELETE | Attribute::READ_ONLY | Attribute::DONT_ENUM, Attribute::DONT_DELETE | Attribute::READ_ONLY | Attribute::DONT_ENUM,
); );

View File

@ -1087,6 +1087,12 @@ pub fn create_xml_proto<'gc>(
Attribute::READ_ONLY, Attribute::READ_ONLY,
); );
xml_proto.define_value(gc_context, "ignoreWhite", false.into(), Attribute::empty()); xml_proto.define_value(gc_context, "ignoreWhite", false.into(), Attribute::empty());
xml_proto.define_value(
gc_context,
"contentType",
"application/x-www-form-urlencoded".into(),
Attribute::empty(),
);
xml_proto.add_property( xml_proto.add_property(
gc_context, gc_context,
"xmlDecl", "xmlDecl",