Revision: 1318
Author:   mathiasbr
Date:     2006-08-19 15:56:58 -0700 (Sat, 19 Aug 2006)
ViewCVS:  http://svn.sourceforge.net/spring-rich-c/?rev=1318&view=rev

Log Message:
-----------
field face now supports configuring buttons - needed to configure JCheckBox and 
JToggleButton fields

Modified Paths:
--------------
    
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/FieldFace.java
    
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/support/DefaultFieldFace.java
Modified: 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/FieldFace.java
===================================================================
--- 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/FieldFace.java
       2006-08-19 22:52:47 UTC (rev 1317)
+++ 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/FieldFace.java
       2006-08-19 22:56:58 UTC (rev 1318)
@@ -15,6 +15,7 @@
  */
 package org.springframework.binding.form;
 
+import javax.swing.AbstractButton;
 import javax.swing.Icon;
 import javax.swing.JLabel;
 
@@ -59,4 +60,9 @@
      * Configures the supplied JLabel using LabelInfo and Icon.
      */
     void configure(JLabel label);
+
+    /**
+     * Configures the supplied button using LabelInfo and Icon.
+     */
+    void configure(AbstractButton button);
 }
\ No newline at end of file

Modified: 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/support/DefaultFieldFace.java
===================================================================
--- 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/support/DefaultFieldFace.java
        2006-08-19 22:52:47 UTC (rev 1317)
+++ 
trunk/spring-richclient/support/src/main/java/org/springframework/binding/form/support/DefaultFieldFace.java
        2006-08-19 22:56:58 UTC (rev 1318)
@@ -17,6 +17,7 @@
 
 import java.awt.Image;
 
+import javax.swing.AbstractButton;
 import javax.swing.Icon;
 import javax.swing.ImageIcon;
 import javax.swing.JLabel;
@@ -89,4 +90,10 @@
         labelInfo.configureLabel(label);
         label.setIcon(icon);
     }
+
+    public void configure(AbstractButton button) {
+        Assert.notNull(button, "The AbstractButton to configure is required");
+        labelInfo.configureButton(button);
+        button.setIcon(icon);
+    }
 }
\ No newline at end of file


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

Reply via email to