public OnButtonGestureDefinition(
     DSL.Def.WhenFunc whenFunc,
     DSL.Def.AcceptableInOnClause onButton
     ) : base(whenFunc)
 {
     this.onButton = onButton;
 }
Beispiel #2
0
 public static Def.Event.IDoubleActionSet Convert(DSL.Def.AcceptableInOnClause onButton)
 {
     if (onButton is DSL.Def.LeftButton)
     {
         return(Def.Constant.LeftButtonDown);
     }
     else if (onButton is DSL.Def.MiddleButton)
     {
         return(Def.Constant.MiddleButtonDown);
     }
     else if (onButton is DSL.Def.RightButton)
     {
         return(Def.Constant.RightButtonDown);
     }
     else if (onButton is DSL.Def.X1Button)
     {
         return(Def.Constant.X1ButtonDown);
     }
     else if (onButton is DSL.Def.X2Button)
     {
         return(Def.Constant.X2ButtonDown);
     }
     else
     {
         throw new ArgumentException();
     }
 }
 public OnButtonWithIfStrokeGestureDefinition(
     DSL.Def.WhenFunc whenFunc,
     DSL.Def.AcceptableInOnClause onButton,
     Def.Stroke stroke,
     DSL.Def.DoFunc doFunc
     ) : base(whenFunc, onButton)
 {
     this.stroke = stroke;
     this.doFunc = doFunc;
 }
 public OnButtonWithIfButtonGestureDefinition(
     DSL.Def.WhenFunc whenFunc,
     DSL.Def.AcceptableInOnClause onButton,
     DSL.Def.AcceptableInIfButtonClause ifButton,
     DSL.Def.BeforeFunc beforeFunc,
     DSL.Def.DoFunc doFunc,
     DSL.Def.AfterFunc afterFunc
     ) : base(whenFunc, onButton)
 {
     this.ifButton   = ifButton;
     this.beforeFunc = beforeFunc;
     this.doFunc     = doFunc;
     this.afterFunc  = afterFunc;
 }