1999-08-20 03:01:34 +04:00
|
|
|
var strBundleService = null;
|
|
|
|
|
2001-04-28 01:30:24 +04:00
|
|
|
function srGetStrBundle(path)
|
1999-08-20 03:01:34 +04:00
|
|
|
{
|
|
|
|
var strBundle = null;
|
|
|
|
|
|
|
|
if (!strBundleService) {
|
2000-04-24 12:04:06 +04:00
|
|
|
try {
|
|
|
|
strBundleService =
|
2000-09-14 03:57:52 +04:00
|
|
|
Components.classes["@mozilla.org/intl/stringbundle;1"].getService();
|
2000-04-24 12:04:06 +04:00
|
|
|
strBundleService =
|
|
|
|
strBundleService.QueryInterface(Components.interfaces.nsIStringBundleService);
|
|
|
|
} catch (ex) {
|
|
|
|
dump("\n--** strBundleService failed: " + ex + "\n");
|
|
|
|
return null;
|
|
|
|
}
|
1999-08-20 03:01:34 +04:00
|
|
|
}
|
|
|
|
|
2001-04-28 01:30:24 +04:00
|
|
|
strBundle = strBundleService.createBundle(path);
|
1999-08-20 03:01:34 +04:00
|
|
|
if (!strBundle) {
|
|
|
|
dump("\n--** strBundle createInstance failed **--\n");
|
|
|
|
}
|
|
|
|
return strBundle;
|
|
|
|
}
|