Add support for specifying child process cwd and env to wxExecute().
Add an optional wxExecuteEnv parameter to wxExecute() which allows to specify the initial working directory and custom environment for the child process. Closes #12163. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65896 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -128,7 +128,8 @@ MRESULT APIENTRY wxExecuteWindowCbk( HWND hWnd,
|
||||
|
||||
long wxExecute( const wxString& rCommand,
|
||||
int flags,
|
||||
wxProcess* pHandler)
|
||||
wxProcess* pHandler,
|
||||
const wxExecuteEnv *env)
|
||||
{
|
||||
if (rCommand.empty())
|
||||
{
|
||||
@@ -219,6 +220,7 @@ long wxExecute(
|
||||
char** ppArgv
|
||||
, int flags
|
||||
, wxProcess* pHandler
|
||||
, const wxExecuteEnv *env
|
||||
)
|
||||
{
|
||||
wxString sCommand;
|
||||
@@ -234,6 +236,7 @@ long wxExecute(
|
||||
return wxExecute( sCommand
|
||||
,flags
|
||||
,pHandler
|
||||
, env
|
||||
);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user