Commit Graph

5076 Commits

Author SHA1 Message Date
CUB3D 96ad0e3d00 avm2: Implement Op::Li16 2021-04-21 00:33:11 -07:00
CUB3D aaaf6ace3e avm2: Implement Op::Si16 2021-04-21 00:33:11 -07:00
CUB3D f437539f73 avm2: Some domain memory is available by default and error when range invalid 2021-04-21 00:33:11 -07:00
CUB3D 5a0cdf60bc avm2: Implement Op::Si8 and Op::Li8 badly 2021-04-21 00:33:11 -07:00
CUB3D 12a198f671 avm2: Implement Op::Coerce and add tests 2021-04-21 00:33:11 -07:00
CUB3D c2969895b2 avm2: Add domain memory tests 2021-04-21 00:33:11 -07:00
CUB3D 89c01dca18 swf: Add support for AVM2 domain memory opcodes 2021-04-21 00:33:11 -07:00
TÖRÖK Attila 46ddc31254 avm2: Call the super initializer of LoaderInfo after construction 2021-04-19 18:16:47 -07:00
Daniel Jacobs c993ad8964 demo: Use absolute URLs for links in README 2021-04-19 16:50:52 -07:00
Mike Welsh cbe685f8d5 tests: Update transform test to verify color transform rounding 2021-04-19 15:47:52 -07:00
Mike Welsh 0552d26551 core: Use Fixed8 and i16 for ColorTransform
Use the proper types for ColorTransform:
 * Fixed8 (8.8) format for multiplicative component
 * i16 format for additive component

This matches the behavior of Flash (for example, alpha only changes
in units of 1/256).
2021-04-19 15:47:52 -07:00
Mike Welsh 50f2ecb1b5 swf: Add Fixed8 and Fixed16 types 2021-04-19 15:47:52 -07:00
dependabot-preview[bot] 784e0f3436 build(deps): bump wasm-bindgen-test from 0.3.19 to 0.3.23
Bumps [wasm-bindgen-test](https://github.com/rustwasm/wasm-bindgen) from 0.3.19 to 0.3.23.
- [Release notes](https://github.com/rustwasm/wasm-bindgen/releases)
- [Changelog](https://github.com/rustwasm/wasm-bindgen/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rustwasm/wasm-bindgen/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-04-18 23:54:51 -07:00
dependabot-preview[bot] 9c466c65da build(deps): bump syn from 1.0.67 to 1.0.69
Bumps [syn](https://github.com/dtolnay/syn) from 1.0.67 to 1.0.69.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/1.0.67...1.0.69)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-04-18 23:54:37 -07:00
Daniel Jacobs 8c9db35baf
demo: Allow small screens to still upload local files 2021-04-18 21:04:02 -07:00
Mike Welsh db6000f071 avm2: Fix parsing of variable-length s32 values
The values are not sign-extended as the spec suggests; a negative
value must use all 5 bytes.
2021-04-18 17:32:01 -07:00
valadaptive f6602dd377
web: Handle errors from CSPs which block WebAssembly
This removes the "Report Bug" link from the error case in which
WebAssembly code generation is disallowed by the host's content security
policy, because there's nothing we can do to fix that, and directs
people to the wiki instead.
2021-04-17 19:21:39 -07:00
dependabot-preview[bot] 9832a7385e build(deps): bump libflate from 1.0.4 to 1.1.0
Bumps [libflate](https://github.com/sile/libflate) from 1.0.4 to 1.1.0.
- [Release notes](https://github.com/sile/libflate/releases)
- [Commits](https://github.com/sile/libflate/compare/1.0.4...1.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-04-17 10:25:29 -07:00
relrelb cd8ab813a4 avm1: Return an unboxed undefined in `TransformObject` constructor
This is now possible thanks to #2415.
2021-04-17 09:27:29 -07:00
relrelb 6d68460196 tests: Expand funky_function_calls 2021-04-17 09:25:24 -07:00
relrelb 95cffdc2f9 avm1: Pass undefined this for CallMethod with non-string method_name
This isn't the most accurate behavior, since it should be an unboxed
Value, but currently it's not possible due to #843.
2021-04-17 09:25:24 -07:00
relrelb 6a34070e76 tests: Expand sound
Check Sound.duration and Sound.getDuration() for detached sounds.
Check rounding behavior of Sound.duration and Sound.getDuration()
behind a comment because NullAudioBackend doesn't respect durations.
TODO: Uncomment it once NullAudioBackend returns real durations.
2021-04-17 09:11:50 -07:00
relrelb e3478248ac avm1: Implement Sound.getDuration() and Sound.setDuration()
These seem to be undocumented.
Looks like Sound.getDuration() behaves exactly as Sound.duration,
and Sound.setDuration() does nothing.
2021-04-17 09:11:50 -07:00
relrelb 79bcee07f5 audio: Properly round sound duration
Previously it was always rounded down. Change it to the nearest
integer.
2021-04-17 09:11:50 -07:00
relrelb 6310e31023 avm1: Sound.duration should return undefined when no sound is attached
Previously it returned 0.
2021-04-17 09:11:50 -07:00
Mike Welsh bab2701208 web: Bump wasm-bindgen and js-sys versions 2021-04-16 23:37:23 -07:00
Mike Welsh b31b00c6d6 wgpu: Bump to latest wgpu master 2021-04-16 23:37:23 -07:00
dependabot-preview[bot] 6f1b0a23ee build(deps): bump isahc from 1.3.0 to 1.3.1
Bumps [isahc](https://github.com/sagebind/isahc) from 1.3.0 to 1.3.1.
- [Release notes](https://github.com/sagebind/isahc/releases)
- [Commits](https://github.com/sagebind/isahc/compare/1.3.0...1.3.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-04-16 23:35:56 -07:00
Mike Welsh 7171628b44 ci: Append GitHub build ID instead to extension version
Appending the build date doesn't work (the Mozilla verison format
requires each numeric to be <65536). Use GITHUB_RUN_NUMBER instead,
which increases each time the workflow runs.
2021-04-16 22:17:01 -07:00
Mike Welsh 7e338335bf ci: Allow manual dispatch of release_nightly workflow
Ignore activity check when release_nightly is manually dispatched.
2021-04-16 19:09:18 -07:00
Mike Welsh 0ff9d7d3f5 ci: Add Mozilla add-on secrets to CI environment 2021-04-16 19:09:18 -07:00
relrelb 4d41297b04 avm1: Remove reduntant new_ret_no_self annotation
Per https://rust-lang.github.io/rust-clippy/master/#new_ret_no_self,
`new_ret_no_self` applies only to functions named `new`.
`TObject::create_bare_object` used to be named `new`, but was renamed
in 79af3ffe44.
2021-04-16 15:25:22 -07:00
relrelb 1f934c5fc6 avm1: Remove redundant newlines 2021-04-16 15:25:22 -07:00
relrelb dac60da936 avm1: ValueObject::boxed -> coerce_to_object 2021-04-16 15:25:22 -07:00
relrelb 0f8f0986e9 chore: Use matches!(...) in more places 2021-04-16 15:25:22 -07:00
relrelb 9dc63a7831 core: Remove redundant tuple 2021-04-16 15:25:22 -07:00
relrelb a2e162be0d avm1: Add Value::is_primitive
This provides a more convenient and readable way compared to
using matches!(Value::Object(_)).
2021-04-16 15:25:22 -07:00
relrelb 2ba6cada5b avm1: Reserve arguments capacity
This prevents unnecessary re-allocations.
2021-04-16 15:25:22 -07:00
Chris Midgley d89f0bbbfe fix: looks like contentType is ignored (at least in FP6) 2021-04-16 12:36:49 -07:00
Chris Midgley ba185418b9 chore: fmt 2021-04-16 12:36:49 -07:00
Chris Midgley 6c619495f4 chore: fix warnings 2021-04-16 12:36:49 -07:00
Chris Midgley 8e6bba1525 avm1: implement send_and_load 2021-04-16 12:36:49 -07:00
Chris Midgley f1b07bd75b avm1: set contentType on xml; fix initial contentType on load_vars. 2021-04-16 12:36:49 -07:00
Mike Welsh 3f718e508e docs: Update Firefox add-on instructions 2021-04-16 12:31:14 -07:00
Mike Welsh 959bd97e17 ci: Upload signed Firefox add-on to GitHub releases 2021-04-16 12:31:14 -07:00
Mike Welsh 98c0146279 extension: Add build date to version in manifest
The Chrome/Firefox marketplaces require the version number of an
extension to increase with each upload, so append the build date
to the version in `manifest.json`. Add `versionName` with the more
readable version (`0.1 nightly 2010-15-04` for nightly builds).
2021-04-16 12:31:14 -07:00
Mike Welsh 100977a266 extension: Catch errors while signing the Firefox add-on
Properly catch errors from the `sign-addon` package and bail out
immediately. This will display better output from the Mozilla
validation service.
2021-04-16 12:31:14 -07:00
Mike Welsh 9e64f111c3 extension: Copy Firefox add-on after signing instead of moving
A rename will fail if the destination is on a different mount
(happened to me!). Instead, copy the file to the destination, then
delete the old file.
2021-04-16 12:31:14 -07:00
Mike Welsh 80dfefa45d extension: Add proper 128x128 icon 2021-04-16 12:31:14 -07:00
relrelb 4d2c8ec7f6 web: Set page title in player.js 2021-04-15 16:29:27 -07:00