Author: toshok
Date: 2008-01-11 22:31:44 -0500 (Fri, 11 Jan 2008)
New Revision: 92717
Modified:
trunk/olive/class/WindowsBase/System.Windows.Media/Matrix.cs
trunk/olive/class/WindowsBase/System.Windows/Int32Rect.cs
trunk/olive/class/WindowsBase/System.Windows/Point.cs
trunk/olive/class/WindowsBase/System.Windows/Size.cs
trunk/olive/class/WindowsBase/System.Windows/Vector.cs
Log:
wrap the operators in 'if NET_3_5'
Modified: trunk/olive/class/WindowsBase/System.Windows/Int32Rect.cs
===================================================================
--- trunk/olive/class/WindowsBase/System.Windows/Int32Rect.cs 2008-01-12
02:56:54 UTC (rev 92716)
+++ trunk/olive/class/WindowsBase/System.Windows/Int32Rect.cs 2008-01-12
03:31:44 UTC (rev 92717)
@@ -48,6 +48,7 @@
this.height = height;
}
+#if NET_3_5
public static bool operator != (Int32Rect int32Rect1, Int32Rect
int32Rect2)
{
throw new NotImplementedException ();
@@ -57,6 +58,7 @@
{
throw new NotImplementedException ();
}
+#endif
public static Int32Rect Empty {
get { return new Int32Rect (0, 0, 0, 0); }
Modified: trunk/olive/class/WindowsBase/System.Windows/Point.cs
===================================================================
--- trunk/olive/class/WindowsBase/System.Windows/Point.cs 2008-01-12
02:56:54 UTC (rev 92716)
+++ trunk/olive/class/WindowsBase/System.Windows/Point.cs 2008-01-12
03:31:44 UTC (rev 92717)
@@ -103,6 +103,8 @@
}
/* operators */
+
+#if NET_3_5
public static Vector operator -(Point point1, Point point2)
{
return Subtract (point1, point2);
@@ -113,9 +115,9 @@
return Subtract (point, vector);
}
- public static bool operator != (Point point1, Point point2)
+ public static Point operator + (Point point, Vector vector)
{
- return !point1.Equals(point2);
+ return Add (point, vector);
}
public static Point operator * (Point point, Matrix matrix)
@@ -123,9 +125,9 @@
return Multiply (point, matrix);
}
- public static Point operator + (Point point, Vector vector)
+ public static bool operator != (Point point1, Point point2)
{
- return Add (point, vector);
+ return !point1.Equals(point2);
}
public static bool operator == (Point point1, Point point2)
@@ -142,6 +144,7 @@
{
return new Vector (point.X, point.Y);
}
+#endif
public static Point Parse (string source)
{
Modified: trunk/olive/class/WindowsBase/System.Windows/Size.cs
===================================================================
--- trunk/olive/class/WindowsBase/System.Windows/Size.cs 2008-01-12
02:56:54 UTC (rev 92716)
+++ trunk/olive/class/WindowsBase/System.Windows/Size.cs 2008-01-12
03:31:44 UTC (rev 92717)
@@ -130,6 +130,7 @@
}
/* operators */
+#if NET_3_5
public static explicit operator Point (Size size)
{
return new Point (size.Width, size.Height);
@@ -149,6 +150,7 @@
{
return !size1.Equals (size2);
}
+#endif
double width;
double height;
Modified: trunk/olive/class/WindowsBase/System.Windows/Vector.cs
===================================================================
--- trunk/olive/class/WindowsBase/System.Windows/Vector.cs 2008-01-12
02:56:54 UTC (rev 92716)
+++ trunk/olive/class/WindowsBase/System.Windows/Vector.cs 2008-01-12
03:31:44 UTC (rev 92717)
@@ -180,6 +180,7 @@
set { y = value; }
}
+#if NET_3_5
/* operators */
public static explicit operator Point (Vector vector)
{
@@ -247,6 +248,7 @@
{
return Add (vector1, vector2);
}
+#endif
double x;
double y;
Modified: trunk/olive/class/WindowsBase/System.Windows.Media/Matrix.cs
===================================================================
--- trunk/olive/class/WindowsBase/System.Windows.Media/Matrix.cs
2008-01-12 02:56:54 UTC (rev 92716)
+++ trunk/olive/class/WindowsBase/System.Windows.Media/Matrix.cs
2008-01-12 03:31:44 UTC (rev 92717)
@@ -143,6 +143,7 @@
}
+#if NET_3_5
public static bool operator == (Matrix matrix1,
Matrix matrix2)
{
@@ -162,6 +163,7 @@
result.Append (trans2);
return result;
}
+#endif
public static Matrix Parse (string source)
{
@@ -314,7 +316,7 @@
public Point Transform (Point point)
{
- return point * this;
+ return Point.Multiply (point, this);
}
public void Transform (Point[] points)
@@ -325,7 +327,7 @@
public Vector Transform (Vector vector)
{
- return vector * this;
+ return Vector.Multiply (vector, this);
}
public void Transform (Vector[] vectors)
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches