Fix a bunch of messages
* Find and rename/remove duplicate string variable names
* Add missing string variables to en language file
* Fix display of some strings missing @ in front of variable name
* Fix several %s --> {1}
* Be consistent in usage of cancelled vs. canceled (both spellings
acceptable)
Tip for finding strings missing from language files:
1) Find all messages:
egrep -hr "gui_msg.+=" > /tmp/msgs.txt
2) Regex replace to trim them down
WHAT: ^\s+gui_msg(?:[^"]+)"([a-zA-Z0-9_]+)=([^"]+).+
WITH: $1
Note that $2 can be used to retain the message
3) Find missing strings:
for i in $(cat /tmp/msgs.txt); do
if ! grep -q $i gui/theme/common/languages/en.xml; then
echo $i;
fi
done
Change-Id: Ic193162e4b5468bf027472928a370be39840ea1d
diff --git a/gui/action.cpp b/gui/action.cpp
index 1b30a20..fe20910 100644
--- a/gui/action.cpp
+++ b/gui/action.cpp
@@ -347,7 +347,7 @@
{
if (PartitionManager.stop_backup.get_value()) {
DataManager::SetValue("tw_cancel_backup", 1);
- gui_msg("backup_cancel=Backup Canceled.");
+ gui_msg("backup_cancel=Backup Cancelled");
DataManager::SetValue("ui_progress", 0);
PartitionManager.stop_backup.set_value(0);
return;
@@ -1197,7 +1197,7 @@
}
else {
DataManager::SetValue("tw_cancel_backup", 1);
- gui_msg("backup_cancel=Backup Canceled.");
+ gui_msg("backup_cancel=Backup Cancelled");
ret = 0;
}
operation_end(ret);