#pragma once

#include <vector>

#include "../Memory/ref_ptr.h"
#include "input_handler.h"

namespace roy {

    namespace ih {

        class sequence_ih : public input_handler
        {
        protected:
            typedef roy::memory::ref_ptr<input_handler> ref_ptr;
            typedef std::vector<ref_ptr> vector;

        public:
            virtual bool    OnLButtonDown(UINT nFlags, CPoint point);
            virtual bool    OnLButtonUp(UINT nFlags, CPoint point);
            virtual bool    OnLButtonDblClk(UINT nFlags, CPoint point);

            virtual bool    OnRButtonDown(UINT nFlags, CPoint point);
            virtual bool    OnRButtonUp(UINT nFlags, CPoint point);
            virtual bool    OnRButtonDblClk(UINT nFlags, CPoint point);

            virtual bool    OnMButtonDown(UINT nFlags, CPoint point);
            virtual bool    OnMButtonUp(UINT nFlags, CPoint point);
            virtual bool    OnMButtonDblClk(UINT nFlags, CPoint point);

            virtual bool    OnMouseWheel(UINT nFlags, short zDelta, CPoint point);

            virtual bool    OnMouseMove(UINT nFlags, CPoint point);

            virtual bool    OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
            virtual bool    OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags);

            virtual void    OnEntering(void);
            virtual void    OnLeaving(void);

        public:
            void            AddIH(const ref_ptr& ih);
            void            Clear(void);
        
        protected:
            vector          _seq;
        };

    }

}

