summaryrefslogtreecommitdiffabout
path: root/korganizer
Unidiff
Diffstat (limited to 'korganizer') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koprefs.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp
index 13035e0..2cfb382 100644
--- a/korganizer/koprefs.cpp
+++ b/korganizer/koprefs.cpp
@@ -400,28 +400,30 @@ void KOPrefs::usrReadConfig()
400 mLocaleDict = new QDict<QString>; 400 mLocaleDict = new QDict<QString>;
401 int i = 0; 401 int i = 0;
402 QString fw ( germanwords[i] [0]); 402 QString fw ( germanwords[i] [0]);
403 while ( !fw.isEmpty() ) { 403 while ( !fw.isEmpty() ) {
404 mLocaleDict->insert( fw, new QString (germanwords[i] [1] )); 404 mLocaleDict->insert( fw, new QString (germanwords[i] [1] ));
405 ++i; 405 ++i;
406 fw = germanwords[i] [0]; 406 fw = germanwords[i] [0];
407 } 407 }
408 408
409 setLocaleDict( mLocaleDict ); 409 setLocaleDict( mLocaleDict );
410 } else { 410 } else {
411 QString fileName ; 411 QString fileName ;
412 if ( mPreferredLanguage == 3 ) 412 if ( mPreferredLanguage == 4 )
413 fileName = MainWindow::resourcePath()+"usertranslation.txt"; 413 fileName = MainWindow::resourcePath()+"usertranslation.txt";
414 else if ( mPreferredLanguage == 2 ) 414 else if ( mPreferredLanguage == 2 )
415 fileName = MainWindow::resourcePath()+"frenchtranslation.txt"; 415 fileName = MainWindow::resourcePath()+"frenchtranslation.txt";
416 else if ( mPreferredLanguage == 3 )
417 fileName = MainWindow::resourcePath()+"italiantranslation.txt";
416 QFile file( fileName ); 418 QFile file( fileName );
417 if (file.open( IO_ReadOnly ) ) { 419 if (file.open( IO_ReadOnly ) ) {
418 QTextStream ts( &file ); 420 QTextStream ts( &file );
419 ts.setEncoding( QTextStream::Latin1 ); 421 ts.setEncoding( QTextStream::Latin1 );
420 //ts.setCodec( QTextCodec::latin1 ); 422 //ts.setCodec( QTextCodec::latin1 );
421 QString text = ts.read(); 423 QString text = ts.read();
422 file.close(); 424 file.close();
423 text.replace( QRegExp("\\\\n"), "\n" ); 425 text.replace( QRegExp("\\\\n"), "\n" );
424 QString line; 426 QString line;
425 QString we; 427 QString we;
426 QString wt; 428 QString wt;
427 int br = 0; 429 int br = 0;