summaryrefslogtreecommitdiffstats
path: root/platform/javascript/js
Commit message (Collapse)AuthorAgeFilesLines
...
* [HTML5] Respect allow_hidpi option during setupFabio Alessandrelli2021-03-081-5/+10
| | | | The option was forced to `true` before, unlike on other platforms.
* [HTML5] Catch audio worklet errors on disconnect.Fabio Alessandrelli2021-03-081-1/+4
| | | | | Which could happen if the worklet was not fully loaded, or the audio context had already aborted.
* [HTML5] Replace XMLHttpRequest with Fetch.Fabio Alessandrelli2021-03-062-142/+258
| | | | | | This has some advantages: - Streaming/chunked response support. - Broader headers support.
* [HTML5] Rename heapCopy to heapSlice.Fabio Alessandrelli2021-03-053-4/+18
| | | | New heapCopy function copies a TypedArray to the heap.
* [HTML5] Export process writes sizes in template.Fabio Alessandrelli2021-03-053-10/+17
| | | | | | This allow the loading bar to be much more reliable, even in cases where realible stream loading status is not detectable (server-side compression, chunked encoding).
* [HTML5] Preloader fetch, streaming instantiation.Fabio Alessandrelli2021-03-054-70/+103
|
* [HTML5] Add jsdoc2rst tool.Fabio Alessandrelli2021-02-261-0/+354
| | | | | | | | | | | A template for `jsdoc` that generat the HTML5 public classref. The script can be run via `npm run docs` to print to stdout. You can dry run via `npm run docs -- --d dry-run` or write to file via `npm run docs -- -d /path/to/file.rst` Also update Makefile in `doc/` and add dry run test to CI.
* [HTML5] Document Engine and EngineConfig (jsdoc).Fabio Alessandrelli2021-02-263-258/+534
| | | | | This commit also removes the utils.js engine file, moving some of it's content to config.js and some to engine.js .
* [HTML5] Better fullscreen, canvas resizing.Fabio Alessandrelli2021-02-192-24/+167
| | | | | | | | | | | Three canvas resize policies: - `None`: Godot window settings are ignored. - `Project`: Godot handles the canvas like a native app (resizing it when setting the window size). - `Adaptive`: Canvas size will always adapt to browser window size. Use `None` if you want to control the canvas size with custom JavaScript code.
* [HTML5] Easier HTML templates, better deinit/cleanup.Fabio Alessandrelli2021-02-193-187/+166
|
* [HTML5] Implement get_processor_count.Fabio Alessandrelli2021-02-171-0/+5
|
* [HTML5] Detect screen scale and DPI.Fabio Alessandrelli2021-02-121-0/+26
| | | | | | | | `OS.get_screen_scale` will now return the `window.devicePixelRatio` value, `OS.get_screen_dpi` uses CSS media queries to find approximate DPI value for the current display. `OS.get_screen_size` also return the actual screen size (not the CSS pixel size).
* Merge pull request #45888 from Faless/js/4.x_xhr_fixRémi Verschelde2021-02-111-24/+6
|\ | | | | [HTML5] Fix HTTPClient request_raw.
| * [HTML5] Fix HTTPClient request_raw.Fabio Alessandrelli2021-02-111-24/+6
| | | | | | | | | | Now send data according to the spec, properly handle null data. Simplify JS code since we are at it.
* | [HTML5] Handle contextmenu, webglcontextlost internally.Fabio Alessandrelli2021-02-112-11/+12
|/ | | | | This way they are automatically cleaned up when the engine exits, landing a hand to browsers garbage collectors.
* [HTML5] Better editor HTML, small refactor.Fabio Alessandrelli2021-01-252-2/+1
| | | | | Side and GDNative libraries are now added by engine.js , the dynlink pre js had been deleted.
* [HTML5] Custom Gamepad library to allow remapping.Fabio Alessandrelli2021-01-181-1/+171
| | | | | | | No longer use emscripten functions for gamepads, implement them as library functions in library_godot_display.js instead. This allows us to do a better job at "guessing" vendorId, productId, OS, etc. thus allowing us to better find the remapping for the controller.
* Update copyright statements to 2021Rémi Verschelde2021-01-018-16/+16
| | | | | | | | | | | | | | Happy new year to the wonderful Godot community! 2020 has been a tough year for most of us personally, but a good year for Godot development nonetheless with a huge amount of work done towards Godot 4.0 and great improvements backported to the long-lived 3.2 branch. We've had close to 400 contributors to engine code this year, authoring near 7,000 commit! (And that's only for the `master` branch and for the engine code, there's a lot more when counting docs, demos and other first-party repos.) Here's to a great year 2021 for all Godot users 🎆
* [HTML5] Fix errors when Mic is not allowed.Fabio Alessandrelli2020-12-091-10/+16
|
* [HTML5] EditorRunNative works with GDNative.Fabio Alessandrelli2020-12-052-1/+8
| | | | | | This "breaks" our loading bar logic (libraries are not counted). Fixing it is non trivial and probably deserves investigating a different strategy.
* [HTML5] GDNative support via SIDE_MODULE.Fabio Alessandrelli2020-12-053-3/+6
| | | | Working with emscripten >= 2.0.10
* [HTML5] Add function signatures to JS libraries.Fabio Alessandrelli2020-12-046-0/+57
|
* [HTML5] Remove file flags from writeFile in setup.Fabio Alessandrelli2020-11-301-1/+1
| | | | Flags where deprecated and partly in removed in emscripten 2.0.9.
* [HTML5] Run eslint --fix.Fabio Alessandrelli2020-11-2311-384/+392
| | | | Should I write a poem about this whole new world? ;)
* [HTML5] Libraries refactor for linting.Fabio Alessandrelli2020-11-2112-0/+2156
Initial work to make liniting easier. This includes: - Rename http_request.js to library_godot_http_request.js. - Rename externs.js to engine.externs.js. - New library_godot_runtime.js (GodotRuntime) wraps around emscripten functions. - Refactor of XMLHttpRequest handler in engine/preloader.js. - Few fixes to bugs spotted by early stage linting.