CODController::OnCtlColor

HBRUSH CODController::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)

Called when a control needs a brush for painting itself.

Defined in: OdController.cpp

Return Value

A handle to a brush.

Parameters

pDC

Contains a pointer to the display context for the child window. May be temporary.

pWnd

Contains a pointer to the control asking for the color. May be temporary.

nCtlColor

Flag indicating type of control.

Comments

This function is called when the WM_CTLCOLOR message is received. It checks to see if the control passed in is the current text edit. If so, it gets a brush from the text component by calling CODTextComponent::GetCtlBrush.