Example #1
0
        private void Stk_MouseLeftButtonDown(object sender, RoutedEventArgs e)
        {
            if (!HasItems)
            {
                IsSelected = true;

                if (IsChoosed == false)
                {
                    IsChoosed = true;
                }
                else
                {
                    e.Handled = true;
                    return;
                }
                ParentTreeView.OnChoosedItemChanged();
            }
            else
            {
                IsSelected = false;
                if (!ParentTreeView.IsExpandDoubleClick)
                {
                    IsExpanded = !IsExpanded;
                }
            }
        }