Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Menu - Restoring Default Layout
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Menu - Restoring Default Layout

 Post Reply Post Reply
Author
Message
Simon HB9DRV View Drop Down
Senior Member
Senior Member
Avatar

Joined: 07 July 2005
Location: Switzerland
Status: Offline
Points: 458
Post Options Post Options   Thanks (0) Thanks(0)   Quote Simon HB9DRV Quote  Post ReplyReply Direct Link To This Post Topic: Menu - Restoring Default Layout
    Posted: 28 January 2008 at 6:40am
As I am developing my software I am adding more entries to my main menu. I do not let the user modify the menu.
 
After restoring settings with CXTPPropExchangeXMLNode / ExchangeLayout I want to make sure the menu shows my latest / current layout so I use:
 
((CXTPToolBar*)m_pMenuBar)->Reset(FALSE);
 
Does this make sense? What is the correct way to be sure that when using CXTPPropExchangeXMLNode and ExchangeLayout to restore docking pane and command bar layouts that I (somehow) always have my desired Menu bar design and layout?
 
Simon HB9DRV
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: 28 January 2008 at 7:04am
Hi,
best way is just call
pMenuBar->EnableCustomization(FALSE);
and controls will not be stored in registry.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Simon HB9DRV View Drop Down
Senior Member
Senior Member
Avatar

Joined: 07 July 2005
Location: Switzerland
Status: Offline
Points: 458
Post Options Post Options   Thanks (0) Thanks(0)   Quote Simon HB9DRV Quote  Post ReplyReply Direct Link To This Post Posted: 28 January 2008 at 8:15am
Originally posted by oleg oleg wrote:

Hi,
best way is just call
pMenuBar->EnableCustomization(FALSE);
and controls will not be stored in registry.
 
Thanks, later it would be good to know how to remove components from a serialisation file, for example enumerate the sections etc.
 
I see that I can remove a section but I can't get a list of the sections.
Simon HB9DRV
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.031 seconds.