Esempio n. 1
0
 public override void DocumentContextChanged(GH_Document document, GH_DocumentContext context)
 {
     if (context == GH_DocumentContext.Unloaded)
     {
         if (myControlPanel != null)
         {
             channel = myControlPanel.channel;
         }
         if (host != null)
         {
             try
             {
                 host.Close();
             }
             catch
             {
                 host.Abort();
             }
         }
     }
     if (context == GH_DocumentContext.Loaded)
     {
         myControlPanel = new mypanel(this, channel);
         functionset();
         myControlPanel._update();
         myControlPanel.Width = 190;
         init();
     }
     base.DocumentContextChanged(document, context);
 }
Esempio n. 2
0
 public override void AddedToDocument(GH_Document document)
 {
     myControlPanel = new mypanel(this, repo, proj, key, filterbyname, filteroldone);
     functionset();
     myControlPanel._update();
     myControlPanel.Width = 190;
     base.AddedToDocument(document);
 }
Esempio n. 3
0
 public override void AddedToDocument(GH_Document document)
 {
     myControlPanel = new mypanel(this, channel);
     functionset();
     myControlPanel._update();
     myControlPanel.Width = 190;
     base.AddedToDocument(document);
     init();
 }
Esempio n. 4
0
 public override void DocumentContextChanged(GH_Document document, GH_DocumentContext context)
 {
     if (context == GH_DocumentContext.Unloaded)
     {
         if (myControlPanel != null)
         {
             proj         = myControlPanel.project;
             key          = myControlPanel.key;
             filteroldone = myControlPanel._filteroldone;
             filterbyname = myControlPanel._filterbyname;
         }
     }
     if (context == GH_DocumentContext.Loaded)
     {
         myControlPanel = new mypanel(this, repo, proj, key, filterbyname, filteroldone);
         functionset();
         myControlPanel._update();
         myControlPanel.Width = 190;
     }
     base.DocumentContextChanged(document, context);
 }