Exemplo n.º 1
0
 /// <summary>
 /// The constructor.
 /// </summary>
 /// <param name="state">The state of the gesture</param>
 internal PanGesture(Gesture.StateType state) : this(Interop.PanGestureDetector.PanGesture_New((int)state), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 2
0
 public RotationGesture(Gesture.StateType state) : this(Interop.RotationGesture.new_RotationGesture__SWIG_0((int)state), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 3
0
        public void GestureState()
        {
            tlog.Debug(tag, $"GestureState START");
            try
            {
                var longPressGesture = new LongPressGesture(Gesture.StateType.Cancelled);
                Assert.IsNotNull(longPressGesture, "Can't create success object LongPressGesture");
                var gesture = new Gesture(longPressGesture);
                Assert.IsNotNull(gesture, "Can't create success object Gesture");
                Assert.IsInstanceOf <Gesture>(gesture, "Should be an instance of Gesture type.");
                Gesture.StateType state = gesture.State;
                Assert.AreEqual(Gesture.StateType.Cancelled, state, "Should be same value");

                gesture.Dispose();
                longPressGesture.Dispose();
            }
            catch (Exception e)
            {
                Tizen.Log.Error(tag, "Caught Exception" + e.ToString());

                Assert.Fail("Caught Exception" + e.ToString());
            }
            tlog.Debug(tag, $"GestureState END (OK)");
            Assert.Pass("GestureState");
        }
Exemplo n.º 4
0
 /// <summary>
 /// The constructor.
 /// </summary>
 /// <param name="state">The state of the gesture</param>
 /// <since_tizen> 3 </since_tizen>
 public LongPressGesture(Gesture.StateType state) : this(NDalicPINVOKE.new_LongPressGesture__SWIG_0((int)state), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 5
0
 /// <summary>
 /// The constructor.
 /// </summary>
 /// <param name="state">The state of the gesture</param>
 internal PanGesture(Gesture.StateType state) : this(NDalicPINVOKE.new_PanGesture__SWIG_1((int)state), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 6
0
 public PinchGesture(Gesture.StateType state) : this(Interop.PinchGesture.New((int)state), true)
 {
     if (NDalicPINVOKE.SWIGPendingException.Pending)
     {
         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
     }
 }
Exemplo n.º 7
0
        public void RotationGestureLocalCenterPoint()
        {
            tlog.Debug(tag, $"RotationGestureLocalCenterPoint START");
            Gesture.StateType state = Gesture.StateType.Finished;
            RotationGesture   a1    = new RotationGesture(state);

            Vector2 v1 = a1.LocalCenterPoint;

            tlog.Debug(tag, $"RotationGestureLocalCenterPoint END (OK)");
            Assert.Pass("RotationGestureLocalCenterPoint");
        }
Exemplo n.º 8
0
        public void RotationGestureConstructor()
        {
            tlog.Debug(tag, $"RotationGestureConstructor START");

            Gesture.StateType state = Gesture.StateType.Finished;
            RotationGesture   a2    = new RotationGesture(state);

            a2.Dispose();
            tlog.Debug(tag, $"RotationGestureConstructor END (OK)");
            Assert.Pass("RotationGesture");
        }
Exemplo n.º 9
0
        public void RotationGestureGetRotationGestureFromPtr()
        {
            tlog.Debug(tag, $"RotationGestureGetRotationGestureFromPtr START");
            Gesture.StateType state = Gesture.StateType.Finished;
            RotationGesture   a2    = new RotationGesture(state);
            RotationGesture   a1    = RotationGesture.GetRotationGestureFromPtr(RotationGesture.getCPtr(a2).Handle);

            a2.Dispose();
            tlog.Debug(tag, $"RotationGestureGetRotationGestureFromPtr END (OK)");
            Assert.Pass("RotationGestureGetRotationGestureFromPtr");
        }
Exemplo n.º 10
0
        public void RotationGesturegetCPtr()
        {
            tlog.Debug(tag, $"RotationGesturegetCPtr START");
            Gesture.StateType state = Gesture.StateType.Finished;
            RotationGesture   a1    = new RotationGesture(state);

            global::System.Runtime.InteropServices.HandleRef r1 = RotationGesture.getCPtr(a1);

            tlog.Debug(tag, $"RotationGesturegetCPtr END (OK)");
            Assert.Pass("RotationGesturegetCPtr");
        }
Exemplo n.º 11
0
        public void PinchGestureScreenCenterPoint()
        {
            tlog.Debug(tag, $"PinchGestureScreenCenterPoint START");
            Gesture.StateType state = Gesture.StateType.Finished;
            PinchGesture      a1    = new PinchGesture(state);

            Vector2 v1 = a1.ScreenCenterPoint;

            tlog.Debug(tag, $"PinchGestureScreenCenterPoint END (OK)");
            Assert.Pass("ScreenCenterPoint");
        }
Exemplo n.º 12
0
        public void PinchGestureSpeed()
        {
            tlog.Debug(tag, $"PinchGestureSpeed START");
            Gesture.StateType state = Gesture.StateType.Finished;
            PinchGesture      a1    = new PinchGesture(state);

            float f1 = a1.Speed;

            tlog.Debug(tag, $"PinchGestureSpeed END (OK)");
            Assert.Pass("PinchGestureSpeed");
        }
Exemplo n.º 13
0
        public void RotationGestureRotation()
        {
            tlog.Debug(tag, $"RotationGestureRotation START");
            Gesture.StateType state = Gesture.StateType.Finished;
            RotationGesture   a1    = new RotationGesture(state);

            float f1 = a1.Rotation;

            tlog.Debug(tag, $"RotationGestureRotation END (OK)");
            Assert.Pass("RotationGestureRotation");
        }
Exemplo n.º 14
0
        public void LongPressGestureNumberOfTouches()
        {
            tlog.Debug(tag, $"LongPressGestureNumberOfTouches START");
            Gesture.StateType state = Gesture.StateType.Finished;
            LongPressGesture  ret1  = new LongPressGesture(state);

            uint num = ret1.NumberOfTouches;

            tlog.Debug(tag, $"LongPressGestureNumberOfTouches END (OK)");
            Assert.Pass("LongPressGestureNumberOfTouches");
        }
Exemplo n.º 15
0
        public void LongPressGestureConstructor()
        {
            tlog.Debug(tag, $"LongPressGestureConstructor START");
            Gesture.StateType state = Gesture.StateType.Finished;
            LongPressGesture  ret1  = new LongPressGesture(state);

            ret1.Dispose();

            tlog.Debug(tag, $"LongPressGestureConstructor END (OK)");
            Assert.Pass("LongPressGestureConstructor");
        }
Exemplo n.º 16
0
        public void LongPressGesturegetCPtr()
        {
            tlog.Debug(tag, $"LongPressGesturegetCPtr START");
            Gesture.StateType state = Gesture.StateType.Finished;
            LongPressGesture  ret1  = new LongPressGesture(state);

            global::System.Runtime.InteropServices.HandleRef a = LongPressGesture.getCPtr(ret1);

            tlog.Debug(tag, $"LongPressGesturegetCPtr END (OK)");
            Assert.Pass("LongPressGestureLocalPoint");
        }
Exemplo n.º 17
0
        public void PinchGestureConstructor()
        {
            tlog.Debug(tag, $"PinchGestureConstructor START");

            Gesture.StateType state = Gesture.StateType.Finished;
            PinchGesture      a2    = new PinchGesture(state);

            a2.Dispose();

            tlog.Debug(tag, $"PinchGestureConstructor END (OK)");
            Assert.Pass("PinchGestureConstructor");
        }
Exemplo n.º 18
0
        public void PinchGestureGetPinchGestureFromPtr()
        {
            tlog.Debug(tag, $"PinchGestureGetPinchGestureFromPtr START");

            Gesture.StateType state = Gesture.StateType.Finished;
            PinchGesture      a2    = new PinchGesture(state);

            PinchGesture a1 = PinchGesture.GetPinchGestureFromPtr(PinchGesture.getCPtr(a2).Handle);

            a2.Dispose();
            tlog.Debug(tag, $"PinchGestureGetPinchGestureFromPtr END (OK)");
            Assert.Pass("PinchGestureGetPinchGestureFromPtr");
        }
Exemplo n.º 19
0
        public void LongPressGestureLocalPoint()
        {
            tlog.Debug(tag, $"LongPressGestureLocalPoint START");
            Gesture.StateType state = Gesture.StateType.Finished;
            LongPressGesture  ret1  = new LongPressGesture(state);

            Vector2 v = ret1.LocalPoint;

            ret1.Dispose();

            tlog.Debug(tag, $"LongPressGestureLocalPoint END (OK)");
            Assert.Pass("LongPressGestureLocalPoint");
        }
Exemplo n.º 20
0
        public void LongPressGestureGetLongPressGestureFromPtr()
        {
            tlog.Debug(tag, $"LongPressGestureGetLongPressGestureFromPtr START");
            Gesture.StateType state = Gesture.StateType.Finished;
            LongPressGesture  ret1  = new LongPressGesture(state);

            LongPressGesture ret = LongPressGesture.GetLongPressGestureFromPtr(LongPressGesture.getCPtr(ret1).Handle);

            ret1.Dispose();
            ret.Dispose();


            tlog.Debug(tag, $"LongPressGestureGetLongPressGestureFromPtr END (OK)");
            Assert.Pass("LongPressGestureGetLongPressGestureFromPtr");
        }