Print Page | Close Window

XTP_DPN_SHOWWINDOW behavior changed in v13

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=13381
Printed Date: 23 November 2024 at 11:26am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: XTP_DPN_SHOWWINDOW behavior changed in v13
Posted By: znakeeye
Subject: XTP_DPN_SHOWWINDOW behavior changed in v13
Date Posted: 10 February 2009 at 3:43pm
Upgraded to v13.0.0 from v12.1.1.
 
pMainPane = GetMainFrame().GetPaneManager().FindPane(IDR_EXISTING_PANE);
CWnd* pWndChild = pMainPane->GetChild(); // Returns NULL when pane has not been sized (zero-height in this case)!
 
It seems XTP_DPN_SHOWWINDOW is not sent when the pane has zero-height. Is this by design?
 
Anyway, such changes should be thoroughly documented!


-------------
PokerMemento - http://www.pokermemento.com/



Replies:
Posted By: znakeeye
Date Posted: 10 February 2009 at 3:55pm

You check for empty rectangles in the ShowWindow() call. Can you please tell me how to make certain pane-children attached explicitly? When I call GetChild() from my other pane-manager, the child window must already be set!



-------------
PokerMemento - http://www.pokermemento.com/


Posted By: Oleg
Date Posted: 11 February 2009 at 4:45am
Hi,
I compared sources with 12.1.1 - nothing that can change this behavior.
XTP_DPN_SHOWWINDOW called when pane become visible.
 
You can add method that attach panes and call it from CMainFrame::Create and from NotifyHandler.


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


Posted By: znakeeye
Date Posted: 11 February 2009 at 4:58am

The behavior might be the same in v12, but I encountered it in v13.

Let me clarify.
XTP_DPN_SHOWWINDOW is not sent when the the pane's rectangle is empty (IsRectEmpty). This should be documented as it could lead to strange behavior:
 
1) The user changes the size of a pane to zero-height and closes the application.
2) Pane is saved to the Registry.
3) Application is opened and the pane read from the Registry.
4) Since the child-window is created and attached in OnDockingPaneNotify(), the child will not be created until the pane is explicitly resized!
 
Perhaps create/attach should always be made in OnCreate() instead of OnDockingPaneNotify()?


-------------
PokerMemento - http://www.pokermemento.com/



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