# HG changeset patch
# User insilmaril
# Date 1177516974 0
# Node ID b0d72eb511c9138ad9bd7a1890d5d5753cd87f8d
# Parent  12e763c3e4869f54f5ff833d97369879eb1897ca
started doxygen documentation

diff -r 12e763c3e486 -r b0d72eb511c9 animpoint.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/animpoint.cpp	Wed Apr 25 16:02:54 2007 +0000
@@ -0,0 +1,70 @@
+#include "animpoint.h"
+
+AnimPoint::AnimPoint()
+{
+	init();
+}
+
+void AnimPoint::operator= ( const AnimPoint & other )
+{
+	copy (other);
+}
+
+void AnimPoint::operator= ( const QPointF & other )
+{
+	init();
+	setX (other.x() );
+	setY (other.x() );
+}
+
+bool AnimPoint::operator== ( const QPointF& other )
+{
+	QPointF p( x(),y());
+	return p == other;
+}
+
+bool AnimPoint::operator== ( AnimPoint  other )
+{
+    if (rx() != other.rx() ) return false;
+    if (ry() != other.ry() ) return false;
+    if (animated != other.animated ) return false;
+
+	return true;
+}
+
+void AnimPoint::init ()
+{
+	animated=false;
+}
+
+void AnimPoint::copy (AnimPoint other)
+{
+	setX (other.x() );
+	setY (other.x() );
+	animated=other.animated;
+}
+
+
+void AnimPoint::setDest(const QPointF &p)
+{
+	destPos=p;
+}
+
+void AnimPoint::setAnimated(bool b)
+{
+	animated=b;
+}
+
+bool AnimPoint::isAnimated()
+{
+	return animated;
+}
+
+void AnimPoint::animate()
+{
+	setX (x()+1);
+	setY (y()+1);
+}
+
+
+
diff -r 12e763c3e486 -r b0d72eb511c9 animpoint.h
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/animpoint.h	Wed Apr 25 16:02:54 2007 +0000
@@ -0,0 +1,29 @@
+#ifndef ANIMPOINT_H
+#define ANIMPOINT_H
+
+#include <QPointF>
+
+class AnimPoint: public QPointF
+{
+public:
+    AnimPoint();
+	void operator= ( const AnimPoint & );
+	void operator= ( const QPointF & );
+	bool operator== ( const QPointF & );
+	bool operator== ( AnimPoint  );
+	void init();
+	void copy(AnimPoint other);
+	void setDest (const QPointF &);
+	void setAnimated(bool);
+	bool isAnimated ();
+	void animate();
+
+private:
+	QPointF currentPos;
+	QPointF destPos;
+	qreal n;
+    bool animated;
+
+};
+
+#endif