[Arakhnę-Dev] [332] * Fixing the Locale API according the the bug fixes in the Caller API . |
[ Thread Index |
Date Index
| More arakhne.org/dev Archives
]
Revision: 332
Author: galland
Date: 2012-02-07 18:40:58 +0100 (Tue, 07 Feb 2012)
Log Message:
-----------
* Fixing the Locale API according the the bug fixes in the Caller API.
Modified Paths:
--------------
trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/locale/Locale.java
Modified: trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/locale/Locale.java
===================================================================
--- trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/locale/Locale.java 2012-02-07 10:48:54 UTC (rev 331)
+++ trunk/arakhneVmutils/java/src/main/java/org/arakhne/vmutil/locale/Locale.java 2012-02-07 17:40:58 UTC (rev 332)
@@ -225,6 +225,9 @@
Class<?> res = detectResourceClass(resource);
if (res==null) return key;
String val = getStringWithDefaultFrom(classLoader,res.getCanonicalName(),key,null,params);
+ if (val==null && classLoader!=resource.getClassLoader()) {
+ val = getStringWithDefaultFrom(classLoader,res.getCanonicalName(),key,null,params);
+ }
while ((res!=null)&&(val==null)) {
res = res.getSuperclass();
if (res!=null) {
@@ -265,6 +268,9 @@
Class<?> res = detectResourceClass(resource);
if (res==null) return defaultValue;
String val = getStringWithDefaultFrom(classLoader,res.getCanonicalName(),key,null,params);
+ if (val==null && classLoader!=resource.getClassLoader()) {
+ val = getStringWithDefaultFrom(classLoader,res.getCanonicalName(),key,null,params);
+ }
while ((res!=null)&&(val==null)) {
res = res.getSuperclass();
if (res!=null) {