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

LoadState behavior

 Post Reply Post Reply
Author
Message
Magnetic core View Drop Down
Newbie
Newbie
Avatar

Joined: 22 August 2003
Location: Switzerland
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote Magnetic core Quote  Post ReplyReply Direct Link To This Post Topic: LoadState behavior
    Posted: 22 August 2003 at 2:49am

Hello,

Not really a bug, but can be problematic (DockingPane v8.0):

I create a program with 2 panes, then I use DockingPaneLayout to save its layout into the registry. I modify my program to create only the first pane. When a launch the program again, the second pane is still created (I use the DockingPaneLayout to load my panes layout). I have seen in source code that Load function create panes from register values and doesn't take into account the fact that only one pane has been created.

Thanks a lot,

Magnetic core 



Edited by Magnetic core
Back to Top
spike View Drop Down
Groupie
Groupie


Joined: 13 May 2003
Location: United States
Status: Offline
Points: 48
Post Options Post Options   Thanks (0) Thanks(0)   Quote spike Quote  Post ReplyReply Direct Link To This Post Posted: 07 September 2003 at 2:05pm
I have also noticed this problem. Along with another problem when you call LoadState on the DockingPaneLayout. If I create Pane A and Pane B and distribute my application, then decide to modify my application to create Pane C, when LoadState gets called it does not load Pane C into the MainFrame. I guess since it isnt in the registry then it knows nothing about it so it doesnt create it.
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: 31 October 2003 at 11:13pm

You must programmaticaly control this:

CXTPDockingPaneLayout layoutNormal(&m_paneManager);
if (layoutNormal.Load(_T("NormalLayout"))) 
{

  // check if we have 3 stored panes
  if (layoutNormal.GetPaneList().GetCount() == 3)
  {
   m_paneManager.SetLayout(&layoutNormal) ; 
  }
 }

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.156 seconds.