[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-i18n-doc
Subject:    branches/KDE/3.5/kdebase/kioslave/mac
From:       Nicolas Goutte <nicolasg () snafu ! de>
Date:       2005-09-17 21:30:22
Message-ID: 1126992622.939567.31883.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 461528 by goutte:

Improve error message:
- errors declared as internal need to be translated too
  (I18N: untranslatable strings)
- most errors should be declared as ERR_SLAVE_DEFINED to avoid stupid
  phrase constructions.
CCMAIL:kde-i18n-doc@kde.org


 M  +10 -12    kio_mac.cpp  


--- branches/KDE/3.5/kdebase/kioslave/mac/kio_mac.cpp #461527:461528
@@ -91,7 +91,7 @@
     if (modepos != -1) {
         mode += query.mid(modepos + 5, 1);
         if (mode != "-r" && mode != "-b" && mode != "-m" && mode != "-t" && mode != \
                "-a") {
-            error(ERR_MALFORMED_URL, i18n("Unknown mode"));
+            error(ERR_SLAVE_DEFINED, i18n("Unknown mode"));
         }
     } else if (textpos != -1) {
         mode += "t";
@@ -111,7 +111,7 @@
     myKProcess->start(KProcess::Block, KProcess::All);
 
     if (!myKProcess->normalExit() || !(myKProcess->exitStatus() == 0)) {
-        error(ERR_CANNOT_LAUNCH_PROCESS,
+        error(ERR_SLAVE_DEFINED,
               i18n("There was an error with hpcopy - please ensure it is \
installed"));  return;
     }
@@ -140,7 +140,7 @@
         myKProcess->start(KProcess::Block, KProcess::All);
 
         if ((!myKProcess->normalExit()) || (!myKProcess->exitStatus() == 0)) {
-            error(ERR_CANNOT_LAUNCH_PROCESS,
+            error(ERR_SLAVE_DEFINED,
                   i18n("There was an error with hpls - please ensure it is \
installed"));  }
 
@@ -184,7 +184,7 @@
     QString filename = prepareHP(url);
 
     if (filename.isNull()) {
-        error(ERR_DOES_NOT_EXIST, i18n("No filename was found in the URL"));
+        error(ERR_SLAVE_DEFINED, i18n("No filename was found in the URL"));
     } else if (! filename.isEmpty()) {
         myKProcess = new KShellProcess();
 
@@ -197,7 +197,7 @@
         myKProcess->start(KProcess::Block, KProcess::All);
 
         if ((!myKProcess->normalExit()) || (!myKProcess->exitStatus() == 0)) {
-            error(ERR_CANNOT_LAUNCH_PROCESS,
+            error(ERR_SLAVE_DEFINED,
                   i18n("hpls did not exit normally - please ensure you have \
installed the hfsplus tools"));  }
 
@@ -284,7 +284,7 @@
 
     if ((!myKProcess->normalExit()) || (!myKProcess->exitStatus() == 0)) {
         //TODO this error interrupts the user when typing ?dev=foo on each letter of \
                foo
-        error(ERR_CANNOT_LAUNCH_PROCESS,
+        error(ERR_SLAVE_DEFINED,
               i18n("hpmount did not exit normally - please ensure that hfsplus utils \
                are installed,\n"
                    "that you have permission to read the partition (ls -l \
/dev/hdaX)\n"  "and that you have specified the correct partition.\n"
@@ -316,7 +316,7 @@
         myKProcess->start(KProcess::Block, KProcess::All);
 
         if ((!myKProcess->normalExit()) || (!myKProcess->exitStatus() == 0)) {
-            error(ERR_CANNOT_LAUNCH_PROCESS,
+            error(ERR_SLAVE_DEFINED,
                   i18n("hpcd did not exit normally - please ensure it is \
installed"));  return NULL;
         }
@@ -404,7 +404,7 @@
             entry.append(atom);
         }
     } else {
-        error(ERR_INTERNAL, "hpls output was not matched");
+        error(ERR_INTERNAL, i18n("hpls output was not matched"));
     } //if match dirRE or fileRE
 
     return entry;
@@ -447,8 +447,7 @@
     else if (mon == "Nov") { month = 11; }
     else if (mon == "Dec") { month = 12; }
     else {
-        error(ERR_CANNOT_LAUNCH_PROCESS,
-              "Month output from hpls -l not matched, e-mail jr@jriddell.org");
+        error(ERR_INTERNAL, i18n("Month output from hpls -l not matched"));
         month = 13;
     }
 
@@ -477,8 +476,7 @@
 
     //check it's valid
     if ( (!QDate::isValid(year, month, day)) || (!QTime::isValid(hour, minute, 0) ) \
                ) {
-        error(ERR_CANNOT_LAUNCH_PROCESS,
-              "Could not parse a valid date from hpls, e-mail jr@jriddell.org");
+        error(ERR_INTERNAL, i18n("Could not parse a valid date from hpls"));
     }
 
     //put it together and work it out


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic