Commit graph

3648 commits

Author SHA1 Message Date
Rémi Verschelde 0ae65472e7
clang-format: Enable BreakBeforeTernaryOperators
clang-format keeps breaking the way it handles break *after* ternary operators,
so I give up and go with the only style they seem to actually test.
2021-10-28 15:57:41 +02:00
Rémi Verschelde 3a6be64c12
clang-format: Various fixes to comments alignment from clang-format 13
All reviewed manually and occasionally rewritten to avoid bad auto formatting.
2021-10-28 15:43:36 +02:00
Rémi Verschelde 3b11e33a09
clang-format: Disable alignment of operands, too unreliable
Sets `AlignOperands` to `DontAlign`.

`clang-format` developers seem to mostly care about space-based indentation and
every other version of clang-format breaks the bad mismatch of tabs and spaces
that it seems to use for operand alignment. So it's better without, so that it
respects our two-tabs `ContinuationIndentWidth`.
2021-10-28 15:19:35 +02:00
Rémi Verschelde d4067e661c
Merge pull request #54326 from nekomatata/x11-fix-input-delay 2021-10-28 08:57:37 +02:00
PouleyKetchoupp ba96fc6a4d Fix input events random delay on X11
The new system based on a thread gathering events from the X11 server
was causing delays in some scenarios where some events have just been
missed at the time of processing and we're waiting for a whole frame to
check them again.

