【文件属性】:
文件名称:C++视区窗口触摸屏消息捕获
文件大小:208KB
文件格式:RAR
更新时间:2021-06-13 17:20:59
触摸屏捕获
.在 Scratchpad.cpp 中,在 CScratchPadApp::InitInstance(): 后添加以下检查代码:
[cpp] view plain copy
1. BYTE digitizerStatus = (BYTE) GetSystemMetrics(SM_DIGITIZER);
2.
3. if ((digitizerStatus & (0x80 + 0x40)) == 0)
4. //堆栈就绪+多触点
5.
6. {
7.
8. AfxMessageBox(L"No touch input is currently available.");
9.
10. return false;
11.
12. }
13.
14.
15.
16. BYTE nInputs = (BYTE) GetSystemMetrics(SM_MAXIMUMTOUCHES);
17.
18.
19.
20. CString str;
21.
22. str.Format(L"Touch input available with %d touch points.", nInputs);
23.
24. AfxMessageBox(str);
25.
26.
27.
28. return true;
【文件预览】:
触摸捕获
----Scratchpad.sln(897B)
----Scratchpad()
--------ScratchpadDoc.h(871B)
--------stdafx.cpp(143B)
--------FileView.cpp(7KB)
--------Resource.h(3KB)
--------UserImages.bmp(8KB)
--------Scratchpad.aps(172KB)
--------res()
--------stdafx.h(2KB)
--------Scratchpad.vcxproj(8KB)
--------ViewTree.h(372B)
--------ScratchpadDoc.cpp(3KB)
--------ClassView.h(1KB)
--------Scratchpad.rc(36KB)
--------ChildFrm.cpp(894B)
--------targetver.h(234B)
--------ScratchpadView.h(2KB)
--------ScratchpadView.cpp(4KB)
--------FileView.h(1KB)
--------OutputWnd.cpp(5KB)
--------ClassView.cpp(9KB)
--------MainFrm.cpp(13KB)
--------Scratchpad.vcxproj.filters(6KB)
--------ViewTree.cpp(876B)
--------Scratchpad.h(737B)
--------MainFrm.h(1KB)
--------Scratchpad.cpp(6KB)
--------Scratchpad.reg(632B)
--------ChildFrm.h(483B)
--------Scratchpad.vcxproj.user(143B)
--------PropertiesWnd.h(1KB)
--------PropertiesWnd.cpp(8KB)
--------OutputWnd.h(1017B)
--------ReadMe.txt(4KB)