示例#1
0
        public void Deactivate()
        {
            FocusManager.Instance.PreFocusChange -= onPreFocusChange;
            FocusManager.Instance.ClearFocus();

            flexibleView1.DetachScrollBar();
            scrollBar1.Dispose();
            scrollBar1 = null;
            flexibleView2.DetachScrollBar();
            scrollBar2.Dispose();
            scrollBar2 = null;

            parent.Remove(flexibleView1);
            flexibleView1.Dispose();
            flexibleView1 = null;
            parent.Remove(flexibleView2);
            flexibleView2.Dispose();
            flexibleView2 = null;

            root.Remove(parent);
            parent.Dispose();
            parent = null;

            NUIApplication.GetDefaultWindow().Remove(root);
            root.Dispose();
            root = null;
        }
示例#2
0
        public void FlexibleViewChildHelperRemoveViewAt()
        {
            tlog.Debug(tag, $"FlexibleViewChildHelperRemoveViewAt START");

            FlexibleView owner = new FlexibleView()
            {
                Padding = new Extents(10, 10, 10, 10),
            };

            var testingTarget = new FlexibleView.ChildHelper(owner);

            Assert.IsNotNull(testingTarget, "null handle");
            Assert.IsInstanceOf <FlexibleView.ChildHelper>(testingTarget, "Should return FlexibleView.ChildHelper instance.");

            View view = new View()
            {
                Size = new Size(100, 200),
            };
            FlexibleViewViewHolder holder = new FlexibleViewViewHolder(view);

            testingTarget.AttachView(holder, 0);
            var result = testingTarget.RemoveViewAt(0);

            tlog.Debug(tag, "RemoveViewAt : " + result);

            owner.Dispose();
            view.Dispose();
            testingTarget.Dispose();
            tlog.Debug(tag, $"FlexibleViewChildHelperRemoveViewAt END (OK)");
        }
示例#3
0
        public void Deactivate()
        {
            flexibleView1.DetachScrollBar();
            scrollBar1.Dispose();
            flexibleView2.DetachScrollBar();
            scrollBar2.Dispose();

            Window window = Window.Instance;

            window.Remove(flexibleView1);
            flexibleView1.Dispose();
            window.Remove(flexibleView2);
            flexibleView2.Dispose();
        }
示例#4
0
        public void Deactivate()
        {
            flexibleView1.DetachScrollBar();
            scrollBar1.Dispose();
            flexibleView2.DetachScrollBar();
            scrollBar2.Dispose();

            Window window = NUIApplication.GetDefaultWindow();

            window.Remove(flexibleView1);
            flexibleView1.Dispose();
            window.Remove(flexibleView2);
            flexibleView2.Dispose();
        }