Solved by flushing again and checking for pending events at the
beginning of the process loop, in addition to events already gathered
on the event thread.
2021-10-27 15:24:09 -07:00
Rémi Verschelde 9204a3a50e
Android: Properly validate godot_project_name_string for Android special chars
Fixes #52659.
2021-10-26 10:01:09 +02:00
Rémi Verschelde b2ab5cb504
Merge pull request #54045 from ConteZero/primary_clipboard_linux_fix_warning 2021-10-23 19:13:34 +02:00
ConteZero 8c48b4a7e0 Fix primary clipboard warning 2021-10-23 15:50:01 +02:00
Marcel Admiraal f80cb4dffa Fix Gradle builds not excluding excluded tasks 2021-10-23 14:13:36 +01:00
Rémi Verschelde 5f7bbc2b57
JS: Bump ansi-regex version for linter
Silences warning about a moderate security vulnerability (which doesn't affect us).
2021-10-22 23:35:51 +02:00
Aaron Franke 474d0f58f5
Add support for the RISC-V architecture
Supports RV64GC (RISC-V 64-bit with general-purpose and compressed-instruction extensions)
2021-10-22 12:51:10 -05:00
Marcel Admiraal 87a4ba492e Remove unimplemented methods 2021-10-21 18:44:25 +01:00
Rémi Verschelde 8748247d6f
Merge pull request #53702 from ConteZero/primary_clipboard_linux 2021-10-20 16:35:04 +02:00
Rémi Verschelde 4387f9645b
Merge pull request #52940 from groud/toast_notification 2021-10-19 09:57:13 +02:00
ConteZero 838c9d37b4 Added primary clipboard for Linux 2021-10-18 14:01:06 +02:00
Ignacio Roldán Etcheverry 5b278ad7bc
iOS: Don't embed project static frameworks/libs
Previously, files added via `add_ios_project_static_libs` where
being added as embedded frameworks. This commit fixes that.
    
Static frameworks/libs should never be embedded into IPAs.
2021-10-17 22:38:03 +02:00
Rémi Verschelde 1efe7093be
Merge pull request #53833 from akien-mga/remove-webm-support 2021-10-15 17:33:06 +02:00
Rémi Verschelde ae74e78909
Remove WebM support (and deps libvpx and opus)
We've had many issues with WebM support and specifically the libvpx library
over the years, mostly due to its poor integration in Godot's buildsystem,
but without anyone really interested in improving this state.

With the new GDExtensions in Godot 4.0, we intend to move video decoding to
first-party extensions, and this would likely be done using something like
libvlc to expose more codecs.

Removing the `webm` module means we can remove libsimplewebm, libvpx and
opus, which we were only used for that purpose. Both libvpx and opus were
fairly complex pieces of the buildsystem, so this is a nice cleanup.

This also removes the compile-time dependency on `yasm`.

Fixes lots of compilation or non-working WebM issues which will be linked
in the PR.
2021-10-15 12:09:11 +02:00
Rémi Verschelde cd21cc683a
SCons: Set DEBUG_ENABLED and DEV_ENABLED in SConstruct
They're the same for all platforms so they don't need to be repeated in all
platform definitions.
2021-10-15 10:26:58 +02:00
K. S. Ernest (iFire) Lee 8f0c056431 Fix specific warnings issues by Clang
Found by `scons dev=yes` on llvm-mingw.
2021-10-14 14:14:26 -07:00
Marcel Admiraal 95b1275197 Upgrade Android Gradle to version 7.2 2021-10-14 16:19:00 +01:00
Gilles Roudière 0587e5e018 Implement toast notifications in the editor 2021-10-14 13:30:54 +02:00
Rémi Verschelde e2dfb656f4
SCons: Add DEV_ENABLED defines for target=debug builds
This will allow adding developer checks which will be fully compiled out in
user builds, unlike `DEBUG_ENABLED` which is included in debug tempates and
the editor builds.

This define is not used yet, but we'll soon add code that uses it, and change
some existing `DEBUG_ENABLED` checks to be performed only in dev builds.

Related to godotengine/godot-proposals#3371.
2021-10-14 12:01:28 +02:00
Mark Riedesel f0dd693a08 free dbus errors when inhibiting freedesktop screensaver (prevents small memory leak) 2021-10-12 21:11:56 -04:00
Rémi Verschelde 88463c3eee
Merge pull request #53712 from CakHuri/nullptr
Replace NULL with nullptr
2021-10-12 22:30:43 +02:00
Hugo Locurcio b1b14e5fd7
Build for 64-bit ARM by default when compiling or exporting for Android
All Android devices that support Vulkan support 64-bit ARM.

This also removes NEON opt-out code for ARMv7 as pretty much all
ARMv7 devices also support NEON.
2021-10-12 16:35:49 +02:00
M. Huri 033dc4dbef Replaced NULL with nullptr 2021-10-12 20:20:19 +07:00
Aaron Franke 7e51e4cb84
Fix some LGTM errors of "Multiplication result converted to larger type" 2021-10-12 00:17:27 -05:00
ne0fhyk 431ccdb057 Pass the correct export_format argument to locate the assets directory when exporting. 2021-10-11 08:24:21 -07:00
Rémi Verschelde ab9c1574d0
Merge pull request #53580 from RandomShaper/improve_cache_funcs 2021-10-09 13:40:53 +02:00
Pedro J. Estébanez 007cb5ccfb Implement get_cache_path() for iOS, and improve it for Android and Windows 2021-10-09 11:13:26 +02:00
Rémi Verschelde 1f192c43b0
Merge pull request #51429 from omar-polo/fix-basename 2021-10-09 10:34:21 +02:00
Omar Polo a3384b7461 use .get_file() instead of basename(3)
On OpenBSD the compiler complains that calling basename(3) would lose
const qualifier.  basename(3) is defined as

	char *basename(char *);

and can, accorgindly to the POSIX.1, modify the passed string.

This uses the .get_file() method.  The check is necessary because
file_name could be a directory, in which case .get_file() would return
an empty string.  The .get_base_dir().get_file() idiom is already used.

The usage of get_file() and the check were suggested by theraot, thanks!
2021-10-08 20:10:26 +02:00
kobewi 92a53f9bd6 Change dragging cursor on Windows 2021-10-06 13:13:42 +02:00
Rémi Verschelde a7ba227631
Merge pull request #52711 from m4gr3d/provide_getter_for_project_data_dir_master 2021-10-05 21:02:27 +02:00
Fabio Alessandrelli 68616edcbc [HTML5] Refactor JS library listeners to OS. 2021-10-05 14:15:07 +02:00
Fabio Alessandrelli c494e442bc [HTML5] Refactor display/input JS library code. 2021-10-05 14:15:07 +02:00
Fabio Alessandrelli 204822ed45 [HTML5] Implement Pointer Lock API in JS library.
Removes more emscripten HTML5 library dependencies.
2021-10-05 14:15:07 +02:00
Fabio Alessandrelli 7d6c1fdb32 [HTML5] Implement window blur in JS library.
Removes more emscripten HTML5 library dependencies.
2021-10-05 14:15:07 +02:00
Fabio Alessandrelli b6315afc9a [HTML5] Implement fullscreenchange in JS library.
Removes more emscripten HTML5 library dependencies.
2021-10-05 14:15:07 +02:00
Fabio Alessandrelli b2d30c725d [HTML5] Implement mouse/touch/key events in JS library.
This makes us more independent from emscripten libraries, giving us more
control on the application lifecycle.
2021-10-05 14:15:07 +02:00
Rémi Verschelde b1c6826b9f
Merge pull request #52963 from Pineapple/WIN32_LEAN_AND_MEAN_master 2021-10-05 12:03:05 +02:00
Rémi Verschelde 3479aaa369
Merge pull request #53405 from winterpixelgames/PR-more-error-logging-release 2021-10-05 08:43:07 +02:00
Jordan Schidlowsky b78d399f91 revert 0d7409a so additional error information prints in release builds 2021-10-04 16:55:01 -06:00
bruvzg 0c0b5c84b0 Implement TextServer GDExtension interface, remove TextServer GDNative interface. 2021-10-01 15:13:29 +03:00
Rémi Verschelde a7011fa294
Merge pull request #52684 from Frixuu/master 2021-10-01 11:53:01 +02:00
Lightning_A c63b18507d Use range iterators for Map 2021-09-30 15:09:12 -06:00
Rémi Verschelde 3a19400889
Merge pull request #48685 from bruvzg/bundle_icon_4 2021-09-30 14:55:04 +02:00
Fabio Alessandrelli e2e1a5099c
Merge pull request #52809 from selgesel/patch1
Release pressed events when the window is blurred on HTML5 platform
2021-09-29 13:09:59 +02:00
Rémi Verschelde 23b51a1708
HTML5: Fix minification error with Emscripten 1.39.9
It used an old vendored version of acorn.js which seems to choke on this
trailing comma. This is not a problem for more recent Emscripten versions.

We disable the `comma-dangle` check in ESLint to prevent this issue.
2021-09-29 09:11:11 +02:00