/// <summary>Builds a touch state from the current touches</summary>
        /// <returns>The currently mocked touches in a touch state</returns>
        private TouchState buildState()
        {
            var state = new TouchState(this.isAttached, this.touchCollection);

            TouchCollectionHelper.Clear(ref this.touchCollection);
            return(state);
        }
Example #2
0
        public void TestClear()
        {
            var touches = new TouchCollection();

            TouchCollectionHelper.SetLocationCount(ref touches, 3);
            TouchCollectionHelper.Clear(ref touches);

            Assert.AreEqual(0, touches.Count);
        }