Esempio n. 1
0
        public void Deactivate()
        {
            if (root != null)
            {
                if (dropDown != null)
                {
                    if (scrollBar != null)
                    {
                        dropDown.DetachScrollBar();
                        scrollBar.Dispose();
                        scrollBar = null;
                    }

                    parent1.Remove(dropDown);
                    dropDown.Dispose();
                    dropDown = null;
                }
                if (dropDown2 != null)
                {
                    if (scrollBar2 != null)
                    {
                        dropDown2.DetachScrollBar();
                        scrollBar2.Dispose();
                        scrollBar2 = null;
                    }

                    parent2.Remove(dropDown2);
                    dropDown2.Dispose();
                    dropDown2 = null;
                }

                if (createText[0] != null)
                {
                    parent1.Remove(createText[0]);
                    createText[0].Dispose();
                    createText[0] = null;
                }
                if (createText[1] != null)
                {
                    parent2.Remove(createText[1]);
                    createText[1].Dispose();
                    createText[1] = null;
                }

                root.Remove(parent1);
                parent1.Dispose();
                parent1 = null;
                root.Remove(parent2);
                parent2.Dispose();
                parent2 = null;

                NUIApplication.GetDefaultWindow().Remove(root);
                root.Dispose();
                root = null;
            }
        }
Esempio n. 2
0
        public void Deactivate()
        {
            if (root != null)
            {
                if (dropDown != null)
                {
                    if (scrollBar != null)
                    {
                        dropDown.DetachScrollBar();
                        scrollBar.Dispose();
                        scrollBar = null;
                    }

                    root.Remove(dropDown);
                    dropDown.Dispose();
                    dropDown = null;
                }
                if (dropDown2 != null)
                {
                    if (scrollBar2 != null)
                    {
                        dropDown2.DetachScrollBar();
                        scrollBar2.Dispose();
                        scrollBar2 = null;
                    }

                    root.Remove(dropDown2);
                    dropDown2.Dispose();
                    dropDown2 = null;
                }

                if (createText[0] != null)
                {
                    root.Remove(createText[0]);
                    createText[0].Dispose();
                    createText[0] = null;
                }
                if (createText[1] != null)
                {
                    root.Remove(createText[1]);
                    createText[1].Dispose();
                    createText[1] = null;
                }

                Window.Instance.Remove(root);
                root.Dispose();
                root = null;
            }
        }