Honour platform standards on MSW for files beginning with '.'.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14221
This commit is contained in:
Jeff Young 2023-10-28 18:24:11 +01:00
parent 0747d35228
commit f6dc67dc3b
1 changed files with 4 additions and 2 deletions

View File

@ -380,10 +380,12 @@ wxTreeItemId PROJECT_TREE_PANE::addItemToProjectTree( const wxString& aName,
TREE_FILE_TYPE type = TREE_FILE_TYPE::UNKNOWN;
wxFileName fn( aName );
// Files/dirs names starting by "." are not visible files under unices.
// Skip them also under Windows
#ifndef __WXMSW__
// Files/dirs names starting by "." are not visible files under unices (including MacOS),
// but are under MSW.
if( fn.GetName().StartsWith( wxT( "." ) ) )
return wxTreeItemId();
#endif
if( wxDirExists( aName ) )
{