IMPLEMENT_BOOL_STOCKPROP( fname, pname, dispid )
Parameters
fname
[in] Name used to create the names of the put and get methods.
pname
[in] Name used to create the name of the data member that stores the property value.
dispid
[in] The DISPID of the property.
Remarks
Implements stock properties that are boolean values. Same as the IMPLEMENT_STOCKPROP macro except that the get method tests the value of the data member containing the property and returns VARIANT_TRUE or VARIANT_FALSE rather than returning the value. This lets containers that do not interpret all non-zero values as TRUE to use the property. Standard stock properties that are boolean values are Auto Size, Border Visible, Enabled, Tab Stop, and Valid.
IMPLEMENT_BOOL_STOCKPROP creates a data member in your control class for a property, creates a put and get method for the property, and adds code to notify and synchronize with the container if the property changes.
The put and get method names are created by appending fname to put_
and get_
. For example, if fname is Enabled
, the method names are put_Enabled
and get_Enabled
.
The data member name is created by appending pname to m_
. For example, if pname is bEnabled
, the data member is m_bEnabled
.
ATL Macros and Global Functions
See Also
CStockPropImpl, IMPLEMENT_BSTR_STOCKPROP, IMPLEMENT_STOCKPROP, CComControl::m_bEnabled, CComControl::m_bAutoSize, CComControl::m_bBorderVisible, CComControl::m_bTabStop, CComControl::m_bValid