Beispiel #1
0
 private GraphNodeForm()
 {
     InitializeComponent();
     this.CancelButton      = this;
     myDocChangedHandler    = new GoChangedEventHandler(this.DocumentChanged);
     myGotSelectionHandler  = new GoSelectionEventHandler(this.NodeGotSelection);
     myLostSelectionHandler = new GoSelectionEventHandler(this.NodeLostSelection);
     this.HideOnClose       = true;//only hide instead close
 }
Beispiel #2
0
 private void AddListeners()
 {
     if (myDocChangedEventHandler == null)
     {
         myDocChangedEventHandler          = base.SafeOnDocumentChanged;
         myViewResizedEventHandler         = ComponentResized;
         myViewPropertyChangedEventHandler = ViewChanged;
     }
     if (myObservedDocument != null)
     {
         myObservedDocument.Changed += myDocChangedEventHandler;
     }
     if (myObserved != null)
     {
         myObserved.Resize          += myViewResizedEventHandler;
         myObserved.PropertyChanged += myViewPropertyChangedEventHandler;
     }
 }