1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00
Commit graph

385 commits

Author SHA1 Message Date
reuk
83e5264c86
Formatting: Remove double-dots from comments and other strings 2025-11-18 15:47:42 +00:00
attila
a1a56cd54c Linux: WebBrowserComponent: Terminate subprocess if main process crashes 2025-10-14 17:57:55 +02:00
attila
7449867337 MacOS: Fix WebBrowserComponent going blank in FL Studio
The issue could be triggered by opening the plugin in FL Studio, and
then using the TAB button to switch between FL Studio UI elements, until
the plugin became invisible and then it became visible again. This would
cause the WebBrowserComponent to navigate to about:blank permanently.

This was caused by the component becoming invisible and visible again in
rapid succession. This triggered a navigation to about:blank. To
understand the root cause of this, some undocumented behaviour of
WkWebView had to be uncovered. To understand this, see the following
test code, where the test1, test2 and test3 functions are called with
ample time in between one after the other.

void test1()
{
    goToURL ("A");
}

void test2()
{
    goToURL ("B");
    goToURL ("C");

    // B, C ignored completely, only D inserted into back-forward navigation queue
    goToURL ("D");
}

void test3()
{
    goToURL ("E");
    goToURL ("F");

    // E, F ignored completely, back navigation executed from D to A
    goBack();
}
2025-10-09 17:52:29 +02:00
attila
bc8e9e05af Linux: WebBrowserComponent: Fix crash when accessing resources larger than 4k
This commit reverts 8e6aeab799.

The WebBrowserComponent subprocess calls tryNextRead() in an infinite
loop. Prior to the reverted change this allowed it to handle the
transfer of larger files, which would span multiple calls to the
function. The transfer state would be remembered in the receivingLength
and pos class members.

The simplification in 8e6aeab799 mainly
comes from moving these class members into function locals, but this
means, that the transfer state is lost whenever the break statements are
hit. This would cause bad access during the transfer of larger files.
2025-10-09 16:30:52 +02:00
Anthony Nicholls
e68627c9ed Smart Pointers: Add a new enum for indicating if a smart point should increment a reference count or not 2025-09-25 14:56:34 +01:00
reuk
3d8a97c1c1
Android: Update bytecode minimum version requirements 2025-09-17 12:50:06 +01:00
reuk
8ce1f19bf0
JNI: Tidying 2025-09-17 12:50:05 +01:00
attila
47d441787c Linux: Fix bad window error when using the XEmbedComponent
The issue was reproducible by opening a plugin window in the AudioPluginHost.
2025-09-10 11:06:38 +02:00
attila
0c2d55c7dd Linux: Fix XEmbedComponent::setVisible
This also affects the WebBrowserComponent. Prior to this fix calling
setVisible (false) had no effect.
2025-07-30 11:18:39 +02:00
reuk
1dab91e473
WebBrowserComponent: Avoid spinning indefinitely when reaching end of file 2025-06-23 20:33:42 +01:00
reuk
8e6aeab799
WebBrowserComponent: Refactor Linux implementation to simplify cross-process communication 2025-06-23 20:33:42 +01:00
reuk
d95cb61acf
WebBrowserComponent: Allow specifying request headers on Linux 2025-06-23 20:23:08 +01:00
attila
08b82c796b iOS: WebBrowserComponent: Fix unguarded feature only available on 18.4+ 2025-04-10 15:29:03 +02:00
reuk
51be8b9332
Android: Remove unnecessary SDK version checks 2025-03-19 11:06:17 +00:00
attila
389516feeb WebView frontend: Fix window.__JUCE__.backend.removeEventListener
Co-authored-by: Yong Gyu Lee <cosgenio@gmail.com>
2025-02-19 09:30:13 +00:00
reuk
2d01e326db
ObjCHelpers: Rename makeCGRect from makeNSRect 2025-01-23 12:20:27 +00:00
attila
90e72dbd98 Windows: Fix faulty mechanism for creating multiple WebView2 instances serially
Prior to this commit it was possible for the WebBrowserComponent
implementation on Windows to end up in an infinite loop if multiple
WebBrowserComponent objects were being created at the same time.

When an instance was already being created, the createWebView() call for
the second would place it in a queue and return without initiating its
creation. When the first WebView finishes creation, it calls the
handleAsyncUpdate() function of the second. However handleAsyncUdpate()
would see that the webViewBeingCreated helper variable was already true
and not call createWebView(), hence the second WebView would never be
created.

