1c19699a7c
The functions involved in the problem were PGM_BASE::GetEditorName and EDA_BASE_FRAME::OnSelectPreferredEditor: 1) OnSelectPreferredEditor showed a dialog to allow the user selecting the editor, but before that called GetEditorName to get the name of the current editor (to show as a default in the choose file dialog). 2) The problem was when there was no editor, GetEditorName showed its own dialog. 3) So the user was seeing first the dialog from (2) and then the dialog from (1). 4) As GetEditorName is used in many other places the solution I did was to add to it an optional parameter that tells it what to do if no editor is set. To avoid modifying other code that relies on the current behaviour, this parameter has a default value that causes to show the dialog. But now when OnSelectPreferredEditor calls it, it passes the parameter that causes it to return an empty string if no editor was set. 5) Also, I found a second bug while doing it which allowed in the first dialog to select an unexistent file (the dialog was missing the wxFD_FILE_MUST_EXIST flag). 6) Lastly, to avoid having duplicated code (the one that showed the same dialog and that configured the wildcard was in two methods) I created a single function that now both functions call: PGM_BASE::AskUserForPreferredEditor. This way we also will have consistency in the behaviour of both dialogs and there is a single place where it needs to be modified. |
||
---|---|---|
3d-viewer | ||
CMakeModules | ||
Documentation | ||
bitmap2component | ||
bitmaps_png | ||
common | ||
cvpcb | ||
demos | ||
eeschema | ||
gerbview | ||
helpers/tools_to_build_newstroke-font | ||
include | ||
kicad | ||
lib_dxf | ||
new | ||
packaging | ||
pagelayout_editor | ||
patches | ||
pcb_calculator | ||
pcbnew | ||
polygon | ||
potrace | ||
qa | ||
resources/linux/mime | ||
scripting | ||
scripts | ||
template | ||
tools | ||
utils | ||
.bzrignore | ||
.gitconfig | ||
AUTHORS.txt | ||
CHANGELOG.txt | ||
CMakeLists.txt | ||
CTestConfig.cmake | ||
Doxyfile | ||
INSTALL.txt | ||
README.txt | ||
TODO.txt | ||
copyright.h | ||
license_for_documentation.txt | ||
rules | ||
uncrustify.cfg |
README.txt
KiCad README ============ For specific documentation like Compiling, GUI translation, Old changelogs see the Documentation subfolder. Files ----- AUTHORS.txt - The authors, contributors, document writers and translators list CHANGELOG.txt - This years changelog (see for previous years Documentation/changelogs) CMakeList.txt - CMAKE build tool script COPYRIGHT.txt - A copy of the GNU General Public License Version 2 CTestConfig.cmake - Support for CTest and CDash testing tools Doxyfile - Doxygen config file for Kicad INSTALL.txt - The release (binary) installation instructions TODO.txt - Todo list uncrustify.cfg - Uncrustify config file for uncrustify sources formatting tool Subdirectories -------------- 3d-viewer - Sourcecode of 3D viewer bitmaps - Menu and program icons bitmap2component - Sourcecode of a small application to create a footprint or a component from a B&W bitmap this component or footprint has just graphic items that show the bitmap CMakeModules - Modules for the CMAKE build tool common - Sourcecode of the common library (common functions shared across whole suite) cvpcb - Sourcecode of CvPCB, tool to link components with footprints sourcecode demos - Some demo examples Documentation - Compiling documentation. Translating the GUI, old changelogs etcetera. eeschema - Sourcecode of the schematic editor gerbview - Sourcecode of the gerber viewer helpers - Helper tools and utilities for development include - Interfaces to the common library internat - Internationalisation files kicad - Sourcecode of the project manager packaging - Files for packaging on Windows and Mac OSX pcbnew - Sourcecode of the printed circuit board editor polygon - Sourcecode of the polygon library resources - Resources for installation, freedesktop mime-types for linux scripts - Helper scripts. For building, sourcecode packaging. template - Project template(s)