* Fixed Async -> sync in wxExecute

* Added documentation about wxProcess, ...
* Added wxDataStream::WriteString and wxDataStream::ReadString


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@178 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Guilhem Lavaux
1998-07-03 17:44:34 +00:00
parent 884360bc11
commit eafc087e69
7 changed files with 91 additions and 11 deletions

View File

@@ -364,7 +364,7 @@ static void GTK_EndProcessDetector(gpointer data, gint source,
proc_data->pid = 0;
};
long wxExecute( char **argv, bool Async, wxProcess *process )
long wxExecute( char **argv, bool sync, wxProcess *process )
{
wxEndProcessData *data = new wxEndProcessData;
int end_proc_detect[2];
@@ -409,7 +409,7 @@ long wxExecute( char **argv, bool Async, wxProcess *process )
data->tag = gdk_input_add(end_proc_detect[0], GDK_INPUT_READ,
GTK_EndProcessDetector, (gpointer)data);
data->pid = pid;
if (Async) {
if (!sync) {
data->process = process;
} else {
data->process = NULL;
@@ -424,7 +424,7 @@ long wxExecute( char **argv, bool Async, wxProcess *process )
return pid;
};
long wxExecute( const wxString& command, bool Async, wxProcess *process )
long wxExecute( const wxString& command, bool sync, wxProcess *process )
{
if (command.IsNull() || command == "") return FALSE;
@@ -438,6 +438,6 @@ long wxExecute( const wxString& command, bool Async, wxProcess *process )
argv[argc++] = strtok (tmp, IFS);
while ((argv[argc++] = strtok(NULL, IFS)) != NULL)
/* loop */ ;
return wxExecute(argv, Async, process);
return wxExecute(argv, sync, process);
};