Revision: 1143
Author: lstreepy
Date: 2006-05-11 07:46:41 -0700 (Thu, 11 May 2006)
ViewCVS: http://svn.sourceforge.net/spring-rich-c/?rev=1143&view=rev
Log Message:
-----------
Move LabeledEnumResolver to be obtained on demand instead of during class
construction
to avoid an NPE.
Modified Paths:
--------------
trunk/spring-richclient/support/src/main/java/org/springframework/richclient/factory/DefaultComponentFactory.java
Modified:
trunk/spring-richclient/support/src/main/java/org/springframework/richclient/factory/DefaultComponentFactory.java
===================================================================
---
trunk/spring-richclient/support/src/main/java/org/springframework/richclient/factory/DefaultComponentFactory.java
2006-05-11 10:02:55 UTC (rev 1142)
+++
trunk/spring-richclient/support/src/main/java/org/springframework/richclient/factory/DefaultComponentFactory.java
2006-05-11 14:46:41 UTC (rev 1143)
@@ -81,7 +81,7 @@
private MenuFactory menuFactory;
- private LabeledEnumResolver enumResolver =
(LabeledEnumResolver)ApplicationServicesLocator.services().getService(LabeledEnumResolver.class);
+ private LabeledEnumResolver enumResolver;
private MessageSource messageSource;
@@ -108,6 +108,13 @@
this.enumResolver = enumResolver;
}
+ protected LabeledEnumResolver getEnumResolver() {
+ if (enumResolver == null) {
+ enumResolver =
(LabeledEnumResolver)ApplicationServicesLocator.services().getService(LabeledEnumResolver.class);
+ }
+ return enumResolver;
+ }
+
public JLabel createLabel(String labelKey) {
return
getLabelInfo(getRequiredMessage(labelKey)).configureLabel(createNewLabel());
}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
spring-rich-c-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/spring-rich-c-cvs