Esempio n. 1
0
 private void addFlow1_MouseClick(object sender, MouseEventArgs e)
 {
     if (e.Button == MouseButtons.Right)
     {
         Lassalle.Flow.Item item1 = this.addFlow1.GetItemAt(new Point(e.X, e.Y));
         if (item1 != null)
         {
             item1.Selected = true;
         }
     }
 }
Esempio n. 2
0
 /// <summary>
 /// (从某例子中拷贝过来的没弄明白呢,反正是配合剪切用的)
 /// </summary>
 private void SelectionChangeHandle()
 {
     Lassalle.Flow.Item item = addFlow1.SelectedItem;
     if (item != null)
     {
         if (item is Lassalle.Flow.Node)
         {
             Lassalle.Flow.Node node = (Lassalle.Flow.Node)item;
             propertyGrid1.SelectedObject = node;
             //Label1.Text = "Selected Node";
         }
         else if (item is Lassalle.Flow.Link)
         {
             Lassalle.Flow.Link link = (Lassalle.Flow.Link)item;
             propertyGrid1.SelectedObject = link;
             //Label1.Text = "Selected Link";
         }
     }
     else
     {
         propertyGrid1.SelectedObject = addFlow1;
         // Label1.Text = "AddFlow control";
     }
 }