[Webfunds-commits] java/webfunds/client ReceiptBrowser.java

Ian Grigg iang@cypherpunks.ai
Sun, 4 Jun 2000 20:56:58 -0400 (AST)


iang        00/06/04 20:56:58

  Modified:    webfunds/client ReceiptBrowser.java
  Log:
  just swapped buttons over to constants so I could be sure that's what was used

Revision  Changes    Path
1.17      +17 -6     java/webfunds/client/ReceiptBrowser.java

Index: ReceiptBrowser.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/client/ReceiptBrowser.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- ReceiptBrowser.java	2000/05/27 00:12:21	1.16
+++ ReceiptBrowser.java	2000/06/05 00:56:58	1.17
@@ -1,5 +1,5 @@
 /*
- * $Id: ReceiptBrowser.java,v 1.16 2000/05/27 00:12:21 iang Exp $
+ * $Id: ReceiptBrowser.java,v 1.17 2000/06/05 00:56:58 iang Exp $
  *
  * Copyright (c) Systemics Ltd 1995-1999 on behalf of
  * the WebFunds Development Team.  All Rights Reserved.
@@ -55,7 +55,7 @@
         header.setResizingAllowed(true);
 
         JPanel butpanel     = new JPanel();
-        JButton butclose    = new JButton("Close");
+        JButton butclose    = new JButton(CLOSE);
         butclose.setMnemonic('c');
         butclose.setDefaultCapable(true);
         butclose.addActionListener(new ActionListener()
@@ -115,10 +115,21 @@
         initActions();
         this.show();
     }
+
+    /**
+     * Button Labels.
+     */
+    public static final String CLOSE     = "Close",
+                               REFRESH   = "Refresh",
+                               CANCEL    = "Cancel Payment",
+                               SHOWALL   = "Show All",
+                               CANCELALL = "Cancel All",
+                               CHANGE    = "Change";
+
     
     private void initActions()
     {
-        Action cancelpayment = new AbstractAction("Cancel Payment")
+        Action cancelpayment = new AbstractAction(CANCEL)
         {
             public void actionPerformed(ActionEvent evt)
             {
@@ -128,7 +139,7 @@
         toolbar.add(cancelpayment);
         popup.add(cancelpayment);
 
-        Action showCancels = new AbstractAction("Show All")
+        Action showCancels = new AbstractAction(SHOWALL)
         {
             public void actionPerformed(ActionEvent evt)
             {
@@ -137,7 +148,7 @@
         };
         toolbar.add(showCancels);
 
-        Action refresh = new AbstractAction("Refresh")
+        Action refresh = new AbstractAction(REFRESH)
         {
             public void actionPerformed(ActionEvent evt)
             {
@@ -146,7 +157,7 @@
         };
         toolbar.add(refresh);
 
-        Action cancelall = new AbstractAction("Cancel All")
+        Action cancelall = new AbstractAction(CANCELALL)
         {
             public void actionPerformed(ActionEvent evt)
             {