Changeset 7353 for trunk/testapp


Ignore:
Timestamp:
Nov 16, 2001, 8:36:41 AM (24 years ago)
Author:
phaller
Message:

.

Location:
trunk/testapp
Files:
5 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/testapp/keyboard/OKeyHook/OKeyHook.cpp

    r7152 r7353  
    22//
    33
     4#include "stdafx.h"
    45#include "OKeyHook.h"
    56
     
    140141        DWORD dwExtra = GetMessageExtraInfo();
    141142
    142         // log the message
     143        // get the key's name
     144        CHAR szBufKey[40];
     145        GetKeyNameText(lParam, szBufKey, sizeof(szBufKey));
     146       
    143147        // log the message
    144148        CHAR szBuf[512];
    145149        wsprintf(szBuf,
    146                 "nCode=%08xh, wParam=%08xh, lParam=%08xh, extra=%08xh",
     150                "nCode=%08xh, wParam=%08xh, lParam=%08xh, extra=%08xh, name=%s",
    147151                nCode,
    148152                wParam,
    149153                lParam,
    150                 dwExtra);
     154                dwExtra,
     155                szBufKey);
    151156
    152157    pfnLogString("KeyHook", szBuf);
  • trunk/testapp/keyboard/OKeyHook/OKeyHook.h

    r7152 r7353  
    1 
    2 // Windows Header Files:
    3 #include <windows.h>
    4 
    5 // C RunTime Header Files
    6 #include <stdlib.h>
    7 #include <malloc.h>
    8 #include <memory.h>
    9 #include <tchar.h>
    101
    112// The following ifdef block is the standard way of creating macros which make exporting
  • trunk/testapp/keyboard/OKeyTest/OKeyTest.cpp

    r7152 r7353  
    245245                default: pszMsg = "unknown"; break;
    246246        }
     247
     248        // get key name
     249        CHAR szBufKey[40];
     250        GetKeyNameText(lParam, szBufKey, sizeof(szBufKey));
    247251       
    248         wsprintf(szBuf, "%08xh %16s (%08xh, %08xh)",
     252        wsprintf(szBuf, "%08xh %16s (%08xh, %08xh) name=[%s]",
    249253                hwnd,
    250254                pszMsg,
    251255                wParam,
    252                 lParam);
     256                lParam,
     257                szBufKey);
    253258
    254259        logString(lpstrOrigin, szBuf);
  • trunk/testapp/keyboard/OKeyTest/OKeyTest.h

    r7152 r7353  
    1 // Windows Header Files:
    2 #include <windows.h>
    3 
    4 // C RunTime Header Files
    5 #include <stdlib.h>
    6 #include <malloc.h>
    7 #include <memory.h>
    8 #include <tchar.h>
    9 
    101
    112#if !defined(AFX_OKEYTEST_H__05D06965_C6DD_11D5_B6AE_004854D1C794__INCLUDED_)
Note: See TracChangeset for help on using the changeset viewer.