[ATL][SHELL32][EXPLORER] Disable ATLASSERT (#3527)

We are not ready for enabling ATLASSERT. Enabling ATL assertions takes time to realize. CORE-17505
- Disable ATLASSERT by undefining _DEBUG.
- Revert currently non-fixable codes.
This commit is contained in:
Katayama Hirofumi MZ 2021-03-11 20:26:45 +09:00 committed by GitHub
parent 4583eae4f7
commit 9259ded8ae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 9 additions and 12 deletions

View file

@ -989,6 +989,7 @@ VOID CAppInfoDisplay::ResizeChildren(int Width, int Height)
#if DBG #if DBG
ATLASSERT(dwError == ERROR_SUCCESS); ATLASSERT(dwError == ERROR_SUCCESS);
#endif #endif
UNREFERENCED_PARAMETER(dwError);
UpdateWindow(); UpdateWindow();
} }

View file

@ -1231,10 +1231,8 @@ void CNotifyToolbar::Initialize(HWND hWndParent, CBalloonQueue * queue)
TBSTYLE_FLAT | TBSTYLE_TOOLTIPS | TBSTYLE_WRAPABLE | TBSTYLE_TRANSPARENT | TBSTYLE_FLAT | TBSTYLE_TOOLTIPS | TBSTYLE_WRAPABLE | TBSTYLE_TRANSPARENT |
CCS_TOP | CCS_NORESIZE | CCS_NOPARENTALIGN | CCS_NODIVIDER; CCS_TOP | CCS_NORESIZE | CCS_NOPARENTALIGN | CCS_NODIVIDER;
HWND toolbar = CToolbar::Create(hWndParent, styles); // HACK & FIXME: CORE-17505
//HACK: We have not created this toolbar properly, so we need to subclass it now! SubclassWindow(CToolbar::Create(hWndParent, styles));
m_hWnd = NULL;
SubclassWindow(toolbar);
// Force the toolbar tooltips window to always show tooltips even if not foreground // Force the toolbar tooltips window to always show tooltips even if not foreground
HWND tooltipsWnd = (HWND)SendMessageW(TB_GETTOOLTIPS); HWND tooltipsWnd = (HWND)SendMessageW(TB_GETTOOLTIPS);

View file

@ -287,8 +287,7 @@ public:
HWND toolbar = CToolbar::Create(hWndParent, styles); HWND toolbar = CToolbar::Create(hWndParent, styles);
SetDrawTextFlags(DT_NOPREFIX, DT_NOPREFIX); SetDrawTextFlags(DT_NOPREFIX, DT_NOPREFIX);
//HACK: We have not created this toolbar properly, so we need to subclass it now! // HACK & FIXME: CORE-17505
m_hWnd = NULL;
return SubclassWindow(toolbar); return SubclassWindow(toolbar);
} }
}; };

View file

@ -200,10 +200,8 @@ public:
VOID Initialize() VOID Initialize()
{ {
//HACK: We have not created this button properly, so we need to subclass it now! // HACK & FIXME: CORE-17505
HWND button = m_hWnd; SubclassWindow(m_hWnd);
m_hWnd = NULL;
SubclassWindow(button);
SetWindowTheme(m_hWnd, L"Start", NULL); SetWindowTheme(m_hWnd, L"Start", NULL);

View file

@ -398,7 +398,8 @@ HRESULT CMenuToolbarBase::CreateToolbar(HWND hwndParent, DWORD dwFlags)
rc.bottom = 1; rc.bottom = 1;
} }
CToolbar::Create(hwndParent, tbStyles, tbExStyles); // HACK & FIXME: CORE-17505
SubclassWindow(CToolbar::Create(hwndParent, tbStyles, tbExStyles));
SetWindowTheme(m_hWnd, L"", L""); SetWindowTheme(m_hWnd, L"", L"");

View file

@ -1,7 +1,7 @@
add_library(atl_classes INTERFACE) add_library(atl_classes INTERFACE)
if(DBG) if(DBG)
target_compile_definitions(atl_classes INTERFACE _DEBUG) #target_compile_definitions(atl_classes INTERFACE _DEBUG) # HACK & FIXME: CORE-17505
endif() endif()
target_include_directories(atl_classes INTERFACE target_include_directories(atl_classes INTERFACE