Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Docking Pane
  New Posts New Posts RSS Feed - XTP_DPN_SHOWWINDOW behavior changed in v13
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

XTP_DPN_SHOWWINDOW behavior changed in v13

 Post Reply Post Reply
Author
Message
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post Topic: XTP_DPN_SHOWWINDOW behavior changed in v13
    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/
Back to Top
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post 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/
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post 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
Back to Top
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post 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/
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.125 seconds.