From 0612ef29779bdb2f557e002ce90d4a069917647f Mon Sep 17 00:00:00 2001 From: abd Date: Wed, 13 Sep 2006 14:42:30 +0000 Subject: [PATCH] Replace 'cp' to 'xcopy' for Win32 --- src/VISU_I/VISU_Gen_i.cc | 34 +++++++++++++++++++++++----------- src/VISU_I/VISU_Result_i.cc | 9 ++++++++- 2 files changed, 31 insertions(+), 12 deletions(-) diff --git a/src/VISU_I/VISU_Gen_i.cc b/src/VISU_I/VISU_Gen_i.cc index 34c3d37a..ce90dc65 100644 --- a/src/VISU_I/VISU_Gen_i.cc +++ b/src/VISU_I/VISU_Gen_i.cc @@ -333,17 +333,24 @@ namespace VISU if(theIsMultiFile){ aFileName = SALOMEDS_Tool::GetNameFromPath(aStudy->URL()) + aFileName; - std::ostringstream aStream; + + + + //std::ostringstream aStream; #ifndef WNT - aStream<<"cp "< #include #include +#include // VTK Includes #include @@ -1161,9 +1162,15 @@ Create(const char* theFileName) #ifndef WNT aCommand.sprintf("cp %s %s", #else - aCommand.sprintf("xcopy %s %s /Y /Q", + aCommand.sprintf("xcopy %s %s", #endif myFileInfo.absFilePath().latin1(),aTmpDir.c_str()); + aCommand = QDir::convertSeparators( aCommand ); + +#ifdef WNT + aCommand += " /Y /R"; +#endif + if(system(aCommand) == -1){ MESSAGE("Create - Can't execute the command :"<