rlm@1: //////////////////////////////////////////////////////////////////////////////// rlm@1: // Copyright (C) 1998 by Thierry Maurel rlm@1: // All rights reserved rlm@1: // rlm@1: // Distribute freely, except: don't remove my name from the source or rlm@1: // documentation (don't take credit for my work), mark your changes (don't rlm@1: // get me blamed for your possible bugs), don't alter or remove this rlm@1: // notice. rlm@1: // No warrantee of any kind, express or implied, is included with this rlm@1: // software; use at your own risk, responsibility for damages (if any) to rlm@1: // anyone resulting from the use of this software rests entirely with the rlm@1: // user. rlm@1: // rlm@1: // Send bug reports, bug fixes, enhancements, requests, flames, etc., and rlm@1: // I'll try to keep a version up to date. I can be reached as follows: rlm@1: // tmaurel@caramail.com (or tmaurel@hol.fr) rlm@1: // rlm@1: //////////////////////////////////////////////////////////////////////////////// rlm@1: // File : KeyboardEdit.h rlm@1: // Project : AccelsEditor rlm@1: //////////////////////////////////////////////////////////////////////////////// rlm@1: // Version : 1.0 * Authors : A.Lebatard + T.Maurel rlm@1: // Date : 17.08.98 rlm@1: // rlm@1: // Remarks : rlm@1: // rlm@1: //////////////////////////////////////////////////////////////////////////////// rlm@1: // Modified by the VBA-rr Team rlm@1: rlm@1: #if !defined(AFX_KEYBOARDEDIT_H__88E35AB0_2E23_11D2_BA24_0060B0B5E151__INCLUDED_) rlm@1: #define AFX_KEYBOARDEDIT_H__88E35AB0_2E23_11D2_BA24_0060B0B5E151__INCLUDED_ rlm@1: rlm@1: #if _MSC_VER >= 1000 rlm@1: #pragma once rlm@1: #endif // _MSC_VER >= 1000 rlm@1: // KeyboardEdit.h : header file rlm@1: // rlm@1: rlm@1: ///////////////////////////////////////////////////////////////////////////// rlm@1: // CKeyboardEdit window rlm@1: rlm@1: class CKeyboardEdit : public CEdit rlm@1: { rlm@1: DECLARE_DYNAMIC(CKeyboardEdit) // what will this do? rlm@1: rlm@1: // Construction rlm@1: public: rlm@1: CKeyboardEdit(); rlm@1: rlm@1: // Operations rlm@1: public: rlm@1: void ResetKey(); rlm@1: void AllKeyUp(); rlm@1: bool GetAccelKey(WORD &wVirtKey, bool &bCtrl, bool &bAlt, bool &bShift) const; rlm@1: bool GetJamKey(WORD &wJamKey) const; rlm@1: bool IsDefined() const; rlm@1: bool IsFinished() const; rlm@1: rlm@1: // Overrides rlm@1: // ClassWizard generated virtual function overrides rlm@1: //{{AFX_VIRTUAL(CKeyboardEdit) rlm@1: public: rlm@1: virtual BOOL PreTranslateMessage(MSG *pMsg); rlm@1: virtual ~CKeyboardEdit(); rlm@1: //}}AFX_VIRTUAL rlm@1: rlm@1: protected: rlm@1: void DisplayKeyboardString(); rlm@1: rlm@1: // Attributes rlm@1: protected: rlm@1: BYTE m_keys[256]; rlm@1: bool m_bForceUpdate; rlm@1: bool m_bCtrlPressed; rlm@1: bool m_bAltPressed; rlm@1: bool m_bShiftPressed; rlm@1: WORD m_wVirtKey; rlm@1: WORD m_wJamKey; rlm@1: rlm@1: // Generated message map functions rlm@1: public: rlm@1: //{{AFX_MSG(CKeyboardEdit) rlm@1: afx_msg BOOL OnEnChange(); rlm@1: afx_msg BOOL OnEnSetfocus(); rlm@1: afx_msg BOOL OnEnKillfocus(); rlm@1: //}}AFX_MSG rlm@1: rlm@1: DECLARE_MESSAGE_MAP() rlm@1: }; rlm@1: rlm@1: ///////////////////////////////////////////////////////////////////////////// rlm@1: rlm@1: //{{AFX_INSERT_LOCATION}} rlm@1: // Microsoft Developer Studio will insert additional declarations immediately before the previous line. rlm@1: rlm@1: #endif // !defined(AFX_KEYBOARDEDIT_H__88E35AB0_2E23_11D2_BA24_0060B0B5E151__INCLUDED_)