1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-19 01:04:20 +00:00
Commit graph

873 commits

Author SHA1 Message Date
reuk
21b0cd4663
Network: Fix potential deadlock in macOS WebInputStream
Regarding didComplete():

When a WebInputStream is destroyed, the thread of execution will wait in
SharedSession::removeTask() until the task is no longer present in the
list of all active tasks. If multiple threads are all waiting in
removeTask(), then all of those threads should wake when the set of
active tasks changes. Waking only a single thread may result in
deadlocks, as that thread's task may not have completed successfully.
Then, the thread that woke up will be forced to sleep again and may not
get another chance to wake.

Regarding didBecomeInvalid():

Normally, didBecomeInvalid() will only be called after the
SharedSession's destructor. If the destructor is running, we may assume
that no other thread can access the SharedSession, so using notify_one()
in didBecomeInvalid() should be sufficient to wake up the destructor's
thread. However, there's a chance that the NSURLSession may be
invalidated unexpectedly (i.e. before the SharedSession's destructor
runs), in which case there may still be threads waiting in removeTask().
In this scenario we need to notify_all() so that all waiting threads are
able to wake and make progress.
2025-06-30 19:46:19 +01:00
reuk
b8e0146a3c
Network: Make Linux networking code robust against user headers that already end with CRLF 2025-06-19 14:45:30 +01:00
reuk
a3d64c7784
Typeface: Enable advanced colour glyph rendering on Android
Android 15+ removed the 'legacy' png-based emoji font. Modern Android
versions may include only a COLR-v1-based font, which JUCE cannot
render itself.

As a workaround, on Android, we use a Canvas object to render each emoji
glyph into a bitmap, and then render that bitmap in the same way as a
legacy png-based glyph. This won't look as crisp as rendering COLRv1
glyphs directly, especially at larger sizes, but this is a sufficient
stop-gap for the time being.
2025-06-16 16:59:55 +01:00
reuk
6f1d116279
macOS: Add initial macOS 26 suport 2025-06-10 20:15:58 +01:00
reuk
f904fd356a
Android: Improve screen safe-area reporting
The goal of this change is to ensure that the safeAreaInsets and
keyboardInsets members of Display correctly take the current system UI
and screen cutouts into account.

This change also enables rendering behind the status bar and navigation
bar for JUCE applications. This is in line with the new defaults in
Android 15, where building against the Android SDK 35 will automatically
enable "edge-to-edge" drawing. Enabling this behaviour on older
platforms too provides a more consistent experience.
2025-06-03 16:08:20 +01:00
reuk
17bf5c167c
ObjC: Silence Wcast-function-type-mismatch warnings when building with Wextra for x86_64 2025-04-14 13:05:22 +01:00
attila
fbcd416a84 Prevent Thread::sleep waking up on POSIX systems when receiving signals 2025-04-10 16:23:13 +02:00
reuk
51be8b9332
Android: Remove unnecessary SDK version checks 2025-03-19 11:06:17 +00:00
reuk
90695ce7b6
SystemStats: Silence function-cast warnings 2025-03-03 14:41:31 +00:00
attila
49b6dfb7c8 Fix 0 file descriptor handling on POSIX systems 2025-02-06 12:12:15 +01:00
reuk
2d01e326db
ObjCHelpers: Rename makeCGRect from makeNSRect 2025-01-23 12:20:27 +00:00
reuk
9092182605
WebBrowserComponent: Fix leak on Windows
Co-authored-by: Aid Vllasaliu <vllasaliu.aid@gmail.com>
2025-01-07 11:21:05 +00:00
Oliver James
cafe62dd88 SystemStats (macOS): Add macOS 15 (Sequoia) enum 2025-01-06 11:52:55 +00:00
reuk
0329635ed2
RuntimePermissions: Allow requesting the POST_NOTIFICATIONS permission at runtime on Android 2024-12-04 11:09:18 +00:00
Anthony Nicholls
5e803ded5f Deprecations: Add ignore deprecation warning macros 2024-11-27 11:07:04 +00:00
tpoole
39b335ccef Make building with MinGW a compiler error 2024-11-22 14:43:18 +00:00
reuk
7437e35ef5
File: Always interpret path as absolute in getLinkedTarget()
This fixes an issue where paths consisting of just a drive letter ("C:")
would be passed to CreateFile without a trailing path separator. The
documented behaviour in this case is for the path to be interpreted
relative to the "current directory" on that disk, so getLinkedTarget()
would incorrectly return the disk's working directory instead of the
drive root.
2024-11-07 21:00:22 +00:00
reuk
93640b63ff
Compatibility: Add new macros for straightforward checking of minimum deployment target
This also fixes a bug introduced in f7c7225f5c
where the condition guarding the definition of traitCollectionDidChange
was incorrect. This function is never required if the deployment target
is at least 17.0.
2024-11-05 13:28:10 +00:00
reuk
3005b716fe
ObjCHelpers: Add new macros to help with version checking 2024-10-29 19:46:35 +00:00
reuk
f7c7225f5c
UIViewComponentPeer: Fix deprecation warnings for iOS 17 2024-10-29 19:46:35 +00:00
reuk
a4ba0c1b1c
FileChooser: Fix deprecation warnings for iOS 14 2024-10-29 19:46:34 +00:00
Anthony Nicholls
b78ff3bf7e HighResolutionTimer: Add fallback implementation for Windows 2024-10-29 13:06:28 +00:00
Oliver James
c68e82f44d Core: Handle Windows Arm platform definition 2024-10-21 14:11:11 +01:00
reuk
470ada4454 ComSmartPtr: Update implementation slightly so that error codes can be inspected during debugging 2024-09-13 13:57:10 +01:00
Anthony Nicholls
1b0f45fa96 Formatting: Improve consistency of static inline word ordering 2024-09-06 15:40:39 +00:00
reuk
add3a5de0d
Android: Fix issues with input stream special members
Fixes bugs in AndroidInputStreamWrapper introduced in
0d2e34f34c

- Now that AndroidInputStreamWrapper is moveable, its destructor must be
  able to handle the situation where stream is null
- The move assignment operators of AndroidInputStreamWrapper and
  AndroidContentUriInputStream could previously end up calling
  themselves recursively
2024-09-05 12:17:12 +01:00
attila
5ce2fc388e Fix C++23 compilation 2024-08-15 11:15:15 +02:00
Anthony Nicholls
25ee1b9e68 macOS: Simplify the CoreGraphics pointer types and add some new ones 2024-08-09 17:20:36 +01:00
reuk
b89553ae2c
Platform: Remove build-time Apple SDK availability checks 2024-07-03 13:50:08 +01:00
reuk
8ba2dc2ae2
Platform: Remove compatibility checks for Android 20 and earlier 2024-07-03 13:45:37 +01:00
reuk
6428f43eeb
Platform: Remove compatibility checks for iOS 10 2024-07-02 18:06:28 +01:00
reuk
8ac7bfc9ca
Platform: Remove compatibility checks for macOS 10.10 2024-07-02 18:06:27 +01:00
reuk
da8c5fdcb4
Platform: Remove compatibility checks for macOS 10.8 2024-07-02 18:06:27 +01:00
reuk
9112911122
MinGW: Remove support 2024-06-27 18:10:21 +01:00
reuk
1019614dcd
URLConnectionState: Use a shared NSURLSession to improve performance 2024-06-24 12:50:02 +01:00
reuk
1e3703fe64
URLConnectionState: Simplify and improve thread safety 2024-06-20 17:52:23 +01:00
reuk
ae75e27948
Network: Remove code for compatibility with unsupported platforms 2024-06-20 17:52:23 +01:00
reuk
74da0f977d
File: Remove broken dynamic load of GetFinalPathNamebyHandle 2024-04-29 16:08:24 +01:00
reuk
19061e6d17
Direct2D: Add initial support 2024-04-18 14:16:02 +01:00
reuk
0d2e34f34c
Typeface: Implement platform typefaces using Harfbuzz hb_font_t 2024-04-17 14:41:00 +01:00
reuk
1f9ba0682c
ComSmartPtr: Make ownership more explicit
COM objects now always start with a refcount of 1, as is convention.
2024-04-16 21:07:45 +01:00
attila
3548e51ef6 Android: Fix loading multiple classes from a single bytecode loader 2024-04-16 17:43:21 +01:00
Tom Poole
94d98a2b10 Update licensing information 2024-04-16 11:39:35 +01:00
Anthony Nicholls
fe00442335 Copyright: Fix incorrect or inconsistent copyright notices 2024-03-25 10:22:58 +00:00
reuk
c2398791be
ImageDemo: Fix permissions on mobile devices
Co-authored-by: MajorMurphy <major@murphyindustries.net>
2024-03-18 12:07:24 +00:00
reuk
047448fbce
Warnings: Add missing overrides 2024-01-30 11:37:30 +00:00
reuk
878aad687e
ObjCHelpers: Remove unnecessary __block variables 2024-01-16 13:00:56 +00:00
attila
3f52b29432 File: Avoid leaving behind file system changes when moveFileTo() fails 2024-01-09 11:14:30 +01:00
attila
6219eb950f Android: Fix crash when using NetworkServiceDiscovery 2023-12-18 15:09:35 +00:00
Anthony Nicholls
b0aa8dbb7c Formatting: Use nested namespace 2023-12-14 14:48:08 +00:00