diff options
Diffstat (limited to 'kfilereplace/kfilereplacepart.cpp')
-rw-r--r-- | kfilereplace/kfilereplacepart.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/kfilereplace/kfilereplacepart.cpp b/kfilereplace/kfilereplacepart.cpp index adfd6a4f..3955e643 100644 --- a/kfilereplace/kfilereplacepart.cpp +++ b/kfilereplace/kfilereplacepart.cpp @@ -1029,7 +1029,7 @@ void KFileReplacePart::replaceAndBackup(const TQString& currentDir, const TQStri if (m_option->m_encoding == "utf8") currentStream.setEncoding(TQTextStream::UnicodeUTF8); else - currentStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding)); + currentStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding.ascii())); TQString line = currentStream.read(), backupLine = line; @@ -1068,7 +1068,7 @@ void KFileReplacePart::replaceAndBackup(const TQString& currentDir, const TQStri if (m_option->m_encoding == "utf8") newStream.setEncoding(TQTextStream::UnicodeUTF8); else - newStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding)); + newStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding.ascii())); newStream << line; newFile.close(); } @@ -1121,7 +1121,7 @@ void KFileReplacePart::replaceAndOverwrite(const TQString& currentDir, const TQS if (m_option->m_encoding == "utf8") oldStream.setEncoding(TQTextStream::UnicodeUTF8); else - oldStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding)); + oldStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding.ascii())); TQString line = oldStream.read(); oldFile.close(); @@ -1146,7 +1146,7 @@ void KFileReplacePart::replaceAndOverwrite(const TQString& currentDir, const TQS if (m_option->m_encoding == "utf8") newStream.setEncoding(TQTextStream::UnicodeUTF8); else - newStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding)); + newStream.setCodec(TQTextCodec::codecForName(m_option->m_encoding.ascii())); newStream << line; newFile.close(); } @@ -1340,7 +1340,7 @@ void KFileReplacePart::search(const TQString& currentDir, const TQString& fileNa if (m_option->m_encoding == "utf8") stream.setEncoding(TQTextStream::UnicodeUTF8); else - stream.setCodec(TQTextCodec::codecForName(m_option->m_encoding)); + stream.setCodec(TQTextCodec::codecForName(m_option->m_encoding.ascii())); TQString line = stream.read(); file.close(); |