BCGControlBar Pro for MFC
static BOOL CBCGPToolBar::IsLastCommandFromButton ( CBCGPToolbarButton pButton)
static

Determines whether the last command was sent from a toolbar button.

Returns
Nonzero if the last command was sent from the specified by pButton button; otherwise 0.

Call this static member function to determine whether the last command was sent from the specified by the pButton parameter toolbar button.

The function obtains a pointer to MSG structure by calling CWnd::GetCurrentMessage function. Then, it compares the handle to the button's window with MSG::lParam and MSG::hwnd members.

Parameters
pButtonPointer to button.