Motion detected event arguments class.
Inheritance: System.EventArgs
Example #1
0
        /// <summary>
        /// Raises the motion detection state changed event.
        /// </summary>
        /// <param name="e">
        /// The event arguments.
        /// </param>
        protected virtual void OnMotionDetectionStateChanged(MotionDetectedEventArgs e)
        {
            if (e.MotionDetected)
            {
                this._lastMotion = DateTime.Now;
            }
            else
            {
                this._lastInactive = DateTime.Now;
            }

            if (this.MotionDetectionStateChanged != null)
            {
                this.MotionDetectionStateChanged(this, e);
            }
        }
Example #2
0
		/// <summary>
		/// Raises the motion detection state changed event.
		/// </summary>
		/// <param name="e">
		/// The event arguments.
		/// </param>
		protected virtual void OnMotionDetectionStateChanged(MotionDetectedEventArgs e) {
			if (e.MotionDetected) {
				this._lastMotion = DateTime.Now;
			}
			else {
				this._lastInactive = DateTime.Now;
			}

			if (this.MotionDetectionStateChanged != null) {
				this.MotionDetectionStateChanged(this, e);
			}
		}