Exemplo n.º 1
0
        public void ScrollViewSnapStartedSignalConnect()
        {
            tlog.Debug(tag, $"ScrollViewSnapStartedSignalConnect START");

            var testingTarget = new ScrollViewSnapStartedSignal();

            Assert.IsNotNull(testingTarget, "Should be not null!");
            Assert.IsInstanceOf <ScrollViewSnapStartedSignal>(testingTarget, "Should be an Instance of ScrollViewSnapStartedSignal!");

            try
            {
                dummyCallback callback = OnDummyCallback;
                testingTarget.Connect(callback);
                testingTarget.Disconnect(callback);
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception: Failed!");
            }

            testingTarget.Dispose();

            tlog.Debug(tag, $"ScrollViewSnapStartedSignalConnect END (OK)");
        }
        public void ScrollViewSnapStartedSignalEmit()
        {
            tlog.Debug(tag, $"ScrollViewSnapStartedSignalEmit START");
            var currentPid = global::System.Diagnostics.Process.GetCurrentProcess().Id;
            var currentTid = global::System.Threading.Thread.CurrentThread.ManagedThreadId;

            tlog.Debug(tag, $"thread check! main pid={App.mainPid}, current pid={currentPid}, main tid={App.mainTid}, current tid={currentTid}");

            var testingTarget = new ScrollViewSnapStartedSignal();

            Assert.IsNotNull(testingTarget, "Should be not null!");
            Assert.IsInstanceOf <ScrollViewSnapStartedSignal>(testingTarget, "Should be an Instance of ScrollViewSnapStartedSignal!");

            try
            {
                testingTarget.Emit(new ScrollView.SnapEvent());
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception: Failed!");
            }

            testingTarget.Dispose();

            tlog.Debug(tag, $"ScrollViewSnapStartedSignalEmit END (OK)");
        }
Exemplo n.º 3
0
        public void ScrollViewSnapStartedSignalConstructor()
        {
            tlog.Debug(tag, $"ScrollViewSnapStartedSignalConstructor START");

            using (View view = new View())
            {
                var testingTarget = new ScrollViewSnapStartedSignal(view.SwigCPtr.Handle, false);
                Assert.IsNotNull(testingTarget, "Should be not null!");
                Assert.IsInstanceOf <ScrollViewSnapStartedSignal>(testingTarget, "Should be an ScrollViewSnapStartedSignal of WheelSignal!");

                testingTarget.Dispose();
            }

            tlog.Debug(tag, $"ScrollViewSnapStartedSignalConstructor END (OK)");
        }
Exemplo n.º 4
0
        public void ScrollViewSnapStartedSignalEmpty()
        {
            tlog.Debug(tag, $"ScrollViewSnapStartedSignalEmpty START");

            var testingTarget = new ScrollViewSnapStartedSignal();

            Assert.IsNotNull(testingTarget, "Should be not null!");
            Assert.IsInstanceOf <ScrollViewSnapStartedSignal>(testingTarget, "Should be an Instance of ScrollViewSnapStartedSignal!");

            try
            {
                testingTarget.Empty();
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception: Failed!");
            }

            testingTarget.Dispose();

            tlog.Debug(tag, $"ScrollViewSnapStartedSignalEmpty END (OK)");
        }
 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ScrollViewSnapStartedSignal obj)
 {
     return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr);
 }