mirror of
https://github.com/reactos/reactos.git
synced 2025-05-30 22:49:12 +00:00
Fix some assertions now that they are enabled (#3524)
Fix some assertions, hack out some others (they need more ATL work). CORE-17505
This commit is contained in:
parent
df35c8d05e
commit
1952e5b795
7 changed files with 23 additions and 5 deletions
|
@ -1231,7 +1231,10 @@ 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;
|
||||||
|
|
||||||
SubclassWindow(CToolbar::Create(hWndParent, styles));
|
HWND toolbar = CToolbar::Create(hWndParent, styles);
|
||||||
|
//HACK: We have not created this toolbar properly, so we need to subclass it now!
|
||||||
|
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);
|
||||||
|
|
|
@ -287,6 +287,8 @@ 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!
|
||||||
|
m_hWnd = NULL;
|
||||||
return SubclassWindow(toolbar);
|
return SubclassWindow(toolbar);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -200,7 +200,11 @@ public:
|
||||||
|
|
||||||
VOID Initialize()
|
VOID Initialize()
|
||||||
{
|
{
|
||||||
SubclassWindow(m_hWnd);
|
//HACK: We have not created this button properly, so we need to subclass it now!
|
||||||
|
HWND button = m_hWnd;
|
||||||
|
m_hWnd = NULL;
|
||||||
|
SubclassWindow(button);
|
||||||
|
|
||||||
SetWindowTheme(m_hWnd, L"Start", NULL);
|
SetWindowTheme(m_hWnd, L"Start", NULL);
|
||||||
|
|
||||||
m_ImageList = ImageList_LoadImageW(hExplorerInstance,
|
m_ImageList = ImageList_LoadImageW(hExplorerInstance,
|
||||||
|
@ -214,6 +218,8 @@ public:
|
||||||
UpdateSize();
|
UpdateSize();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Hack:
|
||||||
|
// Use DECLARE_WND_SUPERCLASS instead!
|
||||||
HWND Create(HWND hwndParent)
|
HWND Create(HWND hwndParent)
|
||||||
{
|
{
|
||||||
WCHAR szStartCaption[32];
|
WCHAR szStartCaption[32];
|
||||||
|
|
|
@ -915,6 +915,7 @@ CLanStatus::InitializeNetTaskbarNotifications()
|
||||||
Index = 1;
|
Index = 1;
|
||||||
while (TRUE)
|
while (TRUE)
|
||||||
{
|
{
|
||||||
|
pNetCon.Release();
|
||||||
hr = pEnumCon->Next(1, &pNetCon, &Count);
|
hr = pEnumCon->Next(1, &pNetCon, &Count);
|
||||||
if (hr != S_OK)
|
if (hr != S_OK)
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -398,7 +398,7 @@ HRESULT CMenuToolbarBase::CreateToolbar(HWND hwndParent, DWORD dwFlags)
|
||||||
rc.bottom = 1;
|
rc.bottom = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
SubclassWindow(CToolbar::Create(hwndParent, tbStyles, tbExStyles));
|
CToolbar::Create(hwndParent, tbStyles, tbExStyles);
|
||||||
|
|
||||||
SetWindowTheme(m_hWnd, L"", L"");
|
SetWindowTheme(m_hWnd, L"", L"");
|
||||||
|
|
||||||
|
@ -1163,6 +1163,7 @@ HRESULT CMenuStaticToolbar::SetMenu(
|
||||||
m_hwndMenu = hwnd;
|
m_hwndMenu = hwnd;
|
||||||
m_dwMenuFlags = dwFlags;
|
m_dwMenuFlags = dwFlags;
|
||||||
|
|
||||||
|
if (IsWindow())
|
||||||
ClearToolbar();
|
ClearToolbar();
|
||||||
|
|
||||||
return S_OK;
|
return S_OK;
|
||||||
|
@ -1408,6 +1409,7 @@ HRESULT CMenuSFToolbar::SetShellFolder(IShellFolder *psf, LPCITEMIDLIST pidlFold
|
||||||
m_hKey = hKey;
|
m_hKey = hKey;
|
||||||
m_dwMenuFlags = dwFlags;
|
m_dwMenuFlags = dwFlags;
|
||||||
|
|
||||||
|
if (IsWindow())
|
||||||
ClearToolbar();
|
ClearToolbar();
|
||||||
|
|
||||||
return S_OK;
|
return S_OK;
|
||||||
|
|
|
@ -135,6 +135,8 @@ private:
|
||||||
MESSAGE_HANDLER(WM_COMMAND, OnWinEventWrap)
|
MESSAGE_HANDLER(WM_COMMAND, OnWinEventWrap)
|
||||||
MESSAGE_HANDLER(WM_NOTIFY, OnWinEventWrap)
|
MESSAGE_HANDLER(WM_NOTIFY, OnWinEventWrap)
|
||||||
MESSAGE_HANDLER(WM_TIMER, OnPopupTimer)
|
MESSAGE_HANDLER(WM_TIMER, OnPopupTimer)
|
||||||
|
ALT_MSG_MAP(1)
|
||||||
|
// No pager specific handlers yet
|
||||||
END_MSG_MAP()
|
END_MSG_MAP()
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -251,6 +251,8 @@ class CToolbar :
|
||||||
{
|
{
|
||||||
public: // Configuration methods
|
public: // Configuration methods
|
||||||
|
|
||||||
|
// Hack:
|
||||||
|
// Use DECLARE_WND_SUPERCLASS instead!
|
||||||
HWND Create(HWND hWndParent, DWORD dwStyles = 0, DWORD dwExStyles = 0)
|
HWND Create(HWND hWndParent, DWORD dwStyles = 0, DWORD dwExStyles = 0)
|
||||||
{
|
{
|
||||||
if (!dwStyles)
|
if (!dwStyles)
|
||||||
|
|
Loading…
Reference in a new issue