Pcbnew: try to fix an issue about frame title.
for Pcbnew, this issue (see bug 8404) is only seen on OSX. So I am blindly trying to add to Pcbnew a fix made for Eeschema.
This commit is contained in:
parent
31da3e7dc6
commit
60dbda9dd2
|
@ -1140,6 +1140,8 @@ bool PCB_EDIT_FRAME::doAutoSave()
|
|||
{
|
||||
wxFileName tmpFileName;
|
||||
|
||||
wxString title = GetTitle(); // Save frame title, that can be modified by the save process
|
||||
|
||||
if( GetBoard()->GetFileName().IsEmpty() )
|
||||
{
|
||||
tmpFileName = wxFileName( PATHS::GetDefaultUserProjectsPath(), wxT( "noname" ),
|
||||
|
@ -1184,11 +1186,15 @@ bool PCB_EDIT_FRAME::doAutoSave()
|
|||
GetSettingsManager()->TriggerBackupIfNeeded( NULL_REPORTER::GetInstance() );
|
||||
}
|
||||
|
||||
SetTitle( title ); // Restore initial frame title
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
GetBoard()->SetFileName( tmpFileName.GetFullPath() );
|
||||
|
||||
SetTitle( title ); // Restore initial frame title
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue