如何打开左键单击上下文菜单wpf mvvm。 [英] How to open context menu in left click throw wpf mvvm.

查看:124
本文介绍了如何打开左键单击上下文菜单wpf mvvm。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在左键单击打开上下文菜单wpf mvvm?

告诉我这个场景的解决方案:

当用户右键单击按钮的上下文菜单进行某些操作时正在工作,但现在我需要同样的过程做左侧click.how将使用wpf mvvm设计模式。



请帮助我...

How to open context menu in left click throw wpf mvvm?
tell me a solution to this scenario:
when user right click context menu of button doing some operation is working but now i need same process doing left click.how will do using wpf mvvm design pattern.

please help me ...

推荐答案

您可以处理该按钮的MouseLeftButtonDown事件,您可以在该事件中创建自定义上下文菜单。



请参阅以下链接供更多参考。

[ ^ ]
You can handle the MouseLeftButtonDown event for that button and You can create your custom context menu in that event.

see below link for more reference.
[^]


这篇关于如何打开左键单击上下文菜单wpf mvvm。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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