WPF-ListViewItem拖放而不将背景突出显示为蓝色. [英] WPF - ListViewItem Drag-Drop without highlighting the background as blue.

查看:53
本文介绍了WPF-ListViewItem拖放而不将背景突出显示为蓝色.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我有一个启用了拖放功能的列表视图.我面临的问题是,开始拖动某个项目时,该项目的背景变为蓝色(默认情况下).有什么方法可以防止它发生(即背景应该保持透明).

谢谢.

Hi,

I have a listview with drag-drop feature enabled. The issue I am facing is that when drag is started for an item, the background of the item becomes blue (by default). Is there any way to prevent it from happening (i.e. the background should remain transparent).

Thanks

推荐答案

看看这篇文章; 在WPF ListView中拖放项目 [
Look at this article; Drag and Drop Items in a WPF ListView[^] in particular the section on styling the drag item.


如果您正在使用拖放控件 [ ^ ] ,然后只需查看样式以查看可能发生了什么变化.自定义样式并在您自己的代码中使用它.
If you are using the Drag Drop controls[^] from the toolkit, then simply have a look at the styles to see what might have changed. Customize the style and use it in your own code.


是的. thanx的家伙:)
Yeah..I got a work around[yayy]. thanx guys :)


这篇关于WPF-ListViewItem拖放而不将背景突出显示为蓝色.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