X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/716d0327363e81485eb6dd13b62d6f83c9dd4bab..3e1924dd5f5744c3e2a8973de9b3e4f372b7fd85:/src/mac/carbon/dirmac.cpp?ds=sidebyside diff --git a/src/mac/carbon/dirmac.cpp b/src/mac/carbon/dirmac.cpp index 3dd53627a6..52e9a61e0f 100644 --- a/src/mac/carbon/dirmac.cpp +++ b/src/mac/carbon/dirmac.cpp @@ -125,13 +125,14 @@ bool wxDirData::Read(wxString *filename) } wxString name ; + wxString lowerfilespec = m_filespec.Lower(); while( noErr == err ) { HFSUniStr255 uniname ; FSRef fileRef; FSCatalogInfo catalogInfo; - UInt32 fetched = 0; + ItemCount fetched = 0; err = FSGetCatalogInfoBulk( m_iterator, 1, &fetched, NULL, kFSCatInfoNodeFlags | kFSCatInfoFinderInfo , &catalogInfo , &fileRef, NULL, &uniname ); @@ -146,6 +147,7 @@ bool wxDirData::Read(wxString *filename) break ; name = wxMacHFSUniStrToString( &uniname ) ; + wxString lowername = name.Lower(); if ( ( name == wxT(".") || name == wxT("..") ) && !(m_flags & wxDIR_DOTDOT) ) continue; @@ -167,7 +169,7 @@ bool wxDirData::Read(wxString *filename) if ( m_filespec.empty() || m_filespec == wxT("*.*") || m_filespec == wxT("*") ) { } - else if ( !wxMatchWild(m_filespec, name , false) ) + else if ( !wxMatchWild(lowerfilespec, lowername , false) ) { continue ; }