be more precise on importresult overall error

This commit is contained in:
Vincent Breitmoser 2014-09-23 16:23:13 +02:00
parent da1779816b
commit c5239d6e9b
2 changed files with 7 additions and 4 deletions

View File

@ -165,7 +165,7 @@ public class ImportKeyResult extends OperationResult {
? R.string.import_error_nothing_cancelled
: R.string.import_error_nothing);
} else {
str = activity.getString(R.string.import_error);
str = activity.getResources().getQuantityString(R.plurals.import_error, mBadKeys);
}
}

View File

@ -395,15 +395,18 @@
<item quantity="other">"Successfully updated %1$d keys%2$s."</item>
</plurals>
<plurals name="import_keys_with_errors">
<item quantity="one">"Import failed for one key."</item>
<item quantity="other">"Import failed for %d keys."</item>
<item quantity="one">"Import failed for one key!"</item>
<item quantity="other">"Import failed for %d keys!"</item>
</plurals>
<string name="view_log">"View Log"</string>
<string name="import_error_nothing">"Nothing to import."</string>
<string name="import_error_nothing_cancelled">"Import cancelled."</string>
<string name="import_error">"Error importing keys!"</string>
<string name="import_with_warnings">", with warnings"</string>
<string name="import_with_cancelled">", until cancelled"</string>
<plurals name="import_error">
<item quantity="one">"Import failed!"</item>
<item quantity="other">"Import of %d keys failed!"</item>
</plurals>
<!-- Intent labels -->
<string name="intent_decrypt_file">"Decrypt File with OpenKeychain"</string>