27 #include <wx/stdpaths.h> 31 const wxString& aTableName ) :
33 m_defaultFileFound( false )
39 tmp.Printf(
_(
"Configure Global %s Library Table" ), aTableName.Capitalize() );
42 tmp.Printf(
_(
"KiCad has been run for the first time using the new %s library table for\n" 43 "accessing libraries. In order for KiCad to access %s libraries,\n" 44 "you must configure your global %s library table. Please select from one\n" 45 "of the options below. If you are not sure which option to select, please\n" 46 "use the default selection." ), aTableName, aTableName, aTableName );
49 tmp.Printf(
_(
"Copy default global %s library table (recommended)"), aTableName );
51 tmp.Printf(
_(
"Select this option if you not sure about configuring the global %s library " 52 "table" ), aTableName );
55 tmp.Printf(
_(
"Copy custom global %s library table" ), aTableName );
57 tmp.Printf(
_(
"Select this option to copy a %s library table file other than the default" ),
61 tmp.Printf(
_(
"Create an empty global %s library table" ), aTableName );
63 tmp.Printf(
_(
"Select this option to define %s libraries in project specific library tables" ),
67 tmp.Printf(
_(
"Select global %s library table file:" ), aTableName );
74 wxButton* okButton = (wxButton *) FindWindowById( wxID_OK );
77 okButton->SetDefault();
105 if( !wxDialog::TransferDataToWindow() )
114 wxString templatePath =
115 Pgm().GetLocalEnvVariables().at( wxT(
"KICAD6_TEMPLATE_DIR" ) ).GetValue();
117 if( !templatePath.IsEmpty() )
120 templatePath = wxStandardPaths::Get().GetUserConfigDir();
125 wxString fileName = ss.FindValidPath( fn.GetName() );
virtual void onUpdateFilePicker(wxUpdateUIEvent &aEvent) override
wxRadioButton * m_defaultRb
virtual ~DIALOG_GLOBAL_LIB_TABLE_CONFIG()
System directories search utilities.
DIALOG_GLOBAL_LIB_TABLE_CONFIG(wxWindow *aParent, const wxString &aTableName)
wxRadioButton * m_customRb
wxStaticText * m_staticText2
Look for files in a number of paths.
Class DIALOG_GLOBAL_LIB_TABLE_CONFIG_BASE.
virtual bool TransferDataToWindow() override
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
wxStaticText * m_staticText1
void SystemDirsAppend(SEARCH_STACK *aSearchStack)
Append system places to aSearchStack in a platform specific way and pertinent to KiCad programs.
wxRadioButton * m_emptyRb
virtual wxFileName GetGlobalTableFileName()=0
void finishDialogSettings()
In all dialogs, we must call the same functions to fix minimal dlg size, the default position and per...
wxFilePickerCtrl * m_filePicker1
virtual void onUpdateDefaultSelection(wxUpdateUIEvent &aEvent) override
void AddPaths(const wxString &aPaths, int aIndex=-1)
Insert or append path(s).