If, in the meantime, the scriptsWaitingForExecution variable wasn't
empty, handleAsyncUpdate() would endlessly call triggerAsyncUpdate().
2025-01-17 16:29:42 +01:00
reuk
8be78e9f7f
WebBrowserComponent: Avoid nullptr dereference when WebView2 loader library is not present 2025-01-07 11:21:14 +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
f72cf8ff14
WebBrowserComponent (macOS): Catch use after free async callback bug 2025-01-07 11:19:56 +00:00
reuk
269ebbb525
Accessibility: Add AccessibilityHandler::postSystemNotification() function for posting an OS-specific accessible notification 2024-12-04 11:11:21 +00:00
reuk
6d10eb536f
PushNotifications: Update Android implementation to properly request permissions 2024-12-04 11:09:18 +00:00
reuk
ed0092a8bc
PushNotifications: Assert instead of crashing if Android notification icon cannot be located 2024-12-04 11:09:18 +00:00
reuk
98031a814c
PushNotifications: Remove unnecessary qualifications in Android impl 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
reuk
3005b716fe
ObjCHelpers: Add new macros to help with version checking 2024-10-29 19:46:35 +00:00
reuk
80ac9a78a0
Singleton: Add new macros to simplify singleton creation
The INLINE macros allow singletons to be declared and defined in one
line, without requiring a separate JUCE_IMPLEMENT_SINGLETON statement.
2024-10-16 10:36:52 +01:00
reuk
b52f5cff21 WebBrowserComponent: Fix build issue on older linux platforms
Previously, building the DemoRunner on Ubuntu 18.04 failed due to a
missing type declaration.
2024-10-08 19:13:04 +01:00
attila
171edbec7f MacOS: Suppress deprecation warnings related to NSUserNotification
All NSUserNotification related classes have been deprecated in MacOS 11,
and this class will have to be revamped to use the new User
Notifications framework. We are suppressing the warnings for the time
being.
2024-10-03 16:56:34 +02:00
attila
46eed81aae Windows: WebBrowserComponent: Avoid infinite loops caused by CONNECTION_ABORTED errors
WebView2 can emit COREWEBVIEW2_WEB_ERROR_STATUS_CONNECTION_ABORTED
errors during page navigation, even if the page navigation would happen
correctly afterwards. In such situations our internal error handler can
recursively encounter this error when trying to navigate to the error
handler page.

Prior to this commit the implementation could end up in an infinite loop
receiving the error and then navigating to the error handler page.
2024-10-03 16:56:34 +02:00
Anthony Nicholls
6c2d149ef3 Versioning: Add the JUCE version number to any internally created threads 2024-09-26 08:10:56 +00:00
attila
5b98066a48 Windows: WebBrowserComponent: Fix visibility of initially not visible component
Prior to this commit a WebBrowserComponent created with
setVisible (false) would still be visible.
2024-09-05 16:41:25 +02:00
attila
a34bd74133 Windows: WebBrowserComponent: Fix state handling when the component is invisible
The handling of two state variables had to be adjusted. One is
responsible for signalling that we navigated to a blank page due to the
WebBrowserComponent becoming invisible. The other variable in the
WebView2 implementation stores the URL that we should be navigating to
once the WebView2 instance has been created.

Prior to this commit navigating to the URL requested by goToURL could
fail for two reasons: either because it was called before the underlying
WebView2 instance was created, or because the WebBrowserComponent was
not yet visible.
2024-08-22 17:04:55 +02:00
attila
ae23783f63 Windows: Fix rare crash when creating and destroying WebBrowserComponent instances 2024-07-15 14:37:13 +02:00
attila
7ead20d575 WebBrowserComponent: Windows: Avoid flash to default JUCE background colour
The default background colour of the WebBrowserComponent is white on all
platforms. Before the first page finishes loading this is the colour
that should fill the WebBrowserComponent's area.

Prior to this change however, on Windows a sudden flash to the default
JUCE background colour would occur, before the default white background
could take effect.

At the time of this commit there is a known issue with the
icorewebview2controller2, where a white flash is inevitable, unless the
WEBVIEW2_DEFAULT_BACKGROUND_COLOR environment variable is set. Using
a white background behind the WebView avoids this issue.
2024-07-11 13:36:07 +02:00
attila
9082d3274a Fix inactive sliderDragStarted/sliderDragEnded events in the WebView frontend library
This fixes the behaviour of WebBrowserComponent based plugins, including
the WebViewPluginDemo, when working with automations.
2024-07-04 13:59:30 +00:00
attila
f1954bbe4d Add missing documentation for Javascript helper classes 2024-07-04 13:59:30 +00:00
reuk
a858f91354
Platform: Remove deprecated code paths that will never be called 2024-07-03 14:50:08 +01:00
reuk
ba9b6581b7
Platform: Remove references to unsupported platforms in docs and strings 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
5391032238
Platform: Remove compatibility checks for iOS 11 2024-07-02 18:06:28 +01:00
reuk
6428f43eeb
Platform: Remove compatibility checks for iOS 10 2024-07-02 18:06:28 +01:00
reuk
e71ebb3407
Platform: Remove compatibility checks for macOS 10.11 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
6d4bf60330
Platform: Remove compatibility checks for macOS 10.9 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
4576a75388
Platform: Remove compatibility checks for macOS 10.7 2024-07-02 18:06:27 +01:00
attila
2516ad808e WebBrowserComponent: Linux: Add support for libwebkit2gtk-4.1 2024-06-11 20:51:22 +02:00
attila
abdf9a6b75 Add WebView related helper classes for implementing AudioProcessorEditor::getControlParameterIndex 2024-06-06 13:48:51 +02:00
attila
d61e516bbc Add the parameterIndex property to all WebView related parameter ParameterAttachments
This affects the WebSliderParameterAttachment,
WebToggleButtonParameterAttachment, and WebComboBoxParameterAttachment
classes.
2024-06-06 13:48:51 +02:00