2005-05-24 Gary Benson <gbenson@redhat.com>
PR libgcj/21736:
* java/text/MessageFormat.java (MessageFormatElement.setLocale):
Handle DateFormat.DEFAULT case correctly.
From-SVN: r100154
+2005-05-24 Gary Benson <gbenson@redhat.com>
+
+ PR libgcj/21736:
+ * java/text/MessageFormat.java (MessageFormatElement.setLocale):
+ Handle DateFormat.DEFAULT case correctly.
+
2005-05-21 Tom Tromey <tromey@redhat.com>
PR libgcj/21703:
formatClass = java.util.Date.class;
int val = DateFormat.DEFAULT;
+ boolean styleIsPattern = false;
if (style == null)
;
else if (style.equals("short"))
val = DateFormat.LONG;
else if (style.equals("full"))
val = DateFormat.FULL;
+ else
+ styleIsPattern = true;
if (type.equals("time"))
format = DateFormat.getTimeInstance(val, loc);
else
format = DateFormat.getDateInstance(val, loc);
- if (style != null && val == DateFormat.DEFAULT)
+ if (styleIsPattern)
{
SimpleDateFormat sdf = (SimpleDateFormat) format;
sdf.applyPattern(style);