DS_DATA_MODEL::LoadDrawingSheet actually was meant to accept blank filenames as a good thing
It was there...if you stared at it long enough
This commit is contained in:
parent
a38ad7f678
commit
0dd746548a
|
@ -817,12 +817,19 @@ bool DS_DATA_MODEL::LoadDrawingSheet( const wxString& aFullFileName, bool Append
|
||||||
if( fullFileName.IsEmpty() )
|
if( fullFileName.IsEmpty() )
|
||||||
wxGetEnv( wxT( "KICAD_WKSFILE" ), &fullFileName );
|
wxGetEnv( wxT( "KICAD_WKSFILE" ), &fullFileName );
|
||||||
|
|
||||||
if( fullFileName.IsEmpty() || !wxFileExists( fullFileName ) )
|
|
||||||
|
if( fullFileName.IsEmpty() )
|
||||||
{
|
{
|
||||||
#if 0
|
#if 0
|
||||||
if( !fullFileName.IsEmpty() )
|
if( !fullFileName.IsEmpty() )
|
||||||
wxLogMessage( wxT( "Drawing sheet file <%s> not found" ), fullFileName.GetData() );
|
wxLogMessage( wxT( "Drawing sheet file <%s> not found" ), fullFileName.GetData() );
|
||||||
#endif
|
#endif
|
||||||
|
SetDefaultLayout();
|
||||||
|
return true; // we assume its fine / default init
|
||||||
|
}
|
||||||
|
|
||||||
|
if( !wxFileExists( fullFileName ) )
|
||||||
|
{
|
||||||
SetDefaultLayout();
|
SetDefaultLayout();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue