Exemple #1
0
 public Transform(
     BeginHandler Begin               = null,
     EndHandler End                   = null,
     IEnumerable <IField> Fields      = null,
     UnknownFieldHandler UnknownField = null,
     BaseHandler Base                 = null,
     UnknownEndHandler UnknownEnd     = null)
 {
     begin        = Begin;
     end          = End;
     base_        = Base;
     unknownEnd   = UnknownEnd;
     fields       = Fields ?? new IField[0];
     unknownField = UnknownField;
 }
        private void SetUpTree(string root)
        {
            if (!Directory.Exists(root))
            {
                throw new DirectoryNotFoundException(root);
            }

            var rootDirInfo = new DirectoryInfo(root);

            StartHandler?.Invoke(this, EventArgs.Empty);
            _searchIsStopped = false;
            VisitFolder(rootDirInfo, null);
            _searchIsStopped = true;
            EndHandler?.Invoke(this, EventArgs.Empty);
        }
Exemple #3
0
 public Transform(
     BeginHandler Begin = null,
     EndHandler End = null,
     IEnumerable<IField> Fields = null,
     UnknownFieldHandler UnknownField = null,
     BaseHandler Base = null,
     UnknownEndHandler UnknownEnd = null)
 {
     begin = Begin;
     end = End;
     base_ = Base;
     unknownEnd = UnknownEnd;
     fields = Fields ?? new IField[0];
     unknownField = UnknownField;
 }
Exemple #4
0
 MyForm()
 {
     Text = "NetDraw";
     try {
         RemotingConfiguration.Configure("NetDraw.exe.config");
         VirtualPaper              = new Paper();
         VirtualPaper.NewSegment  += (SH = new SegmentHandler(OnNewSegment));
         VirtualPaper.LastSegment += (EH = new EndHandler(OnLastSegment));
         VirtualPaper.ClearAll    += (CH = new ClearHandler(OnClear));
     }
     catch (Exception ex) {
         MessageBox.Show(ex.Message);
         Close();
     }
     strokes = VirtualPaper.GetStrokes();
 }
        /// <summary>
        /// Function used to set an action to take place once the animation has concluded.
        /// </summary>
        /// <param name="ToCallAtEndOfAnimation"> Any function or delegate.</param>
        public void SetEndAction(EndHandler ToCallAtEndOfAnimation)
        {
            switch (kindOfAnimation)
            {
            case VariableToAnimate.floatValue:
                singleValueTweener.Ended += ToCallAtEndOfAnimation;
                break;

            case VariableToAnimate.Vector2Value:
                vectorTwoTweener.Ended += ToCallAtEndOfAnimation;
                break;

            case VariableToAnimate.Vector3Value:
                vector3Tweener.Ended += ToCallAtEndOfAnimation;
                break;

            default:
                vector3Tweener.Ended += ToCallAtEndOfAnimation;
                break;
            }
        }
 public int RandomOne(EndHandler OnEnd)
 {
     this.OnEnd = OnEnd;
     return(RandomOne());
 }
 /// <summary>
 /// Function used to set an action to take place once the animation has concluded.
 /// </summary>
 /// <param name="ToCallAtEndOfAnimation"> Any function or delegate.</param>
 public void SetEndAction(EndHandler ToCallAtEndOfAnimation)
 {
     switch (kindOfAnimation)
     {
         case VariableToAnimate.floatValue:
             singleValueTweener.Ended += ToCallAtEndOfAnimation;
             break;
         case VariableToAnimate.Vector2Value:
             vectorTwoTweener.Ended += ToCallAtEndOfAnimation;
             break;
         case VariableToAnimate.Vector3Value:
             vector3Tweener.Ended += ToCallAtEndOfAnimation;
             break;
         default:
             vector3Tweener.Ended += ToCallAtEndOfAnimation;
             break;
     }
 }