You've already forked com.unity.ide.cursor
mirror of
https://github.com/boxqkrtm/com.unity.ide.cursor.git
synced 2026-05-19 17:20:07 +00:00
com.unity.ide.visualstudio@2.0.8
## [2.0.8] - 2021-04-09 Project generation: Improved generation performance (especially with DOTS enabled projects). Improved stability. Updated Analyzers lookup strategy. Fixed .vsconfig file not generated when using "regenerate all". Integration Improved automation plugins. Documentation Open sourced automation plugins.
This commit is contained in:
40
Editor/COMIntegration/COMIntegration~/BStrHolder.h
Normal file
40
Editor/COMIntegration/COMIntegration~/BStrHolder.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#pragma once
|
||||
#include <OleAuto.h>
|
||||
|
||||
struct BStrHolder
|
||||
{
|
||||
BStrHolder() :
|
||||
m_Str(NULL)
|
||||
{
|
||||
}
|
||||
|
||||
BStrHolder(const wchar_t* str) :
|
||||
m_Str(SysAllocString(str))
|
||||
{
|
||||
}
|
||||
|
||||
~BStrHolder()
|
||||
{
|
||||
if (m_Str != NULL)
|
||||
SysFreeString(m_Str);
|
||||
}
|
||||
|
||||
operator BSTR() const
|
||||
{
|
||||
return m_Str;
|
||||
}
|
||||
|
||||
BSTR* operator&()
|
||||
{
|
||||
if (m_Str != NULL)
|
||||
{
|
||||
SysFreeString(m_Str);
|
||||
m_Str = NULL;
|
||||
}
|
||||
|
||||
return &m_Str;
|
||||
}
|
||||
|
||||
private:
|
||||
BSTR m_Str;
|
||||
};
|
||||
Reference in New Issue
Block a user