Another problem:
class CTest : public CWnd {
public:
CTest ();
HRESULT GetWindowHandle (HWND*);
protected:
DECLARE_INTERFACE_MAP()
BEGIN_INTERFACE_PART(OleWindow, IOleWindow)
HRESULT STDMETHODCALLTYPE GetWindow (HWND*);
HRESULT STDMETHODCALLTYPE ContextSensitiveHelp (BOOL);
END_INTERFACE_PART(OleWindow)
};
CTest::CTest()
{
}
HRESULT CTest::GetWindowHandle(HWND* phWnd)
{
*phWnd = m_hWnd;
return S_OK;
}
STDMETHODIMP_(ULONG) CTest::XOleWindow::AddRef()
{
METHOD_PROLOGUE(CTest, OleWindow);
return pThis->ExternalAddRef();
}
STDMETHODIMP_(ULONG) CTest::XOleWindow::Release()
{
METHOD_PROLOGUE(CTest, OleWindow);
return pThis->ExternalRelease();
}
STDMETHODIMP CTest::XOleWindow::QueryInterface(REFIID riid, LPVOID *ppVoid)
{
METHOD_PROLOGUE(CTest, OleWindow);
return (HRESULT) pThis->ExternalQueryInterface(&riid, ppVoid);
}
STDMETHODIMP CTest::XOleWindow::GetWindow(HWND* phWnd)
{
METHOD_PROLOGUE(CTest, OleWindow);
return pThis->GetWindowHandle(phWnd);
}
STDMETHODIMP CTest::XOleWindow::ContextSensitiveHelp(BOOL)
{
METHOD_PROLOGUE(CTest, OleWindow);
return S_OK;
}
It seems, that VA has some trouble with the END_INTERFACE_PART macro, it is defined in afxwin.h.
It's very interesting that it works fine when I delete VA's local appdata folder and restart VS 2008. But on next start with already parsed symbols VA shows the code as in the picture above.
The same (works only on first start with empty local appdata folder)applies to message maps. Reported as case=8934.