property.cpp

来自「Thinkinc++English 电子书籍,英文版」· C++ 代码 · 共 33 行

CPP
33
字号
// Property.cpp : Implementation of CProperty
#include "stdafx.h"
#include "Simple18.h"
#include "Property.h"

/////////////////////////////////////////////////////////////////////////////
// CProperty


STDMETHODIMP CProperty::get_str(BSTR *pVal)
{
	*pVal = m_str.Copy();
	return S_OK;
}

STDMETHODIMP CProperty::put_str(BSTR newVal)
{
	m_str = newVal;
	return S_OK;
}

STDMETHODIMP CProperty::get_integer(long *pVal)
{
	*pVal = m_integer;
	return S_OK;
}

STDMETHODIMP CProperty::put_integer(long newVal)
{
	m_integer = newVal;
	return S_OK;
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?