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

14923 commits

Author SHA1 Message Date
Anthony Nicholls
25ee1b9e68 macOS: Simplify the CoreGraphics pointer types and add some new ones 2024-08-09 17:20:36 +01:00
Anthony Nicholls
997c92797c macOS: Improve performance for some graphics draw functions 2024-08-09 14:29:53 +01:00
attila
29327144db
StackBasedLowLevelGraphicsContext: Prefer using RectangleListRegion clip when possible
This reverts a tiny part of 19061e6d17.
2024-08-06 17:36:19 +01:00
attila
dda0719d56
EdgeTable: Fix buggy clipToRegion corner case 2024-08-06 17:36:10 +01:00
attila
b083d3c6d8
MIDI: Fix compilation when JUCE_USE_WINRT_MIDI=1 2024-08-06 16:37:12 +01:00
attila
22ee31f3ff EdgeTable: Use HeapBlock instead of vector for better Android Debug drawing performance
This is reverting 417d97b36e.
2024-08-02 14:48:52 +00:00
Anthony Nicholls
cc96592e7c Graphics: Improve drawing performance for stroking paths on macOS 2024-08-02 10:28:15 +01:00
Anthony Nicholls
059b667af2 ListenerList: Replace ListenerList with LightweightListenerList in select places 2024-08-01 16:10:09 +00:00
Anthony Nicholls
2e6ee49cfa ListenerList: Add a LightweightListenerList class
When extra guarantees were added to ListenerList to guard against mutations of
the list from callbacks, it also resulted in removing a previously observable
guarantee that calls to the listeners could be made concurrently as long as
those listeners were themselves thread safe. This commit adds a new class that
restores that behaviour for anybody who needs it.
2024-08-01 16:10:09 +00:00
Anthony Nicholls
572f1c985c Assertions: Add preprocessor definitions for checking when assertions are enabled 2024-08-01 16:10:09 +00:00
Anthony Nicholls
b5bcf621f3 Thread: Fix a typo 2024-08-01 16:10:09 +00:00
Anthony Nicholls
e9b3fc8714 FocusHelpers: Reduce code nesting 2024-08-01 16:10:09 +00:00
Anthony Nicholls
dc0dde7fe9 FocusTraverser: Make more things const 2024-08-01 16:10:09 +00:00
Anthony Nicholls
9f3666e3e1 UnitTests: Reduce the stack size of the KeyboardFocusTraverser tests 2024-08-01 16:10:09 +00:00
reuk
a891f0054c
Windows: Allow constrained resize for windows that are not marked as resizable 2024-07-31 19:36:52 +01:00
reuk
3da5a3c9bd
ResizableWindow: Set resizable flag only when desktop does not support native nonclient resize 2024-07-31 19:36:52 +01:00
reuk
0ffe5948a5
Windows: Fix issue where maximised windows with non-native titlebars could slightly exceed the screen bounds
When handling WM_NCCALCSIZE, we reduce the size of the client area when
the window is maximised. If we don't do this, then the client area
matches the top-level window area, which is larger than the display's
safe area. As a result, the window appears too large, and the edges are
obscured under the edges of the display.

After reducing the client area in WM_NCCALCSIZE, the client area is no
longer equal to the top-level window area, so getBounds() must be
updated to return the window's *client* area rather than the top-level
window area.
2024-07-31 19:36:52 +01:00
reuk
63eb8c5692
Windows: Remove unused functions 2024-07-31 19:36:52 +01:00
reuk
d7bfecae28
Windows: Avoid changing window size after display settings change
Previously, a 'system info' change could cause the window size to
change, which was unexpected.
2024-07-31 19:36:51 +01:00
reuk
66aa42c9c0
VST3 Client: Fix parameter context menu in FL Studio
The change to the VST3 wrapper in
335f6e9591 broke context menu items in FL
Studio, so that clicking on a menu item had no effect. This could be
seen in the DSPModulePluginDemo example.

I'm not sure exactly what caused the breakage. Before the breaking
change, the menu remained alive until the point where the menu item was
triggered as it was leaked. After the breaking change, the IContextMenu
could be freed before a particular IContextMenuTarget was executed. My
guess is that FL Studio requires the menu to be alive when triggering a
particular menu item.

This change captures the IContextMenu inside the popup menu callback to
ensure that it remains alive until the PopupMenu is destroyed.
2024-07-31 19:36:51 +01:00
reuk
281c56f2f9
MidiFile: Fix invalid comparator argument to stable_sort
Previously, stable_sort was used to reorder note-ons and note-offs, with
the intention that note-offs would always be ordered before note-ons
with the same time stamp. However, stable_sort requires the comparator
to be a strict-weak ordering, which was not the case for the previous
implementation.

Additionally, the old implementation could unnecessarily reorder events.
Note ons and offs only need to be reordered if the note numbers and
channels match. It's fine for a note-on to be ordered before a note-off
if the note itself is different.

The new implementation only uses stable_sort to order events by
time-stamp. Then, for each range of events with matching timestamps, the
first note-on event will be swapped with the last following note-off
event with matching channel/number.
2024-07-31 19:36:51 +01:00
attila
fb670d209b Windows: Throttle VBlankThread when the display is off
When the display goes to sleep IDXGIOutput::WaitForVBlank returns S_OK
immediately causing the VBlankThread to consume a core entirely with the
VBlank related messaging.

To limit this problem, we use the same technique as Chromium presently
does, and we sleep for 1 ms, if the time between the last two VBlank
events was less than a ms. This limits the VBlankThread messaging rate
of about 50.000/s on an Intel 13600 to 1000/s.
2024-07-31 18:15:54 +02:00
reuk
4c5c336e65
Windowing: Re-enable rounded corners on Windows 11 2024-07-29 16:12:00 +01:00
reuk
9817a2bb66
Windowing: Allow window to keep repainting when mouse is held in caption area 2024-07-29 16:12:00 +01:00
reuk
ce7bafcfcb
Windowing: Reduce size of RenderContext interface 2024-07-29 16:12:00 +01:00
reuk
14f3751a06
Windowing: Fix issues with window border rendering/positioning 2024-07-29 16:12:00 +01:00
reuk
a43a69241c
Windowing: Ensure modifier key state is updated after clicking on window caption
Without this change, the mouse state was not always updated after
releasing the mouse, leaving the current modifier keys with the
left-mouse-button bit set. This was particularly evident in standalone
plugins, where clicking the 'options' button in the titlebar, then
immediately clicking the titlebar could "stick" the window to the mouse,
making it impossible to interact with the window normally.
2024-07-29 16:11:59 +01:00
reuk
664bc242b2
Windowing: Only begin mouse tracking for movement in the client area 2024-07-29 16:11:59 +01:00
reuk
eca3e074e5
Windowing: Respect modal state and enablement for native titlebar buttons 2024-07-29 16:11:59 +01:00
reuk
f26cce5a46
Windowing: Fix missing Close titlebar button
Prior to this change, windows such as the "Audio/MIDI Settings" window
for standalong plugins had no close button in the titlebar.
2024-07-29 16:11:59 +01:00
reuk
467f20a7a1
Reapply "Windows: Use new window hit-testing API to implement Windows window-management features like Aero Snap"
This reverts commit 086e2264895fa40059c451603abd491fb41f4558.
2024-07-29 16:11:59 +01:00
reuk
01cacf2958
VST3 Host: Supply an IRunLoop from the host context 2024-07-29 16:11:59 +01:00
reuk
ebc91a7e22
VST3 Client: Add support for fetching IRunLoop from host context 2024-07-29 16:11:59 +01:00
reuk
695a51832b
VST3 Client: Fix issue where active run loops could be removed incorrectly
The same run loop may be registered multiple times, e.g. if the host
passes the same run loop pointer to multiple instances of the plugin.
When a particular run loop client goes out of scope, it should only
remove its own reference to the run loop, because other clients may
still be active and still using that run loop.
2024-07-29 16:11:59 +01:00
reuk
6cc8827174
VST3 Client: Remove unnecessary class/struct keywords 2024-07-29 16:11:58 +01:00
reuk
6d5f8976ad
VST3 Client: Tidy up unnecessary namespaces 2024-07-29 16:11:58 +01:00
reuk
b319fabac5
VST3 Host: Remove unnecessary namespaces 2024-07-29 16:11:58 +01:00
reuk
b99e66c159
Harfbuzz: Silence clang overflow warning 2024-07-29 16:11:55 +01:00
reuk
ef31cbb620
DynamicObject: Make virtual functions non-virtual 2024-07-29 16:09:53 +01:00
Tom Poole
46c2a95905 JUCE version 8.0.1 2024-07-29 12:47:03 +01:00
reuk
12ef0a0200 HarfBuzz: Enable atexit to silence some CRT debug memory leak warnings
Before this change, after running a JUCE app on Windows under a
debugger, and quitting it normally (e.g. pressing the close title
button), the output log would display some memory leak diagnostics. This
is because HarfBuzz expects to clean up statics using atexit, but atexit
was not enabled. This change enables atexit on supported platforms,
including Windows.
2024-07-29 12:46:38 +01:00
Tom Poole
8f7f61652e Resave all projects 2024-07-29 12:46:05 +01:00
Tom Poole
fc0fd3042f Bump version number to 8.0.1 2024-07-29 12:43:19 +01:00
attila
04d9d36b15 TextLayout: Fix ignored AttributedText::getLineSpacing() parameter 2024-07-22 13:16:06 +02:00
attila
5de96da34d Graphics: Suppress warnings emitted by harfbuzz 2024-07-18 19:15:18 +02:00
Oliver James
57d33150d3 Unicode: Fix incorrect character ordering in Latin text
This addresses issues that could occur when re-ordering text that
contained brackets or numerical separators.
2024-07-18 19:15:17 +02:00
attila
ae23783f63 Windows: Fix rare crash when creating and destroying WebBrowserComponent instances 2024-07-15 14:37:13 +02:00
reuk
b35688d9a4
SimpleShapedText: Avoid wrapping when WordWrap::none is requested 2024-07-11 18:00:07 +01:00
reuk
b3fdcdc928
AUv3 Client: Allow auval to pass when plugin allows arbitrary matched input/output layouts 2024-07-11 16:56:20 +01:00
reuk
6fd7a928f9
AUv3 Client: Fix issue where creating a bus with no channels could fail
Previously, if the AudioProcessor had disabled buses, the AUv3 wrapper
would attempt to create zero-channel buses to represent the JUCE buses,
which failed.

With this change in place, disabled buses will be created with their
default layout, and then explicitly disabled.
2024-07-11 16:56:20 +01:00