reuk
33e81616ad
MessageManager: Improve thread safety of Lock type
Previously, the following sequence of events was possible:
Background thread Main thread
------------------------------------------------------------------------
Lock::tryAcquire()
Run to blockingMessage->post()
BlockingMessage::messageCallback()
Run to abortWait.set (1)
Lock::tryAcquire()
Exit through return true
Lock::~Lock()
Destroy memory used for Lock
BlockingMessage::messageCallback()
Execute lockedEvent.signal()
Memory already freed, crash
2 years ago
Anthony Nicholls
05d5c94990
Native: Rename all native files for improved consistency
2 years ago
reuk
10bd8235e7
Plugin Client: Move all private helper functions into detail namespace
2 years ago
attila
d246cc280d
MessageManager: Add mutex to isThisTheMessageThread() and setCurrentThreadAsMessageThread()
3 years ago
Tom Poole
83176e23ca
Add a version ID macro
3 years ago
Tom Poole
dea3fe60e4
Update copyright banners
3 years ago
ed
11d872ea1b
MessageMananger: Made dispatchNextMessageOnSystemQueue() accessible by internal code
4 years ago
ed
76d5c07c66
MessageManager: Only reinitialise platform-specific code on Windows when calling setCurrentThreadAsMessageThread()
4 years ago
Tom Poole
894e7d2bd2
Updated all license headers
5 years ago
Tom Poole
2d16374b14
Updated all license headers
5 years ago
ed
59a058fdc6
Fixed some warnings flagged up when enabling -Wswitch-enum, -Wswitch-default, -Wredundant-decls, and -Wimplicit-fallthrough
6 years ago
reuk
c80285463a
MessageManager: Obey the rule of useful return in callAsync
6 years ago
ed
922730f685
Whitespace
6 years ago
Tom Poole
79d3e8b3f5
Windows: Removed some VS2013 workarounds
6 years ago
jules
0367d5c3a9
Added some PopupMenu::addItem overloads which let you attach a lambda callback to be invoked for a menu item.
6 years ago
jules
cadac817c6
Enabled some more warning flags in Xcode, and fixed the problems they caused
7 years ago
jules
5979288706
Added some macros for asserting when functions are called in an unsafe manner outside the message thread.
7 years ago
jules
6fda0bffca
Fixed some stray zeros that were still being passed as null pointers
7 years ago
jules
1e6bbb8da9
Added some methods to allow ReferenceCountedObjectPtrs to be constructed or copied from references as well as pointers - as well as increasing safety, this actually makes things a bit more efficient as it skips a nullptr check. Updated lots of places in the code that could take advantage of this
7 years ago
jules
e2dcc32f88
Updated old code where the 'volatile' keyword was still being used
7 years ago
jules
48a5fbd333
Another batch of ScopedPointer cleanups
8 years ago
Tom Poole
8cecf0baf9
Assorted threading and undefined behaviour fixes
8 years ago
jules
f3cde9763a
Quick tidy-up of some messaging classes
8 years ago
jules
f85d706131
Some minor formatting and comment fixes
8 years ago
jules
2dc9316420
Misc ScopedPointer changes to start using reset() and get() rather than assignments and casts (part of an ongoing drift towards more std::unique_ptr compatibility)
8 years ago
hogliux
b9b34393d1
Improved scheduling when multiple threads are fighting for the MessageManagerLock
8 years ago
jules
eda613c6db
Moved all "namespace juce" declarations from module headers to the individual .h and .cpp source files. This makes life a lot easier for Intellisense and other IDE autocompletion tools
8 years ago
hogliux
b5afccc37c
Updated file headers and the README with the JUCE 5 license
8 years ago
jules
60e9231fb1
Removed need for std::function in order to use MessageManager::callAsync(). Used it to modernise a few bits of old code.
9 years ago
hogliux
42305de6da
Added method OpenGLContext::executeOnGLThread to help executing gl house-keeping tasks on the gl thread even when the message manager is locked
9 years ago
tpoole
2e84129479
Updated the juce_audio_basics, juce_audio_devices, juce_blocks_basics, juce_core and juce_events modules to a new ISC license
9 years ago
hogliux
c7b8e77031
Update copyright notice
10 years ago
jules
f799bb0d6b
Another fix for Windows builds with modal comps disabled.
11 years ago
jules
5fc76082e2
Fix for Windows builds with modal components disabled.
11 years ago
jules
89854c55b9
Added flag JUCE_COMPILER_SUPPORTS_LAMBDAS
11 years ago
jules
df3e039bf9
Added a handy static method MessageManager::callAsync() which can asynchronously invoke a lambda on the message thread.
11 years ago
jules
005f0be531
Better cleanup in MessageManagerLock to avoid spurious assertions when a lock fails on shutdown.
11 years ago
jules
7b8ab7b503
Changed MessageBase::post() to return a bool to detect failure in the OS message queue (which can happen under stress on win32), and used this to avoid some messaging classes getting stuck.
11 years ago
jules
619716751e
Tweaked the ScopedJuceInitialiser_GUI to use reference-counting internally, and used it to replace/simplify some similar objects in the plugin wrapper classes.
11 years ago
jules
505bdcea88
Allowed JUCEApplicationBase::quit() to be called from non-message threads on OSX.
12 years ago
jules
42aa27900b
Moved most of the functionality from JUCEApplication into JUCEApplicationBase, so that it can be used without needing juce_gui_basics to be present.
12 years ago
jules
6045915256
Fixed a namespace problem with the iOS build.
12 years ago
jules
5918d039ce
Added some "override" annotations.
12 years ago
jules
03c2801f3f
Copyright header update in all module files. juce_core modules are now ISC licensed. All other modules are GPLv2/3/AGPLv3
12 years ago
jules
7452efb9e7
safety-check in Label. Typo fix in MessageManager.
12 years ago
jules
67341e7c4d
Tweak to runDispatchLoopUntil timekeeping.
12 years ago
jules
ba2dc52b34
Made use of @autoreleasepool for clang builds.
13 years ago
jules
0ceeb573d8
Minor changes to avoid pedantic compiler warnings.
13 years ago
jules
d1757b5e8a
Minor stuff.
13 years ago
jules
1f95f54089
Purged some warnings.
14 years ago