directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r1430366 - /directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java
Date Tue, 08 Jan 2013 16:30:32 GMT
Author: pamarcelot
Date: Tue Jan  8 16:30:32 2013
New Revision: 1430366

URL: http://svn.apache.org/viewvc?rev=1430366&view=rev
Log:
Added a specific bypass for the "0" value.

Modified:
    directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java

Modified: directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java?rev=1430366&r1=1430365&r2=1430366&view=diff
==============================================================================
--- directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java
(original)
+++ directory/studio/trunk/plugins/valueeditors/src/main/java/org/apache/directory/studio/valueeditors/adtime/ActiveDirectoryTimeValueEditor.java
Tue Jan  8 16:30:32 2013
@@ -61,6 +61,13 @@ public class ActiveDirectoryTimeValueEdi
 
         if ( !showRawValues() )
         {
+            // Special case for the "0" value where we don't want to display date 
+            // that makes no sense ("0" being the default value, it happened a lot).
+            if ( "0".equals( displayValue ) )
+            {
+                return displayValue;
+            }
+
             DateFormat targetFormat = DateFormat.getDateTimeInstance( DateFormat.MEDIUM,
DateFormat.LONG );
 
             try



Mime
View raw message