Print Page | Close Window

DockingPaneAutoHideWnd::CloseWindow Issue

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Docking Pane
Forum Description: Topics Related to Codejock Docking Pane
URL: http://forum.codejock.com/forum_posts.asp?TID=1101
Printed Date: 06 September 2025 at 6:19pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: DockingPaneAutoHideWnd::CloseWindow Issue
Posted By: developer
Subject: DockingPaneAutoHideWnd::CloseWindow Issue
Date Posted: 24 August 2004 at 3:07pm
When the pane hides, the OnTimer event calls this code


     if (nIDEvent == TID_SLIDEOUT && m_bSlideOut)
     {
             m_nSlideStep--;
             if (m_nSlideStep > -1) DoSlideStep();
             else
             {
                  m_bSlideOut = FALSE;
                  KillTimer(TID_SLID EOUT);
                   CloseWindow( ); <-- Here
              }
     }


which calls the CloseWindow code


void CXTPDockingPaneAutoHideWnd::CloseWindow()
{
     if (!IsWindow(m_hWnd))
             return;

     ShowWindow(SW_HIDE);
     if (m_pPane && m_pPane->GetSafeHwnd() && m_pPane->GetParent() == this)
      {     ;  ;
             m_pPane->ShowWindow(SW_HIDE);
              m_pPane->SetParentFrame(GetDockingPaneM anager()->GetSi te());     
      }
     m_pPane = 0;

     if (m_pPanel && m_pPanel->m_pActiveWnd == this)
             m_pPanel->m_pActiveWnd = 0;

     PostMessage(WM_CLOSE); <-- Here
}


but the PostMessage gets the active document and tries to close it... That is a problem. It is getting the document in my CMDIChildFrameWnd (which has changed) and tries to close the document. Why is this happening? Every time someone Autohides a pane and has modified the document, It asks if the user wants to save... they are not closing any document. they are Auto Hiding a pane. Please help.



Replies:
Posted By: Oleg
Date Posted: 25 August 2004 at 1:39am

???

PostMessage sends WM_CLOSE to self window.  

Can I see you code?

 



-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: developer
Date Posted: 25 August 2004 at 12:05pm
I will send you an example...



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net