← Back to team overview

kicad-developers team mailing list archive

Re: [PATCH] Wildcard tests + removed variadic interface

 

Am 2019-01-08 09:16, schrieb John Beard:
Hi,

Here are some patches for wildcards:

* Add some tests to demo the API and expected output.
* Remove a variadic function signature and replace with one that takes
a std::vector<std::string>. This allows better and more typesafe use
of this API at run time.
* Unify the "all files" wildcard handling. Avoids unexpected needs to
call translation functions and sticks to a single idiom for getting
wildcards (call one of these functions).

Could a Windows user please check `make test` works before commit? I
did check it by fiddling with the defines, but good to be sure.

Hi John-

wx provides wxFileSelectorDefaultWildcardStr[1] that maps to the appropriate "*.*" for Windows and "*" for Mac/Linux. You may want to utilize that instead of the hard-coded "*"

-S

[1] https://docs.wxwidgets.org/3.0/filedlg_8h.html#a3a48d9b7ad35e6c332acb146f78c1b5d


Follow ups

References