summaryrefslogtreecommitdiff
path: root/win/Mainfrm.cpp
diff options
context:
space:
mode:
authorleo2005-03-16 19:46:14 +0000
committerleo2005-03-16 19:46:14 +0000
commitc8951a1853dfd43aeb43394b9fa1682c3f0db743 (patch)
treeeb812de57f7c0073052549b3fc90d17a2e5f85c3 /win/Mainfrm.cpp
parent25af63d7d7b85f99f5327d1b97a3ac24fbfd93f0 (diff)
Fixed units in the modify dialog;
Disabled all shortcut keys when the user is entering text. git-svn-id: http://svn.leocad.org/trunk@392 c7d43263-9d01-0410-8a33-9dba5d9f93d6
Diffstat (limited to 'win/Mainfrm.cpp')
-rw-r--r--win/Mainfrm.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/win/Mainfrm.cpp b/win/Mainfrm.cpp
index dba878f..2c0ad18 100644
--- a/win/Mainfrm.cpp
+++ b/win/Mainfrm.cpp
@@ -1113,6 +1113,22 @@ BOOL CMainFrame::PreTranslateMessage(MSG* pMsg)
bool Shift = GetKeyState(VK_SHIFT) < 0;
// Don't process key presses if the user is typing text.
+ if (!Control)
+ {
+ if (m_wndPiecesBar.m_wndPiecesCombo.IsChild(GetFocus()) ||
+ m_wndPiecesBar.m_wndPiecesList.IsChild(GetFocus()))
+ {
+ return CFrameWnd::PreTranslateMessage(pMsg);
+ }
+
+ char Name[256];
+ GetClassName(GetFocus()->m_hWnd, Name, sizeof(Name));
+ if (!strcmp(Name, "Edit"))
+ {
+ return CFrameWnd::PreTranslateMessage(pMsg);
+ }
+ }
+
if (m_wndPiecesBar.m_wndPiecesCombo.IsChild(GetFocus()) ||
m_wndPiecesBar.m_wndPiecesList.IsChild(GetFocus()))
{