View | Details | Raw Unified | Return to bug 12418
Collapse All | Expand All

(-)kdeutils-3.5.7-original/ark/arch.cpp (-2 / +8 lines)
Lines 33-38 Link Here
33
// QT includes
33
// QT includes
34
#include <qapplication.h>
34
#include <qapplication.h>
35
#include <qfile.h>
35
#include <qfile.h>
36
#include <qtextcodec.h>
36
37
37
// KDE includes
38
// KDE includes
38
#include <kdebug.h>
39
#include <kdebug.h>
Lines 303-317 Link Here
303
bool Arch::processLine( const QCString &line )
304
bool Arch::processLine( const QCString &line )
304
{
305
{
305
  QString columns[ 11 ];
306
  QString columns[ 11 ];
307
  QString unicode_line;
306
  unsigned int pos = 0;
308
  unsigned int pos = 0;
307
  int strpos, len;
309
  int strpos, len;
308
310
311
  QTextCodec *codec = QTextCodec::codecForLocale();
312
  unicode_line = codec->toUnicode( line );
313
314
309
  // Go through our columns, try to pick out data, return silently on failure
315
  // Go through our columns, try to pick out data, return silently on failure
310
  for ( QPtrListIterator <ArchColumns>col( m_archCols ); col.current(); ++col )
316
  for ( QPtrListIterator <ArchColumns>col( m_archCols ); col.current(); ++col )
311
  {
317
  {
312
    ArchColumns *curCol = *col;
318
    ArchColumns *curCol = *col;
313
319
314
    strpos = curCol->pattern.search( line, pos );
320
    strpos = curCol->pattern.search( unicode_line, pos );
315
    len = curCol->pattern.matchedLength();
321
    len = curCol->pattern.matchedLength();
316
322
317
    if ( ( strpos == -1 ) || ( len > curCol->maxLength ) )
323
    if ( ( strpos == -1 ) || ( len > curCol->maxLength ) )
Lines 327-333 Link Here
327
333
328
    pos = strpos + len;
334
    pos = strpos + len;
329
335
330
    columns[ curCol->colRef ] = line.mid( strpos, len );
336
    columns[ curCol->colRef ] = unicode_line.mid( strpos, len );
331
  }
337
  }
332
338
333
339
(-)kdeutils-3.5.7-original/ark/arkwidget.cpp (-1 / +1 lines)
Lines 1526-1532 Link Here
1526
                      it != selectedFiles.constEnd();
1526
                      it != selectedFiles.constEnd();
1527
                      ++it )
1527
                      ++it )
1528
                {
1528
                {
1529
                    m_extractList->append( QFile::encodeName( *it ) );
1529
                    m_extractList->append( *it );
1530
                }
1530
                }
1531
1531
1532
                if (!bOvwrt)
1532
                if (!bOvwrt)
(-)kdeutils-3.5.7-original/ark/rar.cpp (-5 / +13 lines)
Lines 32-37 Link Here
32
// QT includes
32
// QT includes
33
#include <qfile.h>
33
#include <qfile.h>
34
#include <qdir.h>
34
#include <qdir.h>
35
#include <qtextcodec.h>
35
36
36
// KDE includes
37
// KDE includes
37
#include <kdebug.h>
38
#include <kdebug.h>
Lines 80-88 Link Here
80
81
81
bool RarArch::processLine( const QCString &line )
82
bool RarArch::processLine( const QCString &line )
82
{
83
{
84
  QString unicode_line;
85
86
  QTextCodec *codec = QTextCodec::codecForLocale();
87
  unicode_line = codec->toUnicode( line );
88
  
83
  if ( m_isFirstLine )
89
  if ( m_isFirstLine )
84
  {
90
  {
85
    m_entryFilename = line;
91
    m_entryFilename = unicode_line;
86
    m_entryFilename.remove( 0, 1 );
92
    m_entryFilename.remove( 0, 1 );
87
    m_isFirstLine = false;
93
    m_isFirstLine = false;
88
    return true;
94
    return true;
Lines 90-96 Link Here
90
96
91
  QStringList list;
97
  QStringList list;
92
98
93
  QStringList l2 = QStringList::split( ' ', line );
99
  QStringList l2 = QStringList::split( ' ', unicode_line );
94
100
95
  list << m_entryFilename; // filename
101
  list << m_entryFilename; // filename
96
  list << l2[ 0 ]; // size
102
  list << l2[ 0 ]; // size
Lines 235-242 Link Here
235
  {
241
  {
236
    *kp << "-o-";
242
    *kp << "-o-";
237
  }
243
  }
244
  
245
  QTextCodec *codec = QTextCodec::codecForLocale();
238
246
239
  *kp << m_filename;
247
  *kp << codec->fromUnicode(m_filename);
240
248
241
  // if the file list is empty, no filenames go on the command line,
249
  // if the file list is empty, no filenames go on the command line,
242
  // and we then extract everything in the archive.
250
  // and we then extract everything in the archive.
Lines 245-255 Link Here
245
    QStringList::Iterator it;
253
    QStringList::Iterator it;
246
    for ( it = m_fileList->begin(); it != m_fileList->end(); ++it )
254
    for ( it = m_fileList->begin(); it != m_fileList->end(); ++it )
247
    {
255
    {
248
      *kp << (*it);
256
      *kp << codec->fromUnicode(*it);
249
    }
257
    }
250
  }
258
  }
251
259
252
  *kp << m_destDir ;
260
  *kp << codec->fromUnicode(m_destDir);
253
261
254
  connect( kp, SIGNAL( receivedStdout(KProcess*, char*, int) ),
262
  connect( kp, SIGNAL( receivedStdout(KProcess*, char*, int) ),
255
           SLOT( slotReceivedOutput(KProcess*, char*, int) ) );
263
           SLOT( slotReceivedOutput(KProcess*, char*, int) ) );
(-)kdeutils-3.5.7-original/ark/zip.cpp (-3 / +7 lines)
Lines 28-33 Link Here
28
28
29
// Qt includes
29
// Qt includes
30
#include <qdir.h>
30
#include <qdir.h>
31
#include <qtextcodec.h>
31
32
32
// KDE includes
33
// KDE includes
33
#include <kdebug.h>
34
#include <kdebug.h>
Lines 207-214 Link Here
207
    *kp << "-o";
208
    *kp << "-o";
208
  else
209
  else
209
    *kp << "-n";
210
    *kp << "-n";
211
  
212
  QTextCodec *codec = QTextCodec::codecForLocale();
210
213
211
  *kp << m_filename;
214
  *kp << codec->fromUnicode(m_filename);
212
215
213
  // if the list is empty, no filenames go on the command line,
216
  // if the list is empty, no filenames go on the command line,
214
  // and we then extract everything in the archive.
217
  // and we then extract everything in the archive.
Lines 218-228 Link Here
218
221
219
    for ( it = m_fileList->begin(); it != m_fileList->end(); ++it )
222
    for ( it = m_fileList->begin(); it != m_fileList->end(); ++it )
220
    {
223
    {
221
      *kp << (*it);
224
      *kp << codec->fromUnicode(*it);
222
    }
225
    }
223
  }
226
  }
224
227
225
  *kp << "-d" << m_destDir;
228
  *kp << "-d";
229
  *kp << codec->fromUnicode(m_destDir);
226
230
227
  connect( kp, SIGNAL( receivedStdout(KProcess*, char*, int) ),
231
  connect( kp, SIGNAL( receivedStdout(KProcess*, char*, int) ),
228
           SLOT( slotReceivedOutput(KProcess*, char*, int) ) );
232
           SLOT( slotReceivedOutput(KProcess*, char*, int) ) );

Return to bug 12418