You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
1.1 KiB
70 lines
1.1 KiB
#include "common.hpp"
|
|
|
|
|
|
//QueryInterface
|
|
STDMETHODIMP CDirectInputConfigUITest::QueryInterface(REFIID iid, LPVOID* ppv)
|
|
{
|
|
//null the out param
|
|
*ppv = NULL;
|
|
|
|
if ((iid == IID_IUnknown)
|
|
//@@BEGIN_MSINTERNAL
|
|
#ifdef DDKBUILD
|
|
#ifdef DBG
|
|
|| (iid == IID_IDirectInputConfigUITest)
|
|
#endif
|
|
#endif
|
|
//@@END_MSINTERNAL
|
|
)
|
|
{
|
|
*ppv = this;
|
|
AddRef();
|
|
return S_OK;
|
|
}
|
|
|
|
return E_NOINTERFACE;
|
|
}
|
|
|
|
|
|
//AddRef
|
|
STDMETHODIMP_(ULONG) CDirectInputConfigUITest::AddRef()
|
|
{
|
|
return InterlockedIncrement(&m_cRef);
|
|
}
|
|
|
|
|
|
//Release
|
|
STDMETHODIMP_(ULONG) CDirectInputConfigUITest::Release()
|
|
{
|
|
|
|
if (InterlockedDecrement(&m_cRef) == 0)
|
|
{
|
|
delete this;
|
|
return 0;
|
|
}
|
|
|
|
return m_cRef;
|
|
}
|
|
|
|
|
|
//TestConfigUI
|
|
STDMETHODIMP CDirectInputConfigUITest::TestConfigUI(LPTESTCONFIGUIPARAMS params)
|
|
{
|
|
return RunDFTest(params);
|
|
}
|
|
|
|
|
|
//constructor
|
|
CDirectInputConfigUITest::CDirectInputConfigUITest()
|
|
{
|
|
//set ref count
|
|
m_cRef = 1;
|
|
}
|
|
|
|
|
|
//destructor
|
|
CDirectInputConfigUITest::~CDirectInputConfigUITest()
|
|
{
|
|
// not necessary to cleanup action format here
|
|
}
|
|
|