Author: jackson
Date: 2007-06-04 15:17:18 -0400 (Mon, 04 Jun 2007)
New Revision: 78583
Modified:
trunk/moon/src/ChangeLog
trunk/moon/src/shape.cpp
trunk/moon/src/shape.h
Log:
* shape.cpp/h: width and height are properties of the
FrameworkElement.
Modified: trunk/moon/src/ChangeLog
===================================================================
--- trunk/moon/src/ChangeLog 2007-06-04 19:09:32 UTC (rev 78582)
+++ trunk/moon/src/ChangeLog 2007-06-04 19:17:18 UTC (rev 78583)
@@ -1,5 +1,10 @@
2007-06-04 Jackson Harper <[EMAIL PROTECTED]>
+ * shape.cpp/h: width and height are properties of the
+ FrameworkElement.
+
+2007-06-04 Jackson Harper <[EMAIL PROTECTED]>
+
* shape.cpp/h: add ellipse_new
- set width/height on ellipses (ellipsi ?) and draw them.
* xaml.cpp: create ellipses, get zorder correct
Modified: trunk/moon/src/shape.cpp
===================================================================
--- trunk/moon/src/shape.cpp 2007-06-04 19:09:32 UTC (rev 78582)
+++ trunk/moon/src/shape.cpp 2007-06-04 19:17:18 UTC (rev 78583)
@@ -180,8 +180,8 @@
double rx, ry, cx, cy;
- rx = width / 2;
- ry = height / 2;
+ rx = w / 2;
+ ry = h / 2;
cx = x + rx;
cy = y + ry;
@@ -221,12 +221,7 @@
void
Ellipse::set_prop_from_str (const char *prop, const char *value)
{
- if (!g_strcasecmp (prop, "width"))
- width = strtod (value, NULL);
- else if (!g_strcasecmp (prop, "height"))
- height = strtod (value, NULL);
- else
- Shape::set_prop_from_str (prop, value);
+ Shape::set_prop_from_str (prop, value);
}
void
Modified: trunk/moon/src/shape.h
===================================================================
--- trunk/moon/src/shape.h 2007-06-04 19:09:32 UTC (rev 78582)
+++ trunk/moon/src/shape.h 2007-06-04 19:17:18 UTC (rev 78583)
@@ -65,10 +65,8 @@
//
class Ellipse : public Shape {
public:
- double width, height;
+ Ellipse () { };
- Ellipse () : width (0), height (0) { };
-
void Draw (Surface *s);
virtual void set_prop_from_str (const char *prop, const char *value);
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches