CVSROOT: /cvsroot/classpath Module name: classpath Branch: Changes by: Anthony Balkissoon <[EMAIL PROTECTED]> 05/11/30 23:02:37
Modified files: . : ChangeLog javax/swing : JFormattedTextField.java javax/swing/text: DefaultFormatter.java Log message: 2005-11-30 Anthony Balkissoon <[EMAIL PROTECTED]> * javax/swing/JFormattedTextField.java: (AbstractFormatter.install): Try to set the text of the formatted text field using this formatter. (FormatterFactoryWrapper): Removed this unneeded class, this is handled by DefaultFormatterFactory now. (formatter): New field. (JFormattedTextField(Format)): Implemented. (JFormattedTextField(AbstractFormatter)): Instantiate a DefaultFormatterFactory instead of a FormatterFactoryWrapper. (JFormattedTextField(AbstractFormatterFactory, Object)): Call setValue and setFormatterFactory instead of setting variables directly because more needs to be done than just setting the value of the variables. (JFormattedTextField(Object value)): Call setValue instead of setting the variable directly. (getAppropriateFormatterFactory): New implementation method. (getFormatter): Don't use the formatter factory here, just return the cached formatter. (processFocusEvent): Set the formatter to the appropriate one as determined by the formatter factory. (setFormatter): Don't get the old formatter from the factory, just use the cached formatter. Uninstall the old formatter. Install the new formatter. Cache the new formatter. Don't create a new formatter factory. (setFormatterFactory): Set the formatter according to the new formatter factory. (setValue): Moved the setting of the value variable to above the call to createFormatter so that an appropriate formatter is created. Cache the formatter that is created. (createFormatter): If argument is a Number, use a NumberFormatter. * javax/swing/text/DefaultFormatter.java: (valueToString): If argument is null return empty String. CVSWeb URLs: http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.5755&tr2=1.5756&r1=text&r2=text http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/JFormattedTextField.java.diff?tr1=1.17&tr2=1.18&r1=text&r2=text http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/text/DefaultFormatter.java.diff?tr1=1.5&tr2=1.6&r1=text&r2=text