OnKeyDown ハンドラーを使用して、Enter キーの押下を検出しています。
void CShortestPathFinderView::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags)
{
if( nChar == VK_RETURN) //Enter key is pressed
{
CClientDC aDC(this);
rubberbanding = 0;
m_pTempElement->vertices[i++]= /*cursor position??*/;
mSecondPoint=m_pTempElement->vertices[0];
m_pTempElement->Draw(&aDC);
}
if文の3行目でカーソル位置を配列に格納したいのですが、そのポイントを取得するにはどうすればよいでしょうか? ハンドラーはそれを提供してくれますか? またはそうするための別の機能がありますか?