日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程语言 > c/c++ >内容正文

c/c++

Visual C++ 2011-5-27

發布時間:2025/6/17 c/c++ 19 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Visual C++ 2011-5-27 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

?

一.命令消息

有兩個命令

1.WM_SYSCOMMAND

這個命令與本身程序有關,如最小化窗體,關閉窗體等

2.WM_APPCOMMAND

這個命令可以控制操作系統本身的很多功能,如打開瀏覽器,郵箱,調節音量等.

使用非常簡單,無須額外的處理

SendMessage(hwnd,WM_APPCOMMAND, (WPARAM)hwnd, MAKELPARAM(0x0000, APPCOMMAND_VOLUME_UP));

二.SHDeleteKey,RegDeleteKey

Deletes a subkey and all its descendants. The function will remove the key and all of the key's values from the registry.

發現SH開頭的函數都是那么的方便

RegDeleteKey

Deletes a subkey and its values.

三.GetWindowThreadProcessId

獲取創建該窗體線程的進程

//獲得應用程序指針 CDemoApp* pApp = (CDemoApp*)AfxGetApp(); //獲得主窗口指針 CWnd* pMainWnd = pApp->m_pMainWnd; DWORD word=::GetCurrentProcessId(); DWORD pword; GetWindowThreadProcessId(pMainWnd->GetSafeHwnd(),&pword); ASSERT(word==pword);

四.SendMessageTimeout

If the specified window was created by the calling thread, the window procedure is called immediately as a subroutine. If the specified window was created by a different thread, the system switches to that thread and calls the appropriate window procedure. Messages sent between threads are processed only when the receiving thread executes message retrieval code. The sending thread is blocked until the receiving thread processes the message. However, the sending thread will process incoming nonqueued messages while waiting for its message to be processed. To prevent this, use SendMessageTimeout with SMTO_BLOCK set.

五.LoadImage && CopyImage

Loads an icon, cursor, animated cursor, or bitmap.

wndclass.hIcon=LoadImage(hInstance,MAKEINTRESOURCE (IDI_ICON),IMAGE_ICON,32,32,LR_DEFAULTCOLOR);//wndclass.hIcon = LoadIcon (hInstance, MAKEINTRESOURCE (IDI_ICON)) ;

可以理解為LoadImage為LoadIcon、LoadCursor、LoadBitmap的一個全局函數,但是銷毀資源時候還是需要用到DestoryIcon,DestoryCursor等

HANDLE CopyImage( HANDLE hImage,UINT uType,int cxDesired,int cyDesired,UINT fuFlags );

同理CopyImage也可以復制原有的Icon、Cursor、Bitmap等資源

六.GetInputState

The GetInputState function determines whether there are mouse-button or keyboard messages in the calling thread's message queue.

七.SendInput

The SendInput function synthesizes keystrokes, mouse motions, and button clicks.

http://baike.baidu.com/view/3638567.htm

模擬鼠標,鍵盤事件

八.AttachThreadInput

Windows created in different threads typically process input independently of each other. That is, they have their own input states (focus, active, capture windows, key state, queue status, and so on), and they are not synchronized with the input processing of other threads. By using the AttachThreadInput function, a thread can attach its input processing to another thread. This also allows threads to share their input states, so they can call the SetFocus function to set the keyboard focus to a window of a different thread. This also allows threads to get key-state information. These capabilities are not generally possible.

轉載于:https://www.cnblogs.com/Clingingboy/archive/2011/06/06/2073611.html

《新程序員》:云原生和全面數字化實踐50位技術專家共同創作,文字、視頻、音頻交互閱讀

總結

以上是生活随笔為你收集整理的Visual C++ 2011-5-27的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。

主站蜘蛛池模板: 日本不卡一区二区三区 | 久久久www成人免费无遮挡大片 | 日本精品久久久久 | 免费萌白酱国产一区二区三区 | 粉嫩av网站 | 黄色免费网页 | 久久精品国产亚洲7777 | 国产精品美女www爽爽爽视频 | 日韩专区在线观看 | 亚洲免费精品视频 | 亚洲成年网 | 久久综合高清 | 亚洲免费视频一区二区三区 | 97综合视频 | 福利视频亚洲 | 日韩插插 | 日韩三区视频 | 亚洲拍拍视频 | av美女在线观看 | 极品美女开粉嫩精品 | 国产精品300页 | 五月激情综合婷婷 | a毛片网站 | 国语对白做受按摩的注意事项 | 久草成人 | 天天黄色片 | 男人用嘴添女人下身免费视频 | 国产精品无码专区av免费播放 | 狠狠摸狠狠操 | 亚洲乱码av | 国产午夜一区二区三区 | av网站在线观看不卡 | av大片网 | 久久久久久久久综合 | 激情超碰在线 | 性感美女一级片 | 综合色视频 | 欧美又粗又大xxxxbbbb疯狂 | 久久精品国产99国产精品 | 亚洲精华液一区二区 | 在线观看黄色片 | missav | 免费高清av在线看 | 亚洲精品在线观看免费 | 中国女人毛茸茸 | 天海翼av在线播放 | 国产精品久久久久久久久 | 国产中文字幕二区 | 制服丝袜在线看 | 欧美国产三级 | 精品区一区二区 | 亚洲av无码成人精品国产 | 日韩在线视频网站 | 久久无码高潮喷水 | 国产精品自在线 | 最新中文字幕在线播放 | 国产又粗又黄又爽视频 | 成年人毛片视频 | 一本大道久久久久精品嫩草 | 国内av片| 久久久青青草 | 欧美少妇一区二区 | 性生交大全免费看 | 亚洲手机在线观看 | 免费成人在线观看视频 | 午夜视频在线网站 | 奇米影视第四色888 免费观看a毛片 | 麻豆国产一区二区三区四区 | 午夜簧片 | 老司机在线精品视频 | 美女视频污| 亚洲综合国产精品 | 午夜福利理论片在线观看 | 人人干人人看 | 一本久道综合色婷婷五月 | 72种无遮挡啪啪的姿势 | 天天干天天操天天射 | 国产精品久久久久久无人区 | 五月天婷婷久久 | 免费在线观看成年人视频 | 日韩美女一区二区三区 | 中国国产bdsm紧缚捆绑 | 久久高清av | 国产精品国产一区二区三区四区 | 日韩精品一区二区三区在线 | 天天摸天天操天天射 | 成人久久国产 | 日韩成人在线免费观看 | 尤物av在线 | 国产伦精品一区三区精东 | 噜噜噜久久,亚洲精品国产品 | 永久av在线免费观看 | 少妇激情一区二区三区视频 | 欧美h视频在线观看 | 无码精品a∨在线观看中文 福利片av | 亚洲欧美一区二区三区 | 国产夫妻久久 | 国产日韩精品一区二区 | 国产成人欧美一区二区三区91 | 在线日韩三级 |