다음을 통해 공유


깜빡임 없는 활성화 제공

If your control draws itself identically in the inactive and active states (and does not use windowless activation), you can eliminate the drawing operations and the accompanying visual flicker that normally occur when making the transition between the inactive and active states. To do this, include the noFlickerActivate flag in the set of flags returned by COleControl::GetControlFlags. 예를 들면 다음과 같습니다.

DWORD CMyAxOptCtrl::GetControlFlags()
{
   DWORD dwFlags = COleControl::GetControlFlags();


...


dwFlags |= noFlickerActivate;


...


   return dwFlags;
}

The code to include this flag is automatically generated if you select the Flicker-Free activation option on the Control Settings page when creating your control with the MFC ActiveX Control Wizard.

If you are using windowless activation, this optimization has no effect.

참고 항목

개념

MFC ActiveX 컨트롤: 최적화