diff --git a/src/msw/dir.cpp b/src/msw/dir.cpp index 7254b6553c..f406a91281 100644 --- a/src/msw/dir.cpp +++ b/src/msw/dir.cpp @@ -76,7 +76,7 @@ CheckFoundMatch(const FIND_STRUCT* finddata, const wxString& filter) if ( filter.empty() ) return true; - return ::PathMatchSpecEx(finddata->cFileName, filter, PMSF_NORMAL) == S_OK; + return ::PathMatchSpec(finddata->cFileName, filter) == TRUE; } inline bool diff --git a/tests/file/dir.cpp b/tests/file/dir.cpp index 17d715b108..fa2b836900 100644 --- a/tests/file/dir.cpp +++ b/tests/file/dir.cpp @@ -167,7 +167,7 @@ TEST_CASE_METHOD(DirTestCase, "Dir::Traverse", "[dir]") } else if (wxDir::GetAllFiles(DIRTEST_FOLDER, &files, "d" + WILDCARD_ALL) == 4) { - WARN("PathMatchSpecEx() seems to work under Wine now"); + WARN("PathMatchSpec() seems to work under Wine now"); } // enum all files according to the filter @@ -287,14 +287,14 @@ TEST_CASE("Dir::Match", "[.]") // Show the results of matching the pattern using various functions. wxPrintf("%-15s %20s %20s %20s\n", - "File", "wxString::Matches", "wxMatchWild", "PathMatchSpecEx"); + "File", "wxString::Matches", "wxMatchWild", "PathMatchSpec"); for ( const auto& fn : filenames ) { wxPrintf("%-15s %20d %20d %20d\n", fn, fn.Matches(filter), wxMatchWild(filter, fn), - PathMatchSpecEx(fn.wc_str(), filter.wc_str(), PMSF_NORMAL) == S_OK); + PathMatchSpec(fn.wc_str(), filter.wc_str()) == TRUE); } }