I can expose ICommands from my ViewModels but where does Non-Click/Command behaviour fit开发者_StackOverflow社区 into a MVVM Application? eg. Drag & Drop, Hover etc
Have a look at this post:
http://blogs.imeta.co.uk/jyoung/archive/2009/07/21/728.aspx
Shows how you can still use the MVVM pattern effectively for "Non-Click / Command" behaviour such as drag / drop.
I would place them in the code-behind because this is UI behaviour, I don't know if it's "right" but I think you shouldn't overcomplicate such easy things.
精彩评论