Beispiel #1
0
 /// <summary>
 /// checkbox click event.  Subscribe or Unsubscribe to the MapSelectionChanged event according to the checkbox value
 /// </summary>
 protected override void OnClick()
 {
     if (IsChecked == true)
     {
         FrameworkApplication.EventAggregator.GetEvent <MapSelectionChanged>().Subscribe(OnMapSelectionChanged);
     }
     else if (IsChecked == false)
     {
         FrameworkApplication.EventAggregator.GetEvent <MapSelectionChanged>().Unsubscribe(OnMapSelectionChanged);
         ITablePane tbl = TableManager.ActiveTablePane;
         while (tbl != null)
         {
             ((Pane)tbl).Close();
             tbl = TableManager.ActiveTablePane;
         }
     }
 }
 /// <summary>
 /// checkbox click event.  Subscribe or Unsubscribe to the MapSelectionChanged event according to the checkbox value
 /// </summary>
 protected override void OnClick()
 {
     if (IsChecked == true)
     {
         MapSelectionChanged.Subscribe(OnMapSelectionChanged);
     }
     else if (IsChecked == false)
     {
         MapSelectionChanged.Unsubscribe(OnMapSelectionChanged);
         ITablePane tbl = TableManager.ActiveTablePane;
         while (tbl != null)
         {
             ((Pane)tbl).Close();
             tbl = TableManager.ActiveTablePane;
         }
     }
 }