So i have a design problem. I have a mouse class that has delegates and events. ie MouseButtonPressed, MouseMoved. and such that are getting called by a state engine.
What i want to have happen is to create an interface like IClickable or IDraggable or somthing and have events inside those interfaces that get called when the mouse event gets called.
public interface IClickable
public event MouseDevice.ButtonClickedHandler<MouseButtons, MouseState> Clicked;
then in the MouseDevice class it has
public delegate void ButtonClickedHandler<O, S>(object sender, InputDeviceEventArgs<O, S> e);
and
public event ButtonClickedHandler<MouseButtons, MouseState> ButtonClicked;
So basically I want to have Clicked be called when buttonClicked gets called.
Is there a way to do this?