mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-21 01:24:21 +00:00
Allow mouse events to pass to FilePreviewComponent in native file choosers
This commit is contained in:
parent
aee19ad963
commit
e5d1e0008e
2 changed files with 16 additions and 0 deletions
|
|
@ -188,6 +188,14 @@ public:
|
|||
finished (result);
|
||||
}
|
||||
|
||||
bool canModalEventBeSentToComponent (const Component* targetComponent) override
|
||||
{
|
||||
if (targetComponent == nullptr)
|
||||
return false;
|
||||
|
||||
return targetComponent->findParentComponentOfClass<FilePreviewComponent>() != nullptr;
|
||||
}
|
||||
|
||||
private:
|
||||
//==============================================================================
|
||||
#if defined (MAC_OS_X_VERSION_10_6) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
|
||||
|
|
|
|||
|
|
@ -558,6 +558,14 @@ public:
|
|||
owner.finished (nativeFileChooser->results);
|
||||
}
|
||||
|
||||
bool canModalEventBeSentToComponent (const Component* targetComponent) override
|
||||
{
|
||||
if (targetComponent == nullptr)
|
||||
return false;
|
||||
|
||||
return targetComponent->findParentComponentOfClass<FilePreviewComponent>() != nullptr;
|
||||
}
|
||||
|
||||
private:
|
||||
FileChooser& owner;
|
||||
Win32NativeFileChooser::Ptr nativeFileChooser;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue