Exemplo n.º 1
0
        public virtual void IsSelectionActiveTest2()
        {
            IPoker   p        = CurrentControl;
            Selector selector = (Selector)p;

            selector.Items.Add(new object());
            selector.Items.Add(new object());
            selector.ApplyTemplate();

            CreateAsyncTest(selector, () => {
                Assert.IsFalse((bool)selector.GetValue(ListBox.IsSelectionActiveProperty), "#1");
                selector.Focus();
                Assert.IsFalse((bool)selector.GetValue(ListBox.IsSelectionActiveProperty), "#2");
                selector.SelectedIndex = 0;
                Assert.IsFalse((bool)selector.GetValue(ListBox.IsSelectionActiveProperty), "#2");
            });
        }