Commit Graph

203 Commits

Author SHA1 Message Date
unknown a14f19e9e5 avm1: Call the respective listeners 2020-07-29 15:24:23 -07:00
unknown 795cd72dce avm1: Broadcasting functions are now copied from AsBroadcaster 2020-07-29 15:24:23 -07:00
unknown b72dbcae96 chore: Assert his inside of listeners 2020-07-29 15:24:23 -07:00
unknown df50cbb27f avm1: Fix the behavior of addListener and removeListener 2020-07-29 15:24:23 -07:00
unknown 20989ef03d avm1: Initialize now copies the functions from AsBroadcaster 2020-07-29 15:24:23 -07:00
unknown 890dc0ea13 avm1: Implement AsBroadcaster 2020-07-29 15:24:23 -07:00
Nathan Adams 32be19da6d avm1: Allow gotoAndStop/gotoAndPlay with frame numbers in paths - #915 2020-07-29 13:53:57 -07:00
Mike Welsh 5d08956152 tests: Add typeof and labels for Object() test 2020-07-29 13:52:51 -07:00
CUB3D 0fe3a23fd6 core: Correct handling of Object function without args 2020-07-29 13:52:51 -07:00
CUB3D 49bee3fe5c core: Implement Object() function 2020-07-29 13:52:51 -07:00
CUB3D c1771d7d4e core: Split function and constructor, tests, fix bug with constructor 2020-07-27 12:50:31 -07:00
CUB3D afb1d6b42f core: Add global Array() function 2020-07-27 12:50:31 -07:00
CUB3D 22db5ab76a core: Populate function when creating a constructor 2020-07-27 10:38:50 -07:00
Nathan Adams cf61f8a4d3 avm1: Add failing test for registerClass in a loaded movie 2020-07-27 01:40:28 -07:00
Mike Welsh efa059ff8d tests: Add test for LoadVars 2020-07-23 03:00:19 -07:00
Mike Welsh 74cb8609c1 avm1: Support loading into _level in GetURL2
Calling loadMovieNum with a variable parameter compiles into a
GetURL2 call with a `_level` window target parameter. Previously
this triggered Ruffle to try to navigate to the SWF. Now it
properly loads the SWF inside the current movie.
2020-07-23 02:08:48 -07:00
Nathan Adams f0980301da avm1: Implement arguments.callee 2020-07-22 15:57:45 -07:00
Nathan Adams d5deeee1b7 avm1: Properly implement the arguments object, it's an array 2020-07-21 07:49:00 -07:00
Mike Welsh 8c1ec01d75 tests: Test clip events copying in duplicateMovieClip
duplicateMovieClip should also copy any clip events on the source
clip to the newly created movie clip.
2020-07-17 20:49:05 -07:00
Mike Welsh f9b1c586d1 tests: Add test for paths in ActionCall 2020-07-14 23:34:21 -07:00
CUB3D 83cca044ad core: Add tests for ContextMenu and ContextMenuItem 2020-07-12 15:25:58 -07:00
Mike Welsh 8715589f50 tests: Add setInterval test 2020-07-10 14:38:48 -07:00
Nathan Adams 8a0430d744 avm1: Implement Object.watch & Object.unwatch (#268) 2020-07-10 12:02:26 -07:00
Nathan Adams ecbab536b5 avm1: Respect ScriptLimits for recursion depth, and use that in infinite_recursion_function 2020-07-08 14:47:38 -07:00
Nathan Adams 51ec5739c6 avm1: Throw errors when functions (user-called, or special) go too deep 2020-07-08 14:47:38 -07:00
Mike Welsh 2cbbe32412 tests: Add test for GetVariable/SetVariable on _x, etc. 2020-07-05 15:15:31 -07:00
Mike Welsh 804385347f tests: Add test for virtual properties on prototype 2020-07-05 15:15:31 -07:00
Mike Welsh fec8cf5e52 tests: Add tests for with from issue #792 2020-07-05 15:15:31 -07:00
CUB3D ab58cff8b3 core: Add tests for ColorTransform and cleanup code 2020-07-05 13:49:59 -07:00
Mike Welsh 07814fdf53 tests: Add test for Error 2020-07-02 20:58:01 -07:00
Mike Welsh 3a4d432645 tests: Edit textfield_variable test for #777 2020-07-02 01:29:41 -07:00
Nathan Adams d86761db5d avm1: Implement try {..} catch {..} finally {..} - #731 2020-07-01 17:30:56 -07:00
Nathan Adams 7c0b0a7a57 avm1: Fix instanceof checks with primitives 2020-07-01 16:36:54 -07:00
Nathan Adams d1732dd3d6 avm1: Returning from with{} should return from the parent activation 2020-07-01 16:21:43 -07:00
Mike Welsh d97a515330 tests: Add text field variable test 2020-06-28 18:36:10 -07:00
Mike Welsh 8da0f43412 tests: Add test for DefineLocal and issue #760 2020-06-28 15:15:45 -07:00
Mike Welsh 0833c15e25 tests: Add test for enumerating array indices 2020-06-27 20:25:45 -07:00
Mike Welsh 478d88b22d tests: Test hasOwnProperty for array indices in array_properties 2020-06-27 20:25:45 -07:00
Mike Welsh 8e3b96f1b1 tests: Add tests for non-string params in hasOwnProperty: 2020-06-27 20:25:45 -07:00
Mike Welsh b37b74e0b6 tests: Add test for __constructor__ being DontEnum 2020-06-27 18:54:01 -07:00
Nathan Adams 463b79f063 avm1: Implement Action::Throw 2020-06-25 02:03:15 -07:00
David Wendt c1ad37a0f6 Implement text span raising, sans list items.
During the raising process, we maintain a list of pointers to the lowest-most `textformat`, `p`, `font`, `a`, `b`, `i`, and `u` in the document that we are appending to. When we get a new one of any of those elements, we clear the rest off the stack. This forces us to add HTML in the same order Flash does.

LIs are not yet supported because they require us to process text line-by-line which doesn't mesh with this model.

There's also a test but the XML DOM generates HTML strings with the wrong attribute order, so the test fails spuriously.
2020-06-20 20:14:57 -04:00
David Wendt e036d6594b Add some entity support to HTML parsing. 2020-06-20 20:08:22 -04:00
David Wendt 88fcb98913 Allow disabling entity processing when parsing XML.
This necessitated a change to edittext_bullet, which turns out is accidentally an entity test, too. It now no longer uses entities so that it won't spuriously fail due to an entity related problem.
2020-06-20 20:06:21 -04:00
David Wendt 65f4d2cf1e Add regression tests for `underline`.
We're within 4px in every case.
2020-06-20 19:56:01 -04:00
David Wendt a2d69a69a3 Add a test for bullets.
As usual with most newline related things, we're 3px off no matter how many or how few lines we have.
2020-06-20 19:56:00 -04:00
David Wendt 8628261dc8 Add a bunch of necessary fixes to default text formatting and HTML format extraction.
This also replaces the `edittext_html_defaults` test with a more robust test that checks the default format and global format of SWF-based, text, and HTML test vectors.
2020-06-20 19:55:57 -04:00
David Wendt 3c9a43ea72 Add a regression test for newlines.
This test includes tests for HTML newlines, which causes the XML parser in Ruffle to throw errors. Hence why it's currently ignored.
2020-06-20 19:55:53 -04:00
David Wendt 6c44418b10 Add a test for tab_stops.
This test is currently inaccurate by up to 5 pixels, this is due to some behavior with really, really wide tabstops and word breaks that I don't entirely get yet.
2020-06-20 19:55:51 -04:00
David Wendt 0e45dc12e9 Recompile the letter spacing test 'cause I spotted an errant `s` in the FLA 2020-06-20 19:55:49 -04:00