Browse Source

Do not use new vista-only file choosers on mingw

Signed-off-by: falkTX <falktx@falktx.com>
pull/22/head
falkTX 3 years ago
parent
commit
7a6711bb55
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      modules/juce_gui_basics/native/juce_win32_FileChooser.cpp

+ 4
- 0
modules/juce_gui_basics/native/juce_win32_FileChooser.cpp View File

@@ -166,6 +166,7 @@ private:
void operator() (LPWSTR ptr) const noexcept { CoTaskMemFree (ptr); } void operator() (LPWSTR ptr) const noexcept { CoTaskMemFree (ptr); }
}; };
#if JUCE_MSVC
bool showDialog (IFileDialog& dialog, bool async) bool showDialog (IFileDialog& dialog, bool async)
{ {
FILEOPENDIALOGOPTIONS flags = {}; FILEOPENDIALOGOPTIONS flags = {};
@@ -383,6 +384,7 @@ private:
return result; return result;
} }
#endif
Array<URL> openDialogPreVista (bool async) Array<URL> openDialogPreVista (bool async)
{ {
@@ -499,11 +501,13 @@ private:
const Remover remover (*this); const Remover remover (*this);
#if JUCE_MSVC
if (SystemStats::getOperatingSystemType() >= SystemStats::WinVista if (SystemStats::getOperatingSystemType() >= SystemStats::WinVista
&& customComponent == nullptr) && customComponent == nullptr)
{ {
return openDialogVistaAndUp (async); return openDialogVistaAndUp (async);
} }
#endif
return openDialogPreVista (async); return openDialogPreVista (async);
} }


Loading…
Cancel
Save