示例#1
0
        private void CodeSourceTree_SelectedItemChanged(object sender, RoutedPropertyChangedEventArgs <object> e)
        {
            if (CodeSourceTreeIsCollapsing)
            {
                return;
            }

            TreeViewItem selected = (TreeViewItem)e.NewValue;

            selected.BringIntoView();
            selected.Focus();

            if (PreFilterLock.IsChecked == false)
            {
                AbstractXPathBuilder xpath = Parser.SuggestXPathFor(selected, String.Empty);
                XPathInput2.Text = string.Empty;
                XPathInput1.Text = xpath.ToString();
                ClickHistory.Add(xpath);
            }
            else
            {
                string root = XPathInput1.Text;
                AbstractXPathBuilder xpath = Parser.SuggestXPathFor(selected, root);
                XPathInput2.Text = xpath.ToString();
                ClickHistory.Add(xpath);
            }
        }
 partial void DeleteClickHistory(ClickHistory instance);
 partial void InsertClickHistory(ClickHistory instance);
 partial void UpdateClickHistory(ClickHistory instance);
示例#5
0
 public void Add(ClickHistory click)
 {
     DB.ClickHistories.InsertOnSubmit(click);
     DB.SubmitChanges();
 }