WM_DRAWCLIPBOARD 监视剪切板
WM_DRAWCLIPBOARD 监视剪切板 第一步:Add the window to the clipboard viewer chain.
通过SetClipboardViewer()传入窗口句柄,所有监视剪贴板的窗口句柄会组成一个链表(后来者靠前)。这样当剪贴板内容发生变化时,Windows系统给给这些窗口发生消息。
第二步:Process the WM_CHANGECBCHAIN message.
当这个监视剪贴板的窗口句柄链表发生变化时,会收到这个消息。每个窗口都应该给下一个窗口传递消息。
这个消息的wParam和lParam说明如下:
wParam表示
A handle to the window being removedfrom the clipboard viewer chain
lParam表示
A handle to the next window in thechain following the window being removed. This parameter is NULL if thewindow being removed is the last window in the chain。
第三步:Process the WM_DRAWCLIPBOARD message.
当剪贴板数据发送变化时,窗口会依次收到这个消息。
第四步:Remove the window from the clipboard viewer chain before itis destroyed.
当窗口关闭时,应该调用ChangeClipboardChain()来通知Windows系统将自己从监视剪贴板的窗口句柄链表中移除。
查看评论 回复
"WM_DRAWCLIPBOARD 监视剪切板"的相关文章
- 上一篇:没有了
- 下一篇:处理WM_DRAWCLIPBOARD消息过程
热门文章
- 空格后面的作为标题 ___delphi___
- 要处理的文件总行数 ___delphi___
- function TrimString(str:string):string; ___delphi_
- 把要处理的文件装入到memo1_test中,启动处理定时器ti
- 读入的内容写到Memo1_Test显示出来,测试用 ___delphi_
- textarea不能使用以下方式 ___delphi___
- 随机发布文章到栏目类别 ___delphi___
- 用pos函数来判断,在下面这一行怎么会出错呢? ___del
- delphi什么函数能判断一个字符串包含在另一字符串 ___
- delphi怎样判断字符串包含指定字符 ___delphi___