You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by od...@apache.org on 2010/04/21 13:59:16 UTC
svn commit: r936272 -
/harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java
Author: odeakin
Date: Wed Apr 21 11:59:15 2010
New Revision: 936272
URL: http://svn.apache.org/viewvc?rev=936272&view=rev
Log:
Fix minor spelling mistake and add check for the case where nothing is entered for class name.
Modified:
harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java
Modified: harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java?rev=936272&r1=936271&r2=936272&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java (original)
+++ harmony/enhanced/java/trunk/jdktools/modules/jdktools/src/main/java/org/apache/harmony/tools/serialver/ShowGui.java Wed Apr 21 11:59:15 2010
@@ -67,6 +67,13 @@ public class ShowGui extends JFrame {
public void actionPerfomed(ActionEvent evt) {
String targetClass = classNameField.getText();
+ if (targetClass.length() == 0) {
+ // No string was entered
+ statusBarLabel.setText("");
+ serialVersionField.setText("");
+ return;
+ }
+
// Load the class.
try {
Clazz clazz = new Clazz(classProvider, targetClass);
@@ -84,7 +91,7 @@ public class ShowGui extends JFrame {
}
} catch (ClassNotFoundException e) { // Class Not Found
serialVersionField.setText("");
- statusBarLabel.setText("Class " + targetClass + " not fond.");
+ statusBarLabel.setText("Class " + targetClass + " not found.");
}
}
}