Double check file dlg results on MSW.

This commit is contained in:
Jeff Young
2025-07-03 17:35:34 -06:00
parent 762fd179d3
commit 54cfb62597
+6 -1
View File
@@ -409,8 +409,13 @@ int KICAD_MANAGER_CONTROL::openProject( const wxString& aDefaultDir )
if( !pro.IsAbsolute() )
pro.MakeAbsolute();
if( !pro.FileExists() )
// You'd think wxFD_FILE_MUST_EXIST and the wild-cards would enforce these. Sentry
// indicates otherwise (at least on MSW).
if( !pro.Exists() || ( pro.GetExt() != FILEEXT::ProjectFileExtension
&& pro.GetExt() != FILEEXT::LegacyProjectFileExtension ) )
{
return -1;
}
m_frame->LoadProject( pro );