Print Page | Close Window

Dialog in pane, handling Alt+F, etc.

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=16194
Printed Date: 15 May 2024 at 5:55am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Dialog in pane, handling Alt+F, etc.
Posted By: CyberSky
Subject: Dialog in pane, handling Alt+F, etc.
Date Posted: 15 February 2010 at 5:08am
I just started using the Xtreme Toolkit Pro (latest version 13.2.1, using VS2008 on Windows 7 64-bit) a week ago and am having a tough time replacing dialog bars with docking panes containing dialog resources. (Control messages aren't automatically sent to my program's view, etc. There are many differences and more to do than I had imagined.)
 
I just discovered that when any of my docking panes have focus, pressing Alt+F doesn't open the File menu, etc.
 
I checked the Active Pane View sample program and found the same thing there. If you click on the Options or Properties pane and they then have focus, you can press Alt+F to open the File menu. But, if you click on the Dialog pane and it has focus, Alt+F doesn't work.
 
Can anybody offer a hint about what I need to do to make things work as they did with dialog bars? I noticed another sample uses a splitter with a form view and am thinking maybe I need to forget about the docking panes and use that approach instead.
 
 
 



Replies:
Posted By: Oleg
Date Posted: 16 February 2010 at 7:51am
Hi,
 
Most easy way is to add such virtual method.

BOOL CPaneDialog::PreTranslateMessage(MSG* pMsg)
{
 // Don't call CDialog::PreTranslateMessage to prevent eating keys.
 return CWnd::PreTranslateMessage(pMsg);
}


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


Posted By: CyberSky
Date Posted: 17 February 2010 at 1:02pm

Thank you! This reminded me that I could just grab the code from MFC's CControlBar::PreTranslateMessage() and adapt it for use in the classes for my docking panes. Works great now!




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