Fix default User Template location
When we assign a string to the wxFilename, it takes the last section as
the filename (unless there is a trailing '/'). So on Linux, we got
/home/user for the Documents dir and /home/ was the directory while
'user' was the filename. Appending directories 'kicad/templates' made
the final directory '/home/kicad/templates'. Forcing this to be a
directory restores correct behavior.
(cherry picked from commit 0ee38653f7
)
This commit is contained in:
parent
c0e1f7a17a
commit
06d2170501
|
@ -445,7 +445,7 @@ bool PGM_BASE::InitPgm()
|
|||
else
|
||||
{
|
||||
// Default user template path.
|
||||
tmpFileName = wxStandardPaths::Get().GetDocumentsDir();
|
||||
tmpFileName.AssignDir( wxStandardPaths::Get().GetDocumentsDir() );
|
||||
tmpFileName.AppendDir( "kicad" );
|
||||
tmpFileName.AppendDir( "template" );
|
||||
envVarItem.SetDefinedExternally( false );
|
||||
|
|
Loading…
Reference in New Issue