--- a/gfxconversion/mifconv/src/mifconv_util.cpp Thu May 27 13:23:07 2010 +0300
+++ b/gfxconversion/mifconv/src/mifconv_util.cpp Tue Jul 06 14:53:04 2010 +0300
@@ -28,6 +28,7 @@
#endif
#include <stdlib.h> // for _MAX_PATH
#include <stdio.h>
+#include <cctype>
#ifndef _MAX_PATH
#define _MAX_PATH (260)
@@ -192,6 +193,26 @@
/**
*
*/
+void MifConvUtil::ReplaceStr( MifConvString& str,
+ MifConvString replaceFrom, MifConvString replaceTo)
+{
+ if( str.length() >= replaceFrom.length() )
+ {
+ MifConvString::size_type index = 0;
+ while( (index = str.find(replaceFrom, index)) != MifConvString::npos )
+ {
+ MifConvString tmp_str = str.substr(0, index);
+ tmp_str = tmp_str + replaceTo;
+ str = tmp_str + str.substr(index+replaceFrom.length(),
+ str.length()-index+replaceFrom.length()
+ );
+ }
+ }
+}
+
+/**
+ *
+ */
void MifConvUtil::SplitPath( const MifConvString& sourcePath, MifConvString& drive, MifConvString& path)
{
if( sourcePath.length() > 0 )