7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-04-19 23:31:40 +00:00

Include project in output path text resolver.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19659
This commit is contained in:
Jeff Young 2025-01-16 17:05:12 +00:00
parent e09b095533
commit 6f32ecafe5

View File

@ -21,6 +21,7 @@
#include <jobs/job.h>
#include <wx/filename.h>
#include <common.h>
#include <project.h>
JOB::JOB( const std::string& aType, bool aOutputIsDirectory ) :
m_type( aType ),
@ -101,7 +102,13 @@ wxString JOB::GetFullOutputPath( PROJECT* aProject ) const
std::function<bool( wxString* )> textResolver =
[&]( wxString* token ) -> bool
{
return m_titleBlock.TextVarResolver( token, aProject );
if( m_titleBlock.TextVarResolver( token, aProject ) )
return true;
if( aProject )
return aProject->TextVarResolver( token );
return false;
};
// use the working output path (nonsaved) over the configured path if its not empty