CXTColorPopup now calling DestroyWindow |
Post Reply |
Author | |
cpede
Senior Member Joined: 13 August 2004 Location: Denmark Status: Offline Points: 668 |
Post Options
Thanks(0)
Posted: 24 February 2009 at 3:45am |
You changed this code from v1211:
void CXTColorPopup::EndSelection(int nCurSel)
{
CXTPMouseMonitor::SetupHook(NULL);
OnEndSelection(nCurSel, m_callerParam);
PostMessage(WM_CLOSE);
} to this code in v1300:
void CXTColorPopup::EndSelection(int nCurSel)
{
CXTPMouseMonitor::SetupHook(NULL); OnEndSelection(nCurSel, m_callerParam); DestroyWindow(); } But the direct call to DestroyWindow makes my Color Popup crash!
A quick debug shows that the EndSelection is called from both CXTColorPopup::OnKillFocus and
from CXTColorSelectorCtrl::OnLButtonUp, making the second call fail.
-cpede
|
|
cpede
Senior Member Joined: 13 August 2004 Location: Denmark Status: Offline Points: 668 |
Post Options
Thanks(0)
|
This is still a problem in v1310.
-cpede
|
|
Product: Xtreme ToolkitPro (24.0.0)
Platform: Windows 10 (x64) Language: Visual Studio 2017 (C++) |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hello,
We added flag now to prevent second call:
void CXTColorPopup::EndSelection(int nCurSel)
{ m_bEndSelection = TRUE; CXTPMouseMonitor::SetupHook(NULL);
OnEndSelection(nCurSel, m_callerParam);
DestroyWindow();
} void CXTColorPopup::OnKillFocus(CWnd* pNewWnd)
{ CWnd::OnKillFocus(pNewWnd); if (!m_pColorDlg && !m_bEndSelection)
{ EndSelection(-1); } } |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |