Look in multiple paths when searching for resource files of samples
When using an out of source build, the files are not in the default wxWidgets directories. Also search in the current directory, parent directory and sample sub-directories. Closes https://trac.wxwidgets.org/ticket/18118
This commit is contained in:
@@ -913,6 +913,7 @@ void TextWidgetsPage::OnButtonLoad(wxCommandEvent& WXUNUSED(event))
|
||||
wxPathList pathlist;
|
||||
pathlist.Add(wxT("."));
|
||||
pathlist.Add(wxT(".."));
|
||||
pathlist.Add(wxT("../widgets"));
|
||||
pathlist.Add(wxT("../../../samples/widgets"));
|
||||
|
||||
wxString filename = pathlist.FindValidPath(wxT("textctrl.cpp"));
|
||||
|
Reference in New Issue
Block a user