F4MP/tiltedcode/Code/immersive_launcher/utils/ComUtils.h
Jous99 37b16f1547 code upload
codigo original de f4mp y tilted para referencias
2026-01-06 18:45:00 +01:00

16 lines
313 B
C++

#pragma once
#include <wrl.h>
// short alias
template <typename T> using ComPtr = Microsoft::WRL::ComPtr<T>;
struct ComScope
{
ComScope()
{
HRESULT hr = CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE);
(void)hr;
}
~ComScope() { CoUninitialize(); }
};