예제 #1
0
        public void PagePanSignaEmpty()
        {
            tlog.Debug(tag, $"PagePanSignaEmpty START");

            using (View view = new View())
            {
                view.Size            = new Size(20, 40);
                view.BackgroundColor = Color.Cyan;

                var testingTarget = new PagePanSignal(view.SwigCPtr.Handle, false);
                Assert.IsNotNull(testingTarget, "Should be not null!");
                Assert.IsInstanceOf <PagePanSignal>(testingTarget, "Should be an Instance of PagePanSignal!");

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

                testingTarget.Dispose();
            }

            tlog.Debug(tag, $"PagePanSignaEmpty END (OK)");
        }
예제 #2
0
        public void PagePanSignalEmit()
        {
            tlog.Debug(tag, $"PagePanSignalEmit 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}");

            using (View view = new View())
            {
                var testingTarget = new PagePanSignal();
                Assert.IsNotNull(testingTarget, "Should be not null!");
                Assert.IsInstanceOf <PagePanSignal>(testingTarget, "Should be an Instance of PagePanSignal!");

                try
                {
                    testingTarget.Emit(new PageTurnView(view.SwigCPtr.Handle, false));
                }
                catch (Exception e)
                {
                    tlog.Debug(tag, e.Message.ToString());
                    Assert.Fail("Caught Exception: Failed!");
                }

                testingTarget.Dispose();
            }

            tlog.Debug(tag, $"PagePanSignalEmit END (OK)");
        }
예제 #3
0
        public void PagePanSignaConnect()
        {
            tlog.Debug(tag, $"PagePanSignaConnect START");

            var testingTarget = new PagePanSignal();

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

            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, $"PagePanSignaConnect END (OK)");
        }
예제 #4
0
        public void PagePanSignalConstructor()
        {
            tlog.Debug(tag, $"PagePanSignalConstructor START");

            using (View view = new View())
            {
                view.Size            = new Size(20, 40);
                view.BackgroundColor = Color.Cyan;

                var testingTarget = new PagePanSignal(view.SwigCPtr.Handle, false);
                Assert.IsNotNull(testingTarget, "Should be not null!");
                Assert.IsInstanceOf <PagePanSignal>(testingTarget, "Should be an Instance of PagePanSignal!");

                testingTarget.Dispose();
            }

            tlog.Debug(tag, $"PagePanSignalConstructor END (OK)");
        }
예제 #5
0
 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PagePanSignal obj)
 {
     return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr);
 }