From ea04a4af7d839520f88677d2b02a92d17d8c2711 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Mon, 27 May 2013 15:59:10 +0200 Subject: [PATCH] eeschema: netlist dialog: fix a very minor issue. --- eeschema/dialogs/dialog_netlist.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/eeschema/dialogs/dialog_netlist.cpp b/eeschema/dialogs/dialog_netlist.cpp index 0964609497..e745c5be53 100644 --- a/eeschema/dialogs/dialog_netlist.cpp +++ b/eeschema/dialogs/dialog_netlist.cpp @@ -475,18 +475,22 @@ void NETLIST_DIALOG::GenNetlist( wxCommandEvent& event ) } fn.SetExt( fileExt ); - wxString fullfilname = fn.GetFullName(); + + if( fn.GetPath().IsEmpty() ) + fn.SetPath( wxGetCwd() ); + + wxString fullfilename = fn.GetFullPath(); if( !GetUseDefaultNetlistName() || currPage->m_IdNetType >= NET_TYPE_CUSTOM1 ) { wxFileDialog dlg( this, title, fn.GetPath(), - fullfilname, fileWildcard, + fullfilename, fileWildcard, wxFD_SAVE ); if( dlg.ShowModal() == wxID_CANCEL ) return; - fullfilname = dlg.GetPath(); + fullfilename = dlg.GetPath(); } m_Parent->ClearMsgPanel(); @@ -496,7 +500,7 @@ void NETLIST_DIALOG::GenNetlist( wxCommandEvent& event ) else m_Parent->SetNetListerCommand( wxEmptyString ); - m_Parent->CreateNetlist( currPage->m_IdNetType, fullfilname, netlist_opt ); + m_Parent->CreateNetlist( currPage->m_IdNetType, fullfilename, netlist_opt ); WriteCurrentNetlistSetup();