#ifndef __MANDOWINDOW_HH
#define __MANDOWINDOW_HH

#include <QtGui/QWidget>
#include <boost/numeric/ublas/vector.hpp>
#include "image_v4linput.h"
#include "pointerRecognition.hh"
#include "ui_mandoWindow.hh"
#include <X11/Xlib.h>
#ifdef None
#undef None
#endif

class MandoWizard;

class MandoWindow: public QWidget
{
  Q_OBJECT
public:
  typedef mimas::image_input< mimas::rgba< unsigned char > > Video;
  typedef boost::shared_ptr< Video > VideoPtr;
  typedef boost::numeric::ublas::vector< double > Vector;
  MandoWindow( QWidget *parent = 0, Qt::WFlags = 0 );
protected slots:
  void about();
  void configure();
  void activate(bool);
  void startDrag();
  void stopDrag();
  void click();
  void mouseMove(int,int);
protected:
  mimas::image< mimas::rgba< unsigned char > > grabColourFrame(void)
    throw (mimas ::mimasexception);
  virtual void timerEvent( QTimerEvent *e );
  Ui::MandoWindow ui;
  MandoWizard *mandoWizard;
  int timer;
  PointerRecognitionPtr pointerRecognition;
  VideoPtr input;
};

#endif