Fix access to system catalog strings.

* fix regression introduced in hrev43950:
  HashMapCatalog::GetString() didn't return the non-translated
  string in case there was no translation found, which e.g.
  caused AboutWindows to trigger a debugger message about the
  alert not having any buttons.
Thanks to diver for the hint.
This commit is contained in:
Oliver Tappe 2012-04-06 13:54:50 +02:00
parent 3cee15aac2
commit 6d2186615f

View File

@ -124,7 +124,10 @@ BHashMapCatalog::GetString(const char *string, const char *context,
const char *comment)
{
CatKey key(string, context, comment);
return GetString(key);
BString value = fCatMap.Get(key);
if (value.Length() != 0)
return value.String();
return string;
}