Ejemplo n.º 1
0
 public virtual void InitializeEvents(IVidgetEventSink eventsink)
 {
     EventSink = eventsink;
     Widget.ComposeEvents(EventSink);
 }
Ejemplo n.º 2
0
 public static void ComposeEvents(this Widget Widget, IVidgetEventSink EventSink)
 {
     Widget.GotFocus       += (s, e) => EventSink?.OnEvent(nameof(IVidget.GotFocus), new EventArgs());
     Widget.ButtonReleased += (s, e) => EventSink?.OnEvent(nameof(IVidget.ButtonReleased), e.ToLmk());
 }
Ejemplo n.º 3
0
 public void InitializeEvents(IVidgetEventSink eventSink)
 {
     EventSink = eventSink;
 }
Ejemplo n.º 4
0
 public void InitializeEvents(IVidgetEventSink eventSink)
 {
     EventSink = eventSink;
     Control.ComposeEvents(EventSink);
 }
Ejemplo n.º 5
0
 public static void ComposeEvents(this Control Control, IVidgetEventSink EventSink)
 {
     Control.GotFocus += (s, e) => EventSink?.OnEvent(nameof(IVidget.GotFocus), new EventArgs());
     Control.Enter    += (s, e) => EventSink?.OnEvent(nameof(IVidget.GotFocus), new EventArgs());
     Control.MouseUp  += (s, e) => EventSink?.OnEvent(nameof(IVidget.ButtonReleased), Converter.Convert(e));
 }
Ejemplo n.º 6
0
 public virtual void InitializeEvents(IVidgetEventSink eventsink)
 {
     this.EventSink    = eventsink;
     Control.GotFocus += (s, e) => EventSink?.OnEvent(nameof(IVidget.GotFocus), new EventArgs());
     Control.MouseUp  += (s, e) => EventSink?.OnEvent(nameof(IVidget.ButtonReleased), WpfConverter.ToXwtButtonArgs((Control)s, e).ToLmk());
 }
Ejemplo n.º 7
0
 public void InitializeEvents(IVidgetEventSink eventSink)
 {
     EventSink                  = eventSink;
     Widget.FocusInEvent       += (s, e) => EventSink?.OnEvent(nameof(IVidget.GotFocus), new EventArgs());
     Widget.ButtonReleaseEvent += (s, e) => EventSink?.OnEvent(nameof(IVidget.ButtonReleased), e.ToXwt((Gtk.Widget)s).ToLmk());
 }