#ifndef __ToolSelEdit_h
#define __ToolSelEdit_h

#include "ToolMoveResizeTmpl.h"	// Super class.
#include "ToolBaseFDA.h"		// Super super class.
#include "ToolTextFindTmpl.h"	// Super class.

#ifdef SUPER_CLASS
#undef SUPER_CLASS
#endif
#define SUPER_CLASS FCToolTextFindTmpl< FCToolMoveResizeTmpl<FCToolBaseFDA, FCToolSelectObjTmplId> >

struct FCFontCharInfo;
class FCObjDynabase;

class FCToolSelEdit : public SUPER_CLASS
{
protected:
typedef SUPER_CLASS BASE_CLASS;
typedef BASE_CLASS::BASE_CLASS BASE_BASE_CLASS;

public:
	FCToolSelEdit ();

	//----- _xZkqqHx_iDfEiDhFiDeOiDiJiDfIiCmFjEeDiInD_xHqqkZx_ -----
// 06.12.09 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	virtual void	OnDraw (CDC* pDC);
	virtual BOOL	CanSelectTool () const;
	virtual BOOL	CanDelete () const;
	virtual void	OnDelete (CDC* pDC);
	virtual BOOL	CanObjectGroup () const;
	virtual void	OnObjectGroup ();
	virtual BOOL	CanObjectUngroup () const;
	virtual void	OnObjectUngroup ();

	virtual BOOL	CanPaste () const;
	virtual void	OnPaste (CDC* pDC);
	virtual BOOL	CanPasteSpec (UINT dwFormat) const;
	virtual void	OnPasteSpec (CDC* pDC, UINT dwFormat);

	virtual BOOL	CanReplaceText () const;
	virtual BOOL	CanReplaceNextText () const;
	virtual void	OnReplaceNextText ();
	virtual BOOL	CanReplacePrevText () const;
	virtual void	OnReplacePrevText ();
	virtual BOOL	CanReplaceTextAll () const;
	virtual void	OnReplaceTextAll ();
	virtual BOOL	CanReplaceTextAllInSelect () const;
	virtual void	OnReplaceTextAllInSelect ();

	virtual BOOL	CanObjectConvertToPoly () const;
	virtual void	OnObjectConvertToPoly ();

	virtual BOOL	IsObjectCommandEnable (DWORD dwCmdID) const;

protected:
	//----- FCToolBaseFDA_xZkqqHx_iCmMiDfEiDhFiDeOiDiJiDfIiCmFjFeLjHhGiCmJiJjOiClGiCmE_xHqqkZx_ -----
// 06.12.09 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
	virtual void	OnDrawState (CDC* pDC, int iState);
	virtual int		TransFDA (int iState, int iEvent);
	virtual void	StateFDA (int iState, CDC* pDC);

	//----- _xZkqqHx_jBeKiInKiPpDjBnEiPiIjHjNiBgJiDeJiBfLiDgPiBfLiDiJiDeDiDgIiBgK_xHqqkZx_ -----
	virtual void	StateExitToolByButton (CDC* pDC);		// _xZkqqHx_iDgDiBfLiDiLiPeJjHlJiBeC_xHqqkZx_

	//----- _xZkqqHx_jBeKiInKiPpDjBnEiPiIjHjN_xHqqkZx_ -----
	virtual void	StateStopMoveObj2 (CDC* pDC);	// _xZkqqHx_jFjEjFgJiInKjDkOiPeJjHlJ_xHqqkZx__2_xZkqqHx_iBeC_xHqqkZx_
	virtual void	StateContextMenu3 (CDC* pDC);	// _xZkqqHx_iDiBiDgKiDiFiBfLjFfMiOkG_xHqqkZx__3_xZkqqHx_iBeC_xHqqkZx_
	virtual void	StateMoveDupCommand (CDC* pDC);	// _xZkqqHx_iInKjDkOjFkBjAlLiDfCiDhNiDjDiDgIiBeC_xHqqkZx_

	//----- FCToolBaseFDA_xZkqqHx_iCmMiDfEiDhFiDeOiDiJiDfIiCmFjFeLjHhGiCmJiJjOiClGiCmE_xHqqkZx_ -----
	virtual BOOL	CanLinkToSelection () const;	// Idle_xZkqqHx_iCmF_xHqqkZx_CTRL+MSMOVE_xZkqqHx_iCmFiDiKiDjDiDeOiCkKjCkDiCoKiCoJiCkJiBeI_xHqqkZx_

	static BOOL		ReplaceAllCallback (FCSearchParser& sp, FCObjFigure* pTextObj, CDC* pDC);

protected:
// _xZkqqHx_iClBiCmMiDeOiDiJiDfIiMmFjHeMiCmMjCoIiLgAiBeC_xHqqkZx_
enum
{
	STATE_BEGIN = BASE_CLASS::STATE_END,	// _xZkqqHx_iPpDjBnEiKeKiOgOiBeC_xHqqkZx_
	STATE_STOP_MOVE_OBJ_2,	// _xZkqqHx_jFjEjFgJiInKjDkOiPeJjHlJ_xHqqkZx__2_xZkqqHx_iBeC_xHqqkZx_
	STATE_CONTEXT_MENU_3,	// _xZkqqHx_iDiBiDgKiDiFiBfLjFfMiOkG_xHqqkZx__3_xZkqqHx_iBeC_xHqqkZx_
	STATE_MOVE_DUP_COMMAND,	// _xZkqqHx_iInKjDkOjFkBjAlLiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
	STATE_END,				// _xZkqqHx_iPpDjBnEiPeJjHlJiBeC_xHqqkZx_
};

protected:
	//----- _xZkqqHx_iDhJiBfLiDfIiDgHiKnGjIeBjFmPjAjE_xHqqkZx_ -----
	long			m_lPasteCount;		// _xZkqqHx_jDkPiClGiDgGiBfLiDfOiCmMiDhJiBfLiDfIiDgHiJpBjAjEiBeC_xHqqkZx_
	DBLPoint		m_mmptPasteOffset;	// _xZkqqHx_iDhJiBfLiDfIiDgHiOjOiCmMiDeJiDhEiDfKiDgCiDgHjHmKiBeC_xHqqkZx_
	FCObjDynabase*	m_pLastPasteObj;	// _xZkqqHx_jBePiJpBiDhJiBfLiDfIiDgHiClFiClNjFjEjFgJiPfHiNmFiPiJiCmMjFjEjFgJiBeC_xHqqkZx_
	DWORD			m_dwLastPasteObj;	// _xZkqqHx_jBePiJpBiDhJiBfLiDfIiDgHiClFiClNjFjEjFgJiPfHiNmFiPiJiCmMjFjEjFgJ_xHqqkZx_ID_xZkqqHx_iBeC_xHqqkZx_
	DBLPoint		m_mmptLastPasteObj;	// _xZkqqHx_jBePiJpBiDhJiBfLiDfIiDgHiOjOiCmMjFjEjFgJiPfHiNmFiPiJiCmMjFjEjFgJiCmMiNmAjFfHiBeC_xHqqkZx_
}; // class FCToolSelEdit.

#endif//__ToolSelEdit_h
