Stop filtering out SC_CLOSE. 'X' button works more reliably, also alt-F4.
Remove minimize box from style.
Signed-off-by: Kevin Wasserman <kevin.wasserman@painless-security.com>
ticket: 7332 (new)
queue: kfw
target_version: 1.10.4
tags: pullup
BOOL CMainFrame::PreTranslateMessage(MSG* pMsg)
{
- if ( pMsg->message == WM_SYSCOMMAND && (pMsg->wParam & 0xfff0) == SC_CLOSE )
- {
- return TRUE;
- }
return CLeashFrame::PreTranslateMessage(pMsg);
}
{
// Use the specific class name we established earlier
// Remove the Minimize and Maximize buttons
-// cs.style &= ~WS_MINIMIZEBOX;
+ cs.style &= ~WS_MINIMIZEBOX;
cs.style &= ~WS_MAXIMIZEBOX;
// Initialize the extended window style to display a TaskBar entry with WS_EX_APPWINDOW
cs.dwExStyle |= WS_EX_APPWINDOW;