2
0
Эх сурвалжийг харах

2006-05-24 Sebastien Pouliot <[email protected]>

	* ImageFormat.cs: Fixed ToString method to match MS output.


svn path=/trunk/mcs/; revision=61080
Sebastien Pouliot 19 жил өмнө
parent
commit
1c06dcfcc1

+ 4 - 0
mcs/class/System.Drawing/System.Drawing.Imaging/ChangeLog

@@ -1,3 +1,7 @@
+2006-05-24  Sebastien Pouliot  <[email protected]>
+
+	* ImageFormat.cs: Fixed ToString method to match MS output.
+
 2006-05-21  Sebastien Pouliot  <[email protected]>
 
 	* ColorAdjustType.cs: Removed [Serializable] from 2.0 profile.

+ 2 - 39
mcs/class/System.Drawing/System.Drawing.Imaging/ImageFormat.cs

@@ -8,10 +8,7 @@
 //   Jordi Mas i Hernandez ([email protected])
 //
 // (C) 2002-4 Ximian, Inc.  http://www.ximian.com
-//
-
-//
-// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2004,2006 Novell, Inc (http://www.novell.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -33,7 +30,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-using System;
 using System.ComponentModel;
 
 namespace System.Drawing.Imaging {
@@ -80,40 +76,7 @@ namespace System.Drawing.Imaging {
 		
 		public override string ToString() 
 		{			
-			if (this.Equals (Bmp))
-				return "Bmp";			
-				
-			if (this.Equals (Emf))
-				return "Emf";			
-				
-			if (this.Equals (Exif))
-				return "Exif";			
-				
-			if (this.Equals (Gif))
-				return "Gif";			
-				
-			if (this.Equals (Tiff))
-				return "Tiff";			
-				
-			if (this.Equals (Png))
-				return "Png";			
-				
-			if (this.Equals (MemoryBmp))
-				return "MemoryBmp";			
-				
-			if (this.Equals (Icon))
-				return "Icon";			
-				
-			if (this.Equals (Jpeg))
-				return "Jpeg";							
-				
-			if (this.Equals (Wmf))
-				return "Wmf";												
-			
-			// Default			
-			return ("[ImageFormat: " + Guid.ToString () + "]");
-
-
+			return ("[ImageFormat: " + guid.ToString () + "]");
 		}
 
 		// properties