📄 modelactionhandler.cpp
字号:
// ActionHandler.cpp : implementation file
//
#include "stdafx.h"
#include "ModelActionHandler.h"
#include "ModelAction.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
namespace SbjCore
{
namespace Mvc
{
namespace Model
{
struct ActionHandlerImpl
{
Action* pTheAction;
HANDLE hItem;
ActionHandlerImpl()
{
}
virtual ~ActionHandlerImpl()
{
}
};
/////////////////////////////////////////////////////////
IMPLEMENT_DYNCREATE(ActionHandler, CCmdTarget)
ActionHandler::ActionHandler() :
m_pImpl(new ActionHandlerImpl)
{
}
ActionHandler::~ActionHandler()
{
try
{
delete m_pImpl;
}
catch(...)
{
ASSERT(FALSE);
}
}
Action* ActionHandler::GetAction() const
{
return m_pImpl->pTheAction;
}
HANDLE ActionHandler::GetItem() const
{
return m_pImpl->hItem;
}
void ActionHandler::Initialize( Action* pAction, HANDLE hItem )
{
m_pImpl->pTheAction = pAction;
m_pImpl->hItem = hItem;
}
int ActionHandler::BeginHandling()
{
return OnBeginHandling();
}
int ActionHandler::EndHandling()
{
return OnEndHandling();
}
int ActionHandler::OnBeginHandling()
{
return Action::kContinue;
}
int ActionHandler::OnEndHandling()
{
return Action::kContinue;
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -