refs #308 lobby client

This commit is contained in:
Roland Winklmeier
2014-09-02 20:38:53 +02:00
parent b00d67e90c
commit 2ab1a0f847
5 changed files with 395 additions and 1 deletions

View File

@@ -17,6 +17,33 @@ namespace BlackSimPlugin
{
namespace Fs9
{
//! Safely release a COM allocated object
template <class T>
void SafeRelease(T*& pT)
{
if (pT)
pT->Release();
pT = nullptr;
}
//! Safely delete an allocated pointer
template <class T>
void SafeDelete(T*& pT)
{
if( pT != nullptr )
delete pT;
pT = nullptr;
}
//! Safely delete an allocated array
template <class T>
void SafeDeleteArray(T*& pT)
{
if(pT)
delete[] pT;
pT = nullptr;
}
//! Register all relevant metadata in BlackMisc
void registerMetadata();
@@ -29,6 +56,8 @@ namespace BlackSimPlugin
double updateInterval);
HRESULT printDirectPlayError(HRESULT error);
}
}