Reputation: 299
I have a controller that needs to capture some events(MouseMove, MouseDown, KeyDown, ...) raised by a control(this control could be WinForms, WPF or Silverlight). Is there a way to implement such a general controller?
*added by ChrisBD *
Background: I have a MVC application and I have a controller(GeneralController) that has acces to IGeneralControl. This IGeneralControl will be implemented by a WPF, WF and Silverlight specific control(WFControl, WPFControl, SilverlightControl). What I want to achieve is to be able to add my code to the delegates of the control at the level of the GeneralController, without the need to implemet WFController, WPFController and SilverlightController
Upvotes: 1
Views: 176
Reputation: 21241
I'm no forms expert but I'm skepical that you can do this with some works for all GeneralController. WPF/Silverlight use a very different event model, using staticly declared routed events.
I think you'd need to implement your WFController and a separate WPF/Silverlight controller.
Upvotes: 1