mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Component::MouseListenerList: Fix bad access
This commit is contained in:
parent
b01d8c3619
commit
c1f3d30679
1 changed files with 6 additions and 1 deletions
|
|
@ -123,7 +123,12 @@ public:
|
|||
template <typename EventMethod, typename... Params>
|
||||
static void sendMouseEvent (HierarchyChecker& checker, EventMethod&& eventMethod, Params&&... params)
|
||||
{
|
||||
if (auto* list = checker.nearestNonNullParent()->mouseListeners.get())
|
||||
auto* parent = checker.nearestNonNullParent();
|
||||
|
||||
if (parent == nullptr)
|
||||
return;
|
||||
|
||||
if (auto* list = parent->mouseListeners.get())
|
||||
{
|
||||
for (int i = list->listeners.size(); --i >= 0;)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue