示例#1
0
 void menu_Click(object sender, EventArgs e)
 {
     MainForm frm2 = new MainForm();
     frm2.ParentMainForm = parent;
     frm2.Name = FullName;
     frm2.HideOnClose = false;
     frm2.Show(parent.DockPane, DockState.Document);
 }
示例#2
0
 public void Initialize(IMainForm Parent)
 {
     parent = Parent;
     //
     frm = new MainForm();
     frm.ParentMainForm = parent;
     frm.Name = FullName;
     frm.HideOnClose = false;
     //
     //glmenu = new ToolStripMenuItem();
     //glmenu.Text = this.FullName;
     //glmenu.DropDownItems.Add(frm.mnuFile);
     //glmenu.DropDownItems.Add(frm.mnuEdit);
     //glmenu.DropDownItems.Add(frm.mnuTools);
     //glmenu.DropDownItems.Add(frm.mnuHelp);
     //parent.AddMenu(glmenu);
     //
     menu = new ToolStripMenuItem();
     menu.Text = Name;
     menu.Click += new EventHandler(menu_Click);
     parent.AddPluginMenu(menu);
     //
     frm.Show(parent.DockPane, DockState.Document);
 }