I am developing one application which shows thumbnails of running application on windows 7. Can i achieve the same thumbnail functionality on window XP.(If I run my application on XP) If Yes. Then How can i achieve this. Any idea? Thanks
问问题
1127 次
1 回答
1
在 Windows 7 中,您可以使用桌面窗口管理器(DWM) 库(除其他外)来截取屏幕截图/缩略图。该文档是 Win API 的一部分,但您可以使用平台调用在 C3 中使用它们:
[DllImport( "dwmapi.dll", PreserveSig = false )]
public static extern void DwmRegisterThumbnail( IntPtr destinationWindowHandle, IntPtr sourceWindowHandle, out IntPtr thumbnailHandle );
[DllImport( "dwmapi.dll", PreserveSig = false )]
public static extern void DwmUnregisterThumbnail( IntPtr thumbnailHandle );
[DllImport( "dwmapi.dll", PreserveSig = false )]
public static extern void DwmUpdateThumbnailProperties( IntPtr thumbnailHandle, ref ThumbnailProperties properties );
最后,这里是一些关于如何实现实际缩略图的示例代码。
于 2013-07-16T19:25:51.200 回答