Commit Graph

1653 Commits

Author SHA1 Message Date
Aaron Hill 639d17d259 Apply 'xml["@myattr"]' logic when setting/deleting properties
We previously only applied this when getting properties.
2024-01-12 19:13:35 -05:00
sleepycatcoding 2775c917bf avm2: Correctly handle `@*` in string_to_multiname 2024-01-13 00:27:28 +02:00
Kamil Jarosz 70486465e8 core: Support TextField.restrict when pasting 2024-01-11 23:22:49 +01:00
Kamil Jarosz 1db34993a2 tests: Add AutomatedEvent::SetClipboardText
Currently in tests (input.json) it is possible to trigger Ctrl-V using:

    { "type": "TextControl", "code": "Paste" },

But there is no way of populating the clipboard.
This patch adds AutomatedEvent::SetClipboardText, so the clipboard
may be populated before pasting:

    { "type": "SetClipboardText", "text": "<value>" },
    { "type": "TextControl", "code": "Paste" },
2024-01-11 23:22:49 +01:00
Kamil Jarosz 2ef63d3a61 avm2: Implement TextField.restrict 2024-01-11 23:22:49 +01:00
Kamil Jarosz 1c15cd55b9 avm1: Implement TextField.restrict 2024-01-11 23:22:49 +01:00
Kamil Jarosz 5feafb2ca3 avm1: Add support for onSetFocus & onKillFocus
Methods `onSetFocus` & `onKillFocus` are invoked when focus is changed
for `TextField`, `Button`, and `MovieClip`.
Multiple SWFs use these methods to listen to a focus change,
e.g. in order to implement placeholders for text fields.
2024-01-10 21:59:25 -05:00
Aaron Hill 57f6963133
render: Implement PixelBender Operation::Select (renamed from Loop) (#14503) 2024-01-11 01:04:50 +00:00
sleepycatcoding aeedec19fa avm2: Implement XML.normalize 2024-01-11 01:30:47 +01:00
Tom Schuster 629e8f89ab tests: Add a test for optimized index access from the interpreter 2024-01-10 23:18:40 +01:00
Tom Schuster f47e15b68c tests: Add a device font test using Tinos 2024-01-08 23:00:18 +01:00
Aaron Hill 6c2e28a08f Correctly handle zero-frame MovieClip
A MovieClip with zero frames can still have a child added
through ActionScript, which ticks normally.
2024-01-08 08:19:17 -05:00
renovate[bot] a328deab11 fix(deps): update rust dependencies 2024-01-08 02:59:04 +01:00
Aaron Hill 47db84473a avm2: Improve handling of Stage3D profile
We now validate the passed in profile, and return the selected profile
from 'Context3D.profile'. We don't yet alter the available
registers/textures based on the profile.
2024-01-07 22:34:33 +01:00
Aaron Hill 3156bf31ce avm2: Throw correct errors in Graphics.[drawPath,drawGraphicsData]
This is pretty straightforward, except for the fact that Flash
completely ignores the provided commands when the 'data' vector
is empty (if 'data' has even a single entry, then Flash will validate
that all of the commands have the correct amount of data to run).

One SWF that I tested relies on this behavior.
2024-01-07 19:57:47 +01:00
TÖRÖK Attila 268a1f5d18 tests: Remove most uses of exclude_warp
They no longer seem necessary with cargo nextest.
2024-01-07 05:58:13 +01:00
Tom Schuster c28be7bb5f tests: Test XML attribute name handling 2024-01-06 09:16:04 +01:00
Kamil Jarosz 47deaf50a2 core: Fix non-ASCII characters input in EditText
Casting the character to u8 and back to char caused some non-ASCII
non-control characters to be treated as control characters.
For instance the letter "ą" (U+0105) after casting to u8 and back
became ENQ (U+0005) which is a control character.
Some other letters worked, for instance the letter "ł" (U+0142)
became "B" (U+0042) and was not classified as a control character.

The test edittext_input was added to verify this behavior.
2024-01-05 13:03:43 -08:00
TÖRÖK Attila 217585daa8 chore: Delegate `[lints]` in `Cargo.toml` of all packages to the workspace 2024-01-05 11:28:19 +01:00
Lord-McSweeney 0a6a95e6f1 tests: Add a test 2024-01-03 15:14:11 +01:00
renovate[bot] 6a0a35c370 fix(deps): update rust dependencies 2024-01-01 02:44:40 +01:00
renovate[bot] 91d0520a43 fix(deps): update rust dependencies 2024-01-01 02:03:54 +01:00
Lord-McSweeney eac68a0647 tests: Add a test for accessing an unnamed Graphic 2023-12-31 07:06:08 +03:00
Aaron Hill 583327ff62 avm2: Properly set LoaderInfo.contentType from sniffed type 2023-12-29 18:40:25 -05:00
sleepycatcoding 41fb30a6a9 avm2: Do not set dispatched flag if dispatcher does not have a listener 2023-12-29 07:31:53 +03:00
Tom Schuster 28a3c7178a avm2: Check the text.engine.FontDescription properties before setting 2023-12-26 23:16:27 +01:00
renovate[bot] 216a8f3b14 fix(deps): update rust dependencies 2023-12-25 10:09:07 +01:00
Tom Schuster e3d8a279ad core: load_device_font register function must be &mut 2023-12-22 13:47:48 +01:00
nosamu a5560587da tests: Add AVM1 SWFv5 string methods test 2023-12-20 10:38:17 -08:00
nosamu d443bd9def avm1: Correctly handle undefined delimiter in String.split() 2023-12-20 10:38:17 -08:00
Aaron Hill 5c37533761 avm2: Avoid marking interface method definitions with VM_INTERNAL
Our asc.jar doesn't seem to apply a version suffix to namespaces for
interface method definitions. This was causing these methods to
get marked as VM_INTERNAL when we loaded playerglobals, preventing SWF
from invoking these methods through the interface (e.g. having a
variable of type `IEventDispatcher`, and calling `dispatchEvent` on it)
2023-12-18 21:50:34 +01:00
Aaron Hill 287ca8801a avm2: Implement AIR playerglobal versioning
This builds on our existing playerglobal versioning support
to add in AIR versioning. We closely follow the avmplus implementation:

* When an SWF is loaded, we chose either a FlashPlayer or AIR
APIVersion for its SWF version, based on our configured player runtime.
* When loading playerglobals, we look at the player runtime. In AIR
  mode, we map FlashPlayer-versioned definitions to the closest AIR
  version. This ensures that all runtime APIVersions are in the
  same series (either AIR or FlashPlayer). In FlashPlayer mode,
  all AIR-versioned definitions get mapped to VM_INTERNAL, hiding
  them from user code.

Part of our existing api versioning code was implemented incorrectly.
Within playerglobals, we need to treat all unmarked namespaces as
VM_INTERNAL - this allows things like playerglobal script
initializer "initproperty" opcodes to see any VM_INTERNAL AIR
definitions (when we run under FlashPlayer mode). Previously, we
were using AllVersions, which would result in those VM_INTERNAL
definitions being hidden from other playerglobal code, which is
not correct.

Using this support, I've added a stub for the AIR-only
'flash.net.DatagramSocket'. I've also extended the test framework
with a new 'player_options.runtime' config option, which can be
set to "AIR" or "FlashPlayer" to configure the test runtime mode.

I've also added two new tests:
* 'air_hidden_lookup' runs under the FlashPlayer runtime, and verifies
  that a list of classes (currently just "DatagramSocket" are
  inacessible).
* 'air_datagram_socket', which uses `player_options.runtime = "AIR"`
  to construct an instance of `flash.net.DatagramSocket`. We can
  extend this test once we implement more of `DatagramSocket`

With this commit, we have all of the needed infrastructure to start
implementing and testing AIR-only classes and methods.
2023-12-16 19:11:50 -05:00
Lord-McSweeney 375c99e601 core: More mixed AVM fixes, improve test
This commit breaks mixed AVM without #13889.
2023-12-16 19:40:57 +01:00
Aaron Hill 837143bb12 naga-agal: Fix handling of sampler overrides
After some testing, and looking at OpenFL, I believe I've
determined the correct behavior for AGAL sampling:

Each time a Context3D.setProgram or Context3D.setSamplerStateAt
call is made, the sampler config for the used texture slot(s)
is updated with the new wrapping/filter behavior. For setProgram,
this comes from all of the 'tex' opcodes used within the program.

However, when the 'ignoresampler' flag is set in a 'tex' opcode,
the setProgram call does *not* override the existing sampler config.
As a result, that program will sample with the behavior determined
by the most recent setSamplerStateAt or setProgram call involving
the used texture slot(s).

Previously, we were always overriding the opcode sampler config
with the values from Context3D.setSamplerStateAt. However, I didn't
realize that the order of the calls matter, so none of my tests ended
up observing the effect of 'ignoresampler'.

We now need to process AGAL bytecode twice - a quick initial
parse to determine the sampler configs (which need to be updated
when we call 'setProgram'), and a second time when to build the
Naga module (which needs to wait until we have the vertex attributes
available, which can be changed by ActionScript after setting
the program).
2023-12-15 22:05:30 -07:00
Robin Allen f427cd58bb
core: Fix mouse coords reported to ActionScript (#14243)
The order in which Flash Player concatenates matrices causes reported
mouse coords to often be rounded.
2023-12-15 23:37:52 +00:00
sleepycatcoding d21be2091b avm2: Remove ArrayObject `to_string` impl
This was causing the `Object.prototype.toString` to throw error 1050,
instead of returning `[object Array]`, which was causing quite a few avmplus test failures.
2023-12-15 23:36:33 +01:00
MrCheeze 0f6dae56b5 core: Improve spacing of device font letters (close #14185) 2023-12-15 20:14:08 +01:00
TÖRÖK Attila 9e87de1089 tests/avm2: Exclude Stage3D visual tests on WARP
As they are a prime suspects for causing hangs on CI.
2023-12-15 14:52:04 +01:00
TÖRÖK Attila bb7d2d9214 tests/avm2: Exclude PixelBender visual tests on WARP
As they are a prime suspects for causing hangs on CI.
2023-12-15 14:52:04 +01:00
TÖRÖK Attila 4e689c6c17 tests/avm2: Reduce the number of digits in Vector3D tests
This makes them pass on aarch64 (for example, Android),
it looks nicer (no secret robot math), and more digits
are not necessary anyway. Also fix up formatting a bit.
2023-12-14 01:20:45 +01:00
michiel2005 f28270376f avm1: Implement TextField.maxChars and fix pasting behavior 2023-12-12 14:06:14 -05:00
David Wendt 27e1e1477a tests: Update the seek test as we now wind up on a different frame. 2023-12-09 12:19:10 -07:00
sleepycatcoding 742ccaf705 avm2: Correctly set the return type of AS defined native methods
Previously, the return type of ActionScript defined native methods was always incorrectly set to the any (`*`) type.
2023-12-09 18:32:31 +01:00
renovate[bot] 40b92e69f7 fix(deps): update rust dependencies 2023-12-05 21:08:16 +01:00
TÖRÖK Attila 82d61faa2c avm2: Use explicitly wrapping integer arithmetic operations 2023-12-03 16:34:27 +01:00
Aaron Hill 656d41f022 tests: Add tests for early SimpleButton allocation 2023-11-30 12:49:32 -08:00
Aaron Hill 58fe23857b tests: Add missing test class files
This does not change the test behavior
2023-11-30 12:49:32 -08:00
Lord-McSweeney 1ce3ec636a avm2: Prevent `AVM1Movie`s from being moved around in the DO hierarchy 2023-11-30 07:12:37 -08:00
Lord-McSweeney 4eec6afc0e tests: Add a test for AVM1 loading AVM2 2023-11-30 07:12:37 -08:00
Lord-McSweeney b2bd91d0ac tests: Add a test for AVM1 in AVM2 2023-11-30 07:12:37 -08:00
Aaron Hill 7289a8bd95 naga-agal: Zero-extend input vectors for cross-product
This matches the behavior of Flash Player
2023-11-30 01:15:21 +01:00
renovate[bot] 6da223a875 fix(deps): update rust dependencies 2023-11-27 09:44:47 +01:00
Aaron Hill e0998642f6 core: Divide by 255 in blend_over calculation
This prevents the value from being changed when blending a
source pixel of 0x0 over a destination pixel (with alpha).
2023-11-25 22:29:30 +01:00
Lord-McSweeney f41059a60a avm2: Version-gate `JSON` to SWFv13 and above 2023-11-25 13:15:42 -08:00
Aaron Hill f12f457f5d avm2: Fix handling of public indices with nested iteration
This more closely aligns our code with the corresponding avmplus code.
A user-supplied index of '0' is special-cased, and we correctly
resume iteration when a public index mismatch is detected.
2023-11-25 21:34:48 +01:00
MrCheeze 5920a6426e core: Allow Regular/Bold/Italic device fonts to be registered separately 2023-11-24 17:08:35 +01:00
sleepycatcoding 7be2eae4b8 avm2: Implement QName enumeration 2023-11-23 19:25:08 +01:00
Aaron Hill c920ceba51 avm2: Set RUNNING_CONSTRUCT_FRAME flag inside DisplayObject ctor
This ensures that this flag is set regardless of whether the
object is constructed by the timeline or from ActionScript
(it was previously only set when constructed by the timeline).
2023-11-23 10:36:37 -05:00
Robin Allen 253b1df928 Add failing test for bug involving constructor call order 2023-11-23 10:36:37 -05:00
Robin Allen cad162121b
core: Fix MorphShape inaccuracy on complex paths (#14089)
* core: Fix MorphShape inaccuracy on complex paths

It's inaccurate to interpolate the moveTo/lineTo deltas individually
because on complex paths they're often small integers, which won't
interpolate smoothly.

Instead, interpolate absolute positions.
2023-11-21 12:41:45 +00:00
MrCheeze d23d16cb11 avm2: Report ProgressEvent when a sound is loaded (close #8932) 2023-11-20 16:14:03 -08:00
renovate[bot] 7757d060ff fix(deps): update rust dependencies to v2 2023-11-20 09:03:08 +01:00
Lord-McSweeney 5be2eb499a avm1: Copy `Activation`'s local register set when running a `catch` 2023-11-19 10:15:36 -08:00
sleepycatcoding a78a67ee24 avm2: Implement [[HasProperty]] for XMLList 2023-11-16 16:09:37 -05:00
Nathan Adams 3a55b3a5fc tests: Clean up main method a bit 2023-11-13 22:28:10 +01:00
Nathan Adams d6f16b0be5 tests: Make tests use a virtual filesystem, which currently maps to the regular physical FS rooted in a test directory 2023-11-13 22:28:10 +01:00
Tom Schuster c7a1e1178a avm2: TLF GroupElement tests 2023-11-13 21:59:29 +01:00
renovate[bot] 32c65e6460 fix(deps): update rust dependencies 2023-11-13 09:10:26 +01:00
Aaron Hill 1501a858f6 avm2: Improve E4XNode::matches_name
Avmplus constructs a full `QName`, and uses the normal
Multiname matching logic. This would be a large refactor,
so I've just modified the existing method to properly
handle multiple namespaces.

I've also included a closely related fix - we should only treat
a multiname with the literal local name "@foo" as an attribute
when the namespace is the empty public namespace. We were incorrectly
reparsing multinames that contained multiple namespaces.
2023-11-12 17:38:56 -05:00
Aaron Hill c360d45729 avm2: Use 'has_own_property' to check for prop in 'resolve_definition'
If Actionscript explicitly sets the property to 'undefined', we
should still succeed.
2023-11-12 00:38:35 +01:00
Lord-McSweeney 1bb2422595
avm2: Correctness fixes to AMF serialization (#13537)
Fixes some cases where `amf::serialize_value` returns `None`
---------

Co-authored-by: Lord-McSweeney <Lord-McSweeney@github.com>
2023-11-10 17:59:26 -08:00
sleepycatcoding e8ccbf4e2c avm2: Support enumeration for XML objects
Previously, iterating the XML object would iterate the prototype. This broke filtering expressions on XML objects, which should work.
2023-11-10 22:50:19 +01:00
Nathan Adams eb72cfb498 tests: Removed the need for test framework to depend on libtest_mimic 2023-11-10 22:02:18 +01:00
Nathan Adams 2b450af8d5 tests: Test framework doesn't need walkdir 2023-11-10 22:02:18 +01:00
Nathan Adams 7b7785e56d tests: Allow multiple renderers to handle a single test 2023-11-10 22:02:18 +01:00
Nathan Adams 8697a313ac tests: Move rendering interface into its own trait 2023-11-10 22:02:18 +01:00
Nathan Adams 86939e0e82 tests: Move TestUiBackend to backends/ui.rs 2023-11-10 22:02:18 +01:00
Nathan Adams bce0608e1f tests: Move all wgpu code out of test framework, make it abstract over any/no renderer, and make wgpu option if imgtests isn't enabled 2023-11-10 22:02:18 +01:00
Nathan Adams c36f4cfe95 tests: Move PrettyString out of lib 2023-11-10 22:02:18 +01:00
Nathan Adams 8a85a24213 tests: Move TestLogBackend to backends/log.rs 2023-11-10 22:02:18 +01:00
Nathan Adams 6a413e28f7 tests: Move TestAudioBackend to backends/audio.rs 2023-11-10 22:02:18 +01:00
Nathan Adams d1713010d2 tests: Move TestNavigatorBackend to backends/navigator.rs 2023-11-10 22:02:18 +01:00
Nathan Adams 2a2a717a06 tests: Appease clippy by implementing Default for some backends 2023-11-10 22:02:18 +01:00
Nathan Adams 673d52f013 tests: Move test framework into its own crate 2023-11-10 22:02:18 +01:00
Aaron Hill c821d0564e avm2: Use class aliases to serialize Vector type
This allows us to round-trip `Vector.<CustomType>` when
`CustomType` has an alias registered.
2023-11-09 22:01:59 -05:00
Aaron Hill 7110be920c Suport uploading ATFTextureData::CompressedRawAlpha
Fortunately, this is very simple - we can just take
the DXT5 data and upload it directly to the wgpu texture.
2023-11-10 02:00:40 +01:00
Aaron Hill 2cb1efca8c avm2: Improve AVM2 button construction handling
An Avm2 button appears to run a 'nested frame' during construction -
the same type of 'nested frame' performed by a goto. This will
run framescripts for all objects in the display hierarchy (including
orphans), resulting in an unusual child->parent framescript execution
order that DeathVsMonstars_decrypted.swf depends on.
2023-11-10 01:33:07 +01:00
Daniel Jacobs 33e9227a50 tests: Bump tolerance of acid_color_0 to accommodate runner discrepancy 2023-11-09 16:31:17 -05:00
Daniel Jacobs bee3984104 tests: Stop ignoring shumway's acid_color_0 test 2023-11-09 16:31:17 -05:00
Richy McGregor dad0bbaac8 tests: Add tests for AutoSize text 2023-11-09 21:20:10 +01:00
Nathan Adams 6061186c0f core: Fix formatting texts when they start with any amount of <br>s 2023-11-09 20:52:16 +01:00
Aaron Hill bab2a80d64 Fix vtable property amf serialization 2023-11-09 19:43:55 +01:00
Aaron Hill 10d6157755 avm2: Work on AMF3 custom object serialization 2023-11-09 19:43:55 +01:00
Aaron Hill fa05c66e2a avm2: Implement namespace versioning
This allows us to hide things like `MovieClip.isPlaying` from older
SWFs, which may define an `isPlaying` method without marking it
as an override.

This has the largest impact on public namespaces. There is no longer
just one public namespace - we now have a public namespace per API
version. Most callsites should use `Avm2.find_public_namespace()`,
which determines the public namespace based on the root SWF API version.
This ensures that explicit property access in Ruffle (e.g. calling
"toString") are able to see things defined in the user SWF.

This requires several changes other:

* A new `ApiVersion` enum is introduced, storing all of the api versions
  defined in avmplus
* NamespaceData::Namespace now holds an `ApiVersion`. When we read a
  namespace from a user-defined ABC file, we use the `ApiVersion` from
  the root movie clip. This matches Flash Player's behavior - when a
  child SWF is loaded through `Loader`, its API version gets overwritten
  with the parent's API version, which affects definition visibility and
  'override' requirements in the child SWF. Note that 'behavior changes'
  in methods like `gotoAndPlay` are unaffected.
* The `PartialEq` impl for `Namespace` has been removed - each call site must now choose
  to compare namespaces either by an exact version match, or by
  'compatible' versions (a `<=` check) with `Namespace::matches_ns`
* `PropertyMap` now uses `Namespace::matches_ns` to check for a
  compatible version when looking up a definition.
* When compiling our playerglobal, we pass in the `-apiversioning` flag,
  which causes asc.jar to convert `[API]` metadata into a special
  Unicode 'version mark' suffix in namespace URLs. We parse this
  when loading namespaces to determine the API version to use for
  playerglobal definitions (unmarked definitions use the lowest possible
  version).

Unfortunately, this makes ffdec unable to decompile our
playerglobal.swc
I've going to file an upstream issue
2023-11-09 15:27:33 +01:00
Nathan Adams fa7e7cc8c1 tests: Add tests for NetConnection with Flash Remoting, and fix implementation to match 2023-11-09 12:39:22 +01:00
Nathan Adams e6b5ac9a2b tests: Allow tests to request http://example.org/foo/bar by loading ./example.org/foo/bar 2023-11-09 12:39:22 +01:00
Nathan Adams b06926f04d tests: Print fetched byte response 2023-11-09 12:39:22 +01:00
Nathan Adams 6d901a7463 avm2: Implement many NetConnection properties 2023-11-09 12:39:22 +01:00
Nathan Adams 08c707caa6 avm2: Implement NetConnection.close() 2023-11-09 12:39:22 +01:00
Nathan Adams 1ed1dba88e tests: Document log_fetch option 2023-11-08 16:50:24 +01:00
sleepycatcoding f334963b47 avm2: Handle single element XMLLists in XML.insertChildBefore/After 2023-11-07 23:23:53 +01:00
sleepycatcoding cea636da30 avm2: Include CData nodes in XMLList.text output 2023-11-07 23:23:53 +01:00
Tom Schuster e99eaafcd0 avm2: Fix two bugs in XML/XMLList set_property_local 2023-11-07 18:12:59 +01:00
CUB3D b0d88645bc avm1: Implement FileReference 2023-11-03 19:32:24 +01:00
Nathan Adams dad39631cf avm2: Don't add ClassDefinition to AMF0 objects 2023-11-03 02:17:40 +01:00
Tom Schuster 8138b68919 avm2: Implement XML.setChildren 2023-11-02 13:40:16 +01:00
Tom Schuster 3572367c8e avm2: Allow assigning XML objects without a name (eg. text) 2023-11-01 18:44:36 +01:00
renovate[bot] 1377a5b07b fix(deps): update rust dependencies 2023-11-01 00:45:43 +01:00
Nathan Adams 36eda35197 avm2: Implement Font.registerFont 2023-10-30 15:49:07 +01:00
Nathan Adams 9ecb7d221f avm2: Implement Font.enumerateFonts 2023-10-30 15:49:07 +01:00
Tom Schuster 72965b3689 amv2: Implement flash.xml.XMLNode removeNode 2023-10-30 14:30:59 +01:00
Tom Schuster 445643fedb amv2: Implement flash.xml.XMLNode cloneNode 2023-10-30 14:30:59 +01:00
sleepycatcoding fb3c4cd307 avm2: Fix E4X [[Replace]] implementation bug
We were incorrectly returning for XML attributes. Fixes #13780.
2023-10-30 14:05:23 +01:00
sleepycatcoding 5bebebddbe avm2: Add SWFv21 and above XML special case 2023-10-29 09:43:14 -07:00
nosamu 6f5eb48ec2 avm2: Fix return value of SharedObject.flush 2023-10-29 16:08:24 +01:00
Aaron Hill cc49aaee58 avm2: Add UTF-16 BOM handling to ByteArray.toString
When a UTF-16 BOM is present, ByteArray.toString automatically
strips it out, and treats the remaining data as a UTF-16 string
with the specified endianness.
2023-10-29 01:13:05 +02:00
Aaron Hill 84f788c2d2
avm2: Use RawTable to implement 'public index' iteration (#12470)
* avm2: Use RawTable to implement 'public index' iteration

This makes our implementation more closely aligned with avmplus.
In particular, it's now possible to delete keys from an object
while iterating without disturbing the iteration order (as long
as those keys were already produced by the iterator).

This is based on @Bale001's work on RawTable-based iteration

A few tests had their output changed (they depend on the exact
object iteration order, and don't neccessarily match Flash Player
exactly).

* Use Cell to store index fields

* Remove outdated comment
2023-10-28 20:44:01 +00:00
Tom Schuster 33dde1eccf avm2: Ignore a missing [[TargetProperty]] when assigning an XMLList 2023-10-28 08:18:15 -07:00
sleepycatcoding ed6fa6b2fe avm2: Support indices in XMLList.child 2023-10-27 22:53:16 +02:00
michiel2005 ee9237681b tests/avm1: Added test for key.isToggled 2023-10-26 17:39:14 -04:00
Aaron Hill b5097445e6 render: Add support for Context3DTextureFormat.COMPRESSED_ALPHA
This is our first non-rgba texture format (it uses Bc3RgbaUnorm).
ATF files store these textures in a very convoluted way - fortunately,
the 'dds2atf' tool is open-source, which allowed me to figure out
how to decode the texture back to a DXT5/DXT1 texture.
2023-10-23 11:18:27 -04:00
sleepycatcoding bb053df30b avm2: Implement XMLList.parent 2023-10-23 15:46:47 +02:00
sleepycatcoding 2745efe2b1 avm2: Throw error 1010 when null/undefined is given to name_to_multiname 2023-10-23 15:26:37 +02:00
renovate[bot] cd01bfe7d6 fix(deps): update rust dependencies 2023-10-23 02:55:11 +02:00
Lord-McSweeney 47442ddd32 tests: Add a test for `textInput` event 2023-10-22 08:01:18 -07:00
Lord-McSweeney 5f217a6b9a avm2: Improve quick_xml to AVM2 XML error conversion 2023-10-21 11:41:57 -07:00
Lord-McSweeney 4de186e18a tests: Activate passing test 2023-10-21 11:41:57 -07:00
Lord-McSweeney 901d84b2cf avm2: Fix defining const slots on global object 2023-10-21 11:41:57 -07:00
Lord-McSweeney 18c53694cb avm2: Implement Error 1070 2023-10-21 11:41:57 -07:00
Lord-McSweeney b1056311f0 avm2: Implement Error 1112 2023-10-21 11:41:57 -07:00
Aaron Hill 5d4e851a6e avm2: Throw ArgumentError when calling function with wrong arg count
Some SWFs rely on catching the error.

In order to reproduce Flash's error messages, we now store a `QName`
in `FunctionObject`, which is set when we make a bound method.
2023-10-21 00:18:50 -04:00
Nathan Adams feacbdc118 core: <font> tag in text should reset the style to Regular 2023-10-20 12:41:15 +02:00
Nathan Adams 64385efe48 core: Use correct embedded font fallback order + tests 2023-10-20 12:41:15 +02:00
sleepycatcoding 8021efaabc avm2: Do not panic in XML call handler
This panic occurred when the call handler was passed zero arguments.
2023-10-19 20:52:33 +02:00
sleepycatcoding 5da09c137e avm2: Implement QName call handler 2023-10-19 11:46:31 +02:00
Aaron Hill fd4d6921d8 avm2: Don't stop root movie clip, even if it doesn't extend `MovieClip`
Normally, Flash Player will ignores frames for a movie clip with
a symbol class that doesn't extend `MovieClip` (e.g. it extends
`Sprite`). However, the root movie appears to have frame run
unconditionally, even if it only extends `Sprite`. This can
be observed by adding a Graphics child in the second frame only -
the child will flicker in and out as the player switches between
frames, but only for the root movie clip.

Seedling relies on this behavior - it has `DoAbc2` tags in the second
frame, and has a main `Preloader` class that extends `Sprite`.
2023-10-18 09:28:50 -04:00
Adrian Wielgosik b02038bcd2 avm1: Add a test for .childNodes edge cases 2023-10-16 11:25:48 +02:00
renovate[bot] b427940431 fix(deps): update rust dependencies 2023-10-16 09:51:22 +02:00
Nathan Adams ec21ad8658 core: Add default_font feature which enables the fallback font 2023-10-15 14:09:21 +02:00
Lord-McSweeney acecaabd0e tests: Activate newly passing tests 2023-10-13 20:22:00 +02:00
David Wendt 18f78233ac tests: Add `output.expected.png` file to `avm2/netstream_seek_flv` 2023-10-10 18:49:09 -06:00
David Wendt 0fc3465443 chore: I deleted one too many lines 2023-10-10 18:49:09 -06:00
David Wendt 81740d09f7 tests: Change seek test output to match test harness timing.
We are not interested in testing the timing of buffer loads (since that will vary based on hardware), we just need to know that we got a buffer load event.

Furthermore all our seeks are in-buffer so multiple buffer full events shouldn't happen in Ruffle.
2023-10-10 18:49:09 -06:00
David Wendt 87b9cf2fa0 tests: Remove all time assertions from the seek test as our test harness and loader impl screws up timing 2023-10-10 18:49:09 -06:00
David Wendt 525165caf6 tests: Change AVM2 version of the `netstream_seek_flv` test to wait for video to play before tracking time and seeking. 2023-10-10 18:49:09 -06:00
David Wendt d3335f4dc4 tests: Add AVM1 version of `netstream_seek_flv` 2023-10-10 18:49:09 -06:00
David Wendt 008427e490 tests: Work around our test harness not loading videos syncronously 2023-10-10 18:49:09 -06:00
David Wendt 5cf005e69e tests: Add test for seeking NetStream on AVM2 2023-10-10 18:49:09 -06:00
renovate[bot] 18796a67fe fix(deps): update rust dependencies 2023-10-10 02:15:59 +02:00
sleepycatcoding 21a1e1f670 avm2: Small set_property_local fixup
Fixes a borrow panic and logic error.
2023-10-10 00:24:39 +02:00
sleepycatcoding 0b2771c23d avm2: Implement other XMLList set_property_local path 2023-10-10 00:24:39 +02:00
sleepycatcoding ca5ba4877c avm2: Implement one XMLList set_property path 2023-10-10 00:24:39 +02:00
Tom Schuster c6804be307 avm2: Add smoke test for namespace issue in monopoly 2023-10-07 23:46:40 +02:00
Tom Schuster ed1a2ee27c avm2: Add failing namespace test for flash.xml 2023-10-07 23:46:40 +02:00
Aaron Hill 3a658f5dec avm2: Implement BitmapData.copyPixelsToByteArray
This basically just re-uses the implementation of getPixels
2023-10-05 17:35:54 -04:00
sleepycatcoding 80ccc1d8a3 avm2: Implement some obscure SWFv9 XML behavior
This affects appendChild, prependChild, insertChildBefore, insertChildAfter.
2023-10-05 16:12:43 +02:00
Aaron Hill ddefac322a avm2: Run DoAbc/DoAbc2/SymbolClass as part of their frame
We previously ran these tags during preloading - however,
they are actually run as part of frame execution. This is observable
by ActionScript - a SWF can load in a class from a stop()'d MoveClip,
and then advance the clip to a frame with a SymbolClass referencing
the loaded class.
2023-10-04 22:00:22 -04:00
renovate[bot] 428e89af73 fix(deps): update rust dependencies 2023-10-04 19:19:51 -04:00
sleepycatcoding 09716b8386 tests: make jpegxr optional 2023-10-03 16:08:51 -04:00
Tom Schuster 6d51bc3964 avm2: Namespace support for XML.name() 2023-10-01 19:26:07 +02:00
sleepycatcoding f140e7a14b
core: Place jpegxr texture support behind feature flag (#13348) 2023-09-29 18:46:54 -04:00
Aaron Hill ec7a8ac645
avm2: Add support for Stage3D bytearray/compressed textures (#13180) 2023-09-28 03:03:30 +00:00
renovate[bot] 7e4e4d4c5b fix(deps): update rust dependencies 2023-09-25 11:14:39 +02:00
Lord-McSweeney 1adde21a9b avm2, tests: Improve String.substr; add a complex test 2023-09-24 12:11:24 +02:00
Aaron Hill 8aec2f1703 Add another test 2023-09-23 14:11:24 +02:00
Aaron Hill bb4410e387 avm2: Skip nested 'goto' frame for SWF 9
This fixes 'who_killed_travolta', and unblocks DeathvsMonstars and
NeoPets Lost City Lanes once some additional button fixes are merged.

This isn't 100% correct (as shown by the disabled test), but it brings
us closer to what Flash Player does.
2023-09-23 14:11:24 +02:00
nosamu e8bbb21554 avm1: tellTarget on an undefined object targets the base clip in SWF6- 2023-09-23 13:42:03 +02:00
Tom Schuster dc53758488 avm2: Implement support for indexes in xml.child() 2023-09-22 21:28:20 +02:00
renovate[bot] 37e2c06034 fix(deps): update rust dependencies 2023-09-18 00:00:45 +02:00
Lord-McSweeney 6eddd3532e avm2: Support Error 1089 2023-09-17 22:03:05 +02:00
sleepycatcoding ecbf325d41
avm2: Improve XML set_property_local implementation (#13041)
* avm2: Add error 1087

* avm2: Add deep_copy method to XmlObject

Changes existing AS3 copy method to use this instead

* avm2: Add a few utility methods to E4XNode

* avm2: Change XML.replace impl to use new utility methods

* avm2: allow setting XML/XMLList as a element

* avm2: Fix `xml_namespaced_property` test failure

* chore: fmt

* chore: Appease clippy

* avm2: Add test for XML/XMLList as element
2023-09-14 21:33:32 +00:00
sleepycatcoding b5fdd9142f avm2: Coerce value in set slot opcode
This was causing a bunch of implicit conversion test failures.
2023-09-13 23:02:44 +02:00
Aaron Hill 981dedafd2 avm2: Fix avmplus.describeTypeJSON bugs and add test 2023-09-08 17:52:12 -04:00
Lord-McSweeney 20db9f8326
avm2: Implement XML.setName (#12979)
* avm2/tests: Implement XML.setName; add a test

* avm2: Basic support for QNames in XML.setName (no namespace support yet)

* avm2: Reorder order of Attribute/Element/PI checks in XML.setName

* avm2: Throw error #1117 when the name passed to XML.setName is not a valid XML name
2023-09-07 21:47:02 +02:00
sleepycatcoding 9c7eb90d69 avm2: Implement XML.prependChild 2023-09-07 01:13:16 +02:00
sleepycatcoding 936eb777e8 avm2: Implement isXMLName 2023-09-06 23:01:34 +02:00
renovate[bot] dabc2d56b9 fix(deps): update rust dependencies 2023-09-04 10:25:24 +02:00
Lord-McSweeney 5edba670de tests: Add a test for using Shared Objects without a root movie 2023-08-31 19:58:53 -04:00
Daniel Jacobs 7bef26d993 tests: Add test for avm2 Sound constructor with URLRequest parameter 2023-08-30 22:41:49 +02:00
Abiel Deneke 0ed447b428 avm1: Set target clip to None if target is an undefined object
SetTarget currently sets the target clip to the base clip if the
target passed to tellTarget() is an undefined object. This causes
goto's to run on the base clip in Ruffle, when Adobe Flash Player
does not run the goto's at all.

Fixes #12389 and #12390
2023-08-29 01:23:52 +02:00
sleepycatcoding 80db9caf74 avm2: Implement XML.replace 2023-08-29 00:48:48 +02:00
sleepycatcoding fbaa02e295 avm2: Implement XML.insertChildAfter and XML.insertChildBefore 2023-08-29 00:48:48 +02:00
TÖRÖK Attila 7dc70354bf tests: Exclude WARP from running acid_large, and allow acid_image and acid_gradient_* again 2023-08-28 21:24:01 +02:00
renovate[bot] 4e75c3890a fix(deps): update rust dependencies 2023-08-28 07:39:35 +02:00
Aaron Hill 88acc96467 avm2: Fix XML/XMLDocument ignoreWhite handling for cdata
The ignoreWhite settings only affect text nodes, not cdata nodes.
Additionally, there should be no special case for empty text.
2023-08-27 20:28:20 -04:00
sleepycatcoding 33164d3f56 avm2: Preserve attribute flag when filling lazy multiname with QName
Fixes #12570
2023-08-27 19:40:00 -04:00
Aaron Hill 879dac347c avm2: Handle child being removing from `Loader`
`Loader` override `removeChild` and `removeChildAt` to try to prevent
user code from removing the loaded content child. However, this can be
bypassed by calling `otherContainer.addChild(loader.content)`, which
actually removes the child from the loader. Stealth Hunter 2 relies
on this behavior.

To make this work, `Loader.content` needs to go through
`contentLoaderInfo`, instead of relying on a child being present.
2023-08-27 19:13:45 -04:00
Nathan Adams 19ad492eaa avm2: Implement Graphics.cubicCurveTo and CUBIC_CURVE_TO 2023-08-27 20:17:43 +02:00
TÖRÖK Attila d523be02e4 tests: Exclude WARP from running the acid_gradient_1 visual test ported from Shumway 2023-08-27 12:25:41 +02:00
Lord-McSweeney 72c659fd0e avm2: Add some static properties to Number 2023-08-26 13:38:33 +02:00
Lord-McSweeney d366d19de6 avm2: Various (u)int/Number correctness fixes 2023-08-26 13:38:33 +02:00
sleepycatcoding 75566b92e0 avm2: XML/XMLList is converted to a string when set as attribute value 2023-08-25 11:20:51 +02:00
David Wendt 7158039135 audio: Audio streamed from FLVs do not have the SWF MP3 header 2023-08-23 15:36:20 -06:00
nosamu 20b07ff147 avm1: Fix XML=>String coercion mangling non-ascii chars
Fixes #12859
2023-08-22 17:23:56 +02:00
nosamu 2f40f0093a avm1: Unescape + to space 2023-08-22 16:38:24 +02:00
sleepycatcoding 991976e437 avm2: Implement XML pretty printing 2023-08-22 09:57:59 -04:00
renovate[bot] 2f4c7d2fe3 fix(deps): update rust dependencies 2023-08-21 08:59:07 +02:00
Nathan Adams 385c2d7cb0 core: Fix links in TextEdits when scrolled down 2023-08-20 22:31:27 +02:00
Nathan Adams f0d356589a core: Implement avm2 event: links in texts 2023-08-20 22:31:27 +02:00
Nathan Adams 814a900b03 avm1: asfunction goes by the parent, not root 2023-08-20 22:31:27 +02:00
Nathan Adams b8cda975f3 core: Allow clicking EditTexts if we're clicking links 2023-08-20 22:31:27 +02:00
Nathan Adams 658ac2dd9f core: Implement url handling (+asfunction) in textedits 2023-08-20 22:31:27 +02:00
TÖRÖK Attila a11725c27c tests: Exclude WARP from running the acid_gradient_2 visual test (ported from Shumway)
This was the culprit for most of our recent Windows CI failures.
2023-08-20 12:49:37 +02:00
Kornelius Rohrschneider a50f5cd072 avm1: Remove delay to enter the unloaded state for non-root MovieClips
avm1_unload_movie has been adapted to only enter the unloaded state with
one frame delay if the MovieClip is a root MovieClip. The unloaded state
is now immediately entered for non-root MovieClips.
This fixes the regressions #12254 and #12265 which got introduced
because of this delay.

However, in Flash Player, even non-root MovieClips enter the unloaded
state one frame after the unloadMovie command has been read. Ruffle is
probably replacing a MovieClip differently to Flash, therefore
introducing these regressions when trying to emulate that delay.
Documentation explaining this all has been added to avm1_unload_movie.

Therefore, the test movieclip_library_state_values has been added. It
tests the default state and the unloaded state of a (non-root) child
MovieClip that's loaded from the library. It is marked as known_failure
because Ruffle currently doesn't implement the delay before entering the
unloaded state for non-root MovieClips.
2023-08-19 17:29:00 +02:00
nosamu 050da0740a avm1: Pass flashvars in loadMovie and MovieClipLoader
Fixes #11497
2023-08-19 16:45:01 +02:00
Lord-McSweeney 89b9bc3827 core/avm2: Support accessing applicationDomain on a LoaderInfo before load starts/finishes; also improve Loader.unload stub. 2023-08-19 00:24:03 +02:00
Nathan Adams a6aa72351f avm2: Add a Function() call handler 2023-08-18 22:13:46 +02:00
Nathan Adams 7df861f212 avm2: Disallow 'new Function(args)' 2023-08-18 22:13:46 +02:00
Nathan Adams f2233855c7 avm2: Throw proper error on 'x is SomethingThatIsntAClass' 2023-08-18 22:13:46 +02:00
Nathan Adams 46381d181a avm2: Use correct error when trying to construct something invalid 2023-08-18 22:13:46 +02:00
Nathan Adams 8bbf8f4ea1 avm2: Use correct error in toString with invalid radix 2023-08-18 22:13:46 +02:00
Nathan Adams c9c2e213bb avm2: Use correct error in toPrecision 2023-08-18 22:13:46 +02:00
sleepycatcoding 2f98da44fb avm2: String.indexOf returns -1 when passed in undefined 2023-08-18 20:41:41 +02:00
sleepycatcoding cde49de1fb avm2: Remove undefined specific behavior in String.split 2023-08-18 20:41:41 +02:00
sleepycatcoding a44546ab1c avm2: Do not ignore nulls in String.fromCharCode 2023-08-18 20:41:41 +02:00
sleepycatcoding 7316f51cb1 avm2: String.toString defaults to "" 2023-08-18 20:41:41 +02:00
sleepycatcoding b835cc8091 avm2: Boolean.valueOf and Boolean.toString default to false
Makes tests `e15_6_3_1`, `e15_6_3_1_3`, `e15_6_4`, `e15_6_4__1` and `ecall_1` pass.
2023-08-18 16:07:15 +02:00
nosamu f3feabb59a avm2: nextScene() and prevScene() should fall back to current scene
Fixes #12797
2023-08-18 00:33:32 +02:00
nosamu 5618ebe6eb tests: Add failing test for queued gotos in AVM2 framescripts
This minimally reproduces #12069 and #10113
2023-08-17 22:46:38 +02:00
Nathan Adams f00671e9cc core: Fix rendering masks + scrollRects when cacheAsBitmap 2023-08-16 16:34:24 +02:00
Aaron Hill b1981debc9 tests: Include test name in error context 2023-08-15 17:04:28 +02:00
Tom Schuster d93c449199 avm2: Throw TypeError on unbound namespace prefix 2023-08-14 19:58:21 +02:00
Tom Schuster 7639d045ad avm2: Limited XML namespace support 2023-08-14 19:58:21 +02:00
Nathan Adams 5e1a30cf4a core: Fix avm2 button bounding box when using scroll rects 2023-08-13 14:14:34 +02:00
Nathan Adams db7c6dec00 core: Implement XML.toString for comments and processing instructions 2023-08-12 20:15:21 +02:00
Nathan Adams bf7c17737b avm2: Trim the start of processing instruction values 2023-08-12 20:15:21 +02:00
Nathan Adams 90b3fa4c63 avm2: Implement to_xml_string_inner for procesing instructions 2023-08-12 20:15:21 +02:00
Nathan Adams f4216aefc1 avm2: Implement XMLList.comments() 2023-08-12 20:15:21 +02:00
Nathan Adams d9847d0167 tests: Rename some files because windows is dumb and they're too long I guess 2023-08-12 17:37:17 +02:00
TÖRÖK Attila 0591fd882a tests: Update displacement_map expected output. 2023-08-12 14:15:40 +02:00
Nathan Adams adda66723e core: Use filters to calculate render sizes of objects 2023-08-12 13:00:27 +02:00
Nathan Adams d35b2b8b84 core: Inform Bitmaps to invalidate, if their backing BitmapDatas change 2023-08-12 11:56:18 +02:00
Nathan Adams e73cd91283 tests: Fix running tests without img_tests feature 2023-08-11 20:15:24 +02:00
Nathan Adams 1858db65c4 tests: Add known_failure test for CABs containing grown filters 2023-08-11 11:23:03 +02:00
Nathan Adams f55147d7c3 core: Override render_bounds_with_transform in Avm2Button 2023-08-11 11:23:03 +02:00
Nathan Adams a9c5bdfbab core: Better handle scroll_rect and/or masks with cacheAsBitmap 2023-08-11 11:23:03 +02:00
Nathan Adams b1aeb010a4 tests: Add CAB + Masks test 2023-08-11 11:23:03 +02:00
TÖRÖK Attila fb01473bb3 tests: Exclude WARP from shumway_acid_tests/acid_image, it was flaky 2023-08-09 21:04:59 +02:00
TÖRÖK Attila 0c4bb22491 chore: Update dependencies of the crates within tests. 2023-08-08 23:19:16 +02:00
MrCheeze 68f8cd6149 avm2: Remove focus from an EditText when it unloads (close #12092) 2023-08-07 23:16:06 +02:00
Nathan Adams bdd2a7ea9e tests: Allow capturing images on specific frames/ticks 2023-08-07 22:52:10 +02:00
Nathan Adams ca8fc23a6c tests: Allow fscommand("captureImage", "IMAGE_NAME") 2023-08-07 22:52:10 +02:00
Nathan Adams 1c8724a458 tests: Turn image_comparison into image_comparisons.NAME, allowing multiple comparisons per test 2023-08-07 22:52:10 +02:00
Nathan Adams 42b4812601 avm2: Throw error when using descendants op (..) on anything that isn't XML, even if it has descendants property 2023-08-06 10:51:25 +02:00
michiel2005 690ce110d8
avm1: reference displayObjects parents if parent is a button (#12541) 2023-08-05 20:32:03 +00:00
sleepycatcoding aac1931569 avm1: Prevent panic when close is called in event handler
Also adds a test case for this.
2023-08-05 14:42:09 +02:00
sleepycatcoding d8ae2ce6b9 avm1: Fix only one message arriving when multiple are sent in the same packet
Test case has been improved to cover this.
2023-08-05 14:42:09 +02:00
sleepycatcoding cec74242cf core: Socket subsystem fixes
Clears the read and write buffer of Socket before returning to ActionScript, this could potentially be problematic
when a SWF reuses the same Socket to connect.

Also remove the handle from Arena when server closes the connection, this fixes
connected still returning true after server disconnection.
2023-08-05 14:42:09 +02:00
sleepycatcoding 0a1f645177 tests: Add onData test for XMLSocket 2023-08-05 14:42:09 +02:00
sleepycatcoding 43e1e72258 tests: Add AVM1 XMLSocket test 2023-08-05 14:42:09 +02:00
sleepycatcoding 1c0426a747 tests: Expand test case as per review 2023-08-05 14:17:02 +02:00
sleepycatcoding e8bc47a569 avm2: Return correct error if Event.clone() returns null 2023-08-05 14:17:02 +02:00
sleepycatcoding 925ed2e82b avm2: Clone event if it has been dispatched before 2023-08-05 14:17:02 +02:00
Nathan Adams fc54c111c3 tests: Port avmplus as3 AMF test 2023-08-04 16:29:27 +02:00
Nathan Adams 5f200dc2a9 avm2: Use correct error in write ops when reading past bounds 2023-08-03 16:28:25 +02:00
Nathan Adams af46301020 avm2: Use correct error in Li ops when reading past bounds 2023-08-03 16:28:25 +02:00
Nathan Adams 3d76953574 avm2: Use correct error when accessing domain memory out of bounds 2023-08-03 16:28:25 +02:00
Nathan Adams c3a283e23d tests: Port avmplus MOPS tests 2023-08-03 16:28:25 +02:00
sleepycatcoding 85db727f17 avm2: Implement XMLSocket 2023-08-02 22:16:16 +02:00
Nathan Adams 3834462abf avm2: Hook up XMLDocument.ignoreWhite 2023-08-02 15:55:08 +02:00
Nathan Adams 6f2420d983 avm2: Implement ignoreComments/ignoreProcessingInstructions/ignoreWhitespace 2023-08-02 15:55:08 +02:00
Nathan Adams da7ee01730 avm2: Implement XML.settings/XML.setSettings/XML.defaultSettings, and add appropriate properties to XML class 2023-08-02 15:55:08 +02:00
Nathan Adams 10e59067d0 avm2: Rewrote XMLDocument/XMLNode to be more correct 2023-08-02 15:55:08 +02:00
Lord-McSweeney 84e4215ece avm2+tests: Various Vector-related fixes; activate now-passing Vector tests 2023-08-02 15:26:53 +02:00
relrelb 006393c581 chore: Appease nightly clippy 2023-08-01 22:44:00 +03:00
TÖRÖK Attila f036fd7aff tests/visual: Also test DisplacementMapFilter with componentX or componentY of 0 2023-08-01 12:54:56 +02:00
Adrian Wielgosik 2621dd78ee avm2: Vector doesn't support propertyIsEnumerable 2023-08-01 00:13:46 +02:00
Adrian Wielgosik b61e92ee12 avm2: Fix property_is_enumerable on arrays 2023-08-01 00:13:46 +02:00
sleepycatcoding a40e8d8ac4 tests: Split read/writeObject off into a separate test 2023-07-31 22:32:03 +02:00
sleepycatcoding cd9ed1a1da tests: remove unneeded loops 2023-07-31 22:32:03 +02:00
sleepycatcoding 1b765e2a45 tests: Use new socket API 2023-07-31 22:32:03 +02:00
sleepycatcoding 749ba80c8a tests: Lower socket test task timeout to 1 microsecond
This was hiding the fact that the test technically did not run and failed, as it only happened very rarely in some scenarios.
2023-07-31 22:32:03 +02:00
Nathan Adams 91bfbe6ab1 tests: Port avmplus as3 MethodClosures test 2023-07-31 19:52:12 +02:00
Nathan Adams 4de8301f75 tests: Port avmplus as3 RuntimeErrors test 2023-07-31 19:52:12 +02:00
Nathan Adams 27fc81f0f3 tests: Port avmplus as3 Dictionary test 2023-07-31 19:52:12 +02:00
Nathan Adams 9ba9ec17a7 tests: Port avmplus as3 e12_6_3_12 Statement test 2023-07-31 19:52:12 +02:00
Nathan Adams cc302a56de tests: Port avmplus as3 for-each-in tests 2023-07-31 19:52:12 +02:00
Nathan Adams d6f83ce9c3 tests: Port avmplus es3 switch tests 2023-07-31 19:52:12 +02:00
Nathan Adams 98f9316fa7 tests: Port avmplus es3 Int tests 2023-07-31 19:52:12 +02:00
Nathan Adams b42ae15759 tests: Port avmplus es3 Number tests 2023-07-31 19:52:12 +02:00
Nathan Adams dab0779493 tests: Port avmplus es3 uint tests 2023-07-31 19:52:12 +02:00
Nathan Adams 01bacb51ba tests: Port avmplus es3 Type Conversions tests 2023-07-31 19:52:12 +02:00
Nathan Adams cdc8e65f0c tests: Port avmplus es3 const tests 2023-07-31 19:52:12 +02:00
Nathan Adams c903c0081c tests: Port avmplus es3 ClassDef tests 2023-07-31 19:52:12 +02:00
Abiel Deneke 6552b4e132 avm2: Implement `Matrix3D.prependScale` 2023-07-31 17:00:44 +02:00
TÖRÖK Attila 288ed7e341 tests: Add an avm1 visual test for BitmapData::perlinNoise() 2023-07-31 16:41:01 +02:00
Adrian Wielgosik 399ac2490c avm2: Remove accidentally duplicated tests 2023-07-30 18:05:24 +02:00
Nathan Adams 647b49ad52 tests: Move from_avmplus up one level 2023-07-30 13:59:33 +02:00
Nathan Adams c8a86966b0 tests: Port avmplus e4x XMLList tests 2023-07-30 13:59:33 +02:00
Nathan Adams 2e1f848144 tests: Port avmplus e4x XML tests 2023-07-30 13:59:33 +02:00
Nathan Adams 0ac0ea21c5 tests: Port avmplus e4x Types tests 2023-07-30 13:59:33 +02:00
Nathan Adams f97559066b tests: Port avmplus e4x TypeConversion tests 2023-07-30 13:59:33 +02:00
Nathan Adams 068a4b38ac tests: Port avmplus e4x Regress tests 2023-07-30 13:59:33 +02:00
Nathan Adams 8a0e57ca95 tests: Port avmplus e4x Namespace tests 2023-07-30 13:59:33 +02:00
Nathan Adams 6030ed563b tests: Port avmplus ecma3 Number tests 2023-07-30 13:59:33 +02:00
Nathan Adams 495f19f10d tests: Port avmplus ecma3 ObjectObjects tests 2023-07-30 13:59:33 +02:00
Nathan Adams e25c18beed tests: Port avmplus ecma3 Statements tests 2023-07-30 13:59:33 +02:00
Nathan Adams 04dbff285a tests: Port avmplus ecma3 String tests 2023-07-30 13:59:33 +02:00
Nathan Adams b7f6373af3 tests: Port avmplus ecma3 TypeConversion tests 2023-07-30 13:59:33 +02:00
Nathan Adams e08e9cc14b tests: Port avmplus ecma3 instanceof tests 2023-07-30 13:59:33 +02:00
Nathan Adams 9c12d3134a tests: Port avmplus ecma3 ErrorObject tests 2023-07-30 13:59:33 +02:00
Nathan Adams e707e98487 tests: Port avmplus ecma3 Boolean tests 2023-07-30 13:59:33 +02:00
Tom Schuster f237aa1da2 avm2: Implement XMLNode.nodeValue 2023-07-30 11:14:00 +02:00
TÖRÖK Attila acddd6c26d tests: Add glow_pass_scaling visual test 2023-07-29 22:23:49 +02:00
TÖRÖK Attila 24afc21f87 tests: Remove redundant "test" suffix from the name of blur_pass_scaling_test 2023-07-29 22:23:49 +02:00
Aaron Hill 4406a70fc9 avm2: Enable Vector.<ObjectSubclass> serialization tests
This also fixes a minor bug (we should always deserialize
to a `Vector.<Object>`, not a `Vector.<*>`)
2023-07-29 15:30:24 -04:00
Nathan Adams f9be8be99e avm2: Make 'new Math()' and 'Math(value)' throw errors 2023-07-29 15:24:30 +02:00
Adrian Wielgosik 456e9d2c05 avm2: Extend vector_concat test 2023-07-28 23:42:04 +02:00
Adrian Wielgosik 22d7ffdefc avm2: fix Vector null display 2023-07-28 23:42:04 +02:00
Adrian Wielgosik e1d73f031a avm2: Activate the Vector/specialized_at_runtime test 2023-07-28 23:42:04 +02:00
Nathan Adams 8be0a36b1a tests: Port avmplus ecma3 Array tests 2023-07-28 22:22:47 +02:00
Nathan Adams 90b4653eaf tests: Port avmplus ecma3 Exception tests 2023-07-28 22:22:47 +02:00
Nathan Adams a52bed18bd tests: Port avmplus ecma3 FunctionObjects tests 2023-07-28 22:22:47 +02:00
Nathan Adams 684c0ea5e6 tests: Port avmplus ecma3 GlobalObject tests 2023-07-28 22:22:47 +02:00
Nathan Adams d3606e3c9d tests: Port avmplus ecma3 Types tests 2023-07-28 22:22:47 +02:00
Nathan Adams a8410aa34e tests: Port avmplus ecma3 ExecutionContexts tests 2023-07-28 22:22:47 +02:00
Nathan Adams 1a354d5809 tests: Port avmplus ecma3 Expression tests 2023-07-28 22:22:47 +02:00
Nathan Adams 8ff5ff8176 tests: Port avmplus ecma3 Function tests 2023-07-28 22:22:47 +02:00
Nathan Adams e1749cd0ad tests: Port avmplus ecma3 Unicode tests 2023-07-28 22:22:47 +02:00
Lord-McSweeney cf5c02ca1b avm2+tests: Fully implement XML.appendChild, add a test 2023-07-28 15:21:38 +02:00
Lord-McSweeney cf8dde966f tests: Allow avmplus e4x/Global/e13_1_2_1 to run, since it no longer loops indefinitely 2023-07-28 13:11:15 +02:00
sleepycatcoding 46d6d6724d tests: Allow some avmplus tests as they now succeed 2023-07-27 23:39:06 +02:00
sleepycatcoding 04aa060c61 tests: Check XML/XMLList.parent() in xml_list_concat 2023-07-27 23:39:06 +02:00
sleepycatcoding 02d815e86b avm2: Implement XML addition operations 2023-07-27 23:39:06 +02:00
Nathan Adams 70fb674d8b avm2: Implement correct errors for write_bytes with offset+length > u32::MAX 2023-07-27 19:47:16 +02:00
Nathan Adams 1bbefbe472 avm2: Throw correct error when writing a too-large string to ByteArray 2023-07-27 19:47:16 +02:00
Nathan Adams 0d1d110660 tests: Port avmplus ByteArray tests 2023-07-27 19:47:16 +02:00
Nathan Adams 7dc0224451 tests: Add lzma feature and add a required_features.lzma flag 2023-07-27 19:47:16 +02:00
Nathan Adams 08b7a8c498 tests: Port avmplus e4x QName tests 2023-07-27 19:30:41 +02:00
Nathan Adams e88a03c2d5 tests: Port avmplus e4x Statements tests 2023-07-27 19:30:41 +02:00
Nathan Adams cbf029c019 tests: Port avmplus e4x Global tests 2023-07-27 19:30:41 +02:00
Nathan Adams 28dfcab8ff tests: Port avmplus e4x Expression tests 2023-07-27 19:30:41 +02:00
Nathan Adams 4f315ef6a9 tests: Include PrettyString workaround again 2023-07-27 19:30:41 +02:00
Nathan Adams cb23067382 avm2: Implement UninitializedError 2023-07-27 09:49:47 +02:00
Nathan Adams 5fc37c7e13 avm2: Implement call handler for Error 2023-07-27 09:49:47 +02:00
Nathan Adams 55d77970e0 tests: Port avmplus Exception tests over 2023-07-27 09:49:47 +02:00
Aaron Hill 583caa3389
avm2: Implement DisplayObject.blendShader (#12238) 2023-07-26 23:25:26 +00:00
Nathan Adams 6a7063a83b tests: Mark vectorIndexRangeExceptions as ignore again, and explain why 2023-07-27 00:52:40 +02:00
Nathan Adams 1ffb87c227 tests: If an image test isn't being checked and we expect it to fail, make it fail 2023-07-27 00:52:40 +02:00
Nathan Adams 049cb0e84d tests: Increase tolerance of bitmapdata_applyfilter_blur to make it pass on my machine 2023-07-27 00:52:40 +02:00
Nathan Adams bdf960f972 tests: Unflagged previously ignored tests that now pass successfully 2023-07-27 00:52:40 +02:00
Nathan Adams a10dfca653 tests: Change a lot of tests from ignore to known_failure 2023-07-27 00:52:40 +02:00
Nathan Adams 6063579fbd tests: Add known_failure to test.toml 2023-07-27 00:52:40 +02:00
Aaron Hill 99ed2c6d4a
avm2: Fix handling of default domain memory (#12308) 2023-07-26 18:26:26 +00:00
Nathan Adams 0a21a6015c tests: Document fscommand('quit') 2023-07-26 17:00:15 +02:00
Nathan Adams 6b788faa9d tests: Implement fscommand('quit') on test runner 2023-07-26 17:00:15 +02:00
Nathan Adams 1a0a82d898 core: Move fscommand execution outside of ExternalInterfaceProvider, so it can be implemented without causing ExternalInterface.available to become true 2023-07-26 17:00:15 +02:00
Nathan Adams 4252d035af tests: Add issue to avm_plus ignored tests 2023-07-26 16:12:57 +02:00
Nathan Adams 3e7a7854ae tests: Ignore failing avmplus tests 2023-07-26 16:12:57 +02:00
Nathan Adams 6b2813c022 tests: Port some avmplus tests over 2023-07-26 16:12:57 +02:00