Ejemplo n.º 1
0
        /// <summary>
        /// 在TabControl的右键中加入菜单
        /// </summary>
        protected void OnMouseUpTabPage(object sender, System.Windows.Forms.MouseEventArgs e)
        {
            if (this.tabControlMain.TabPages.Count > 0 && e.Button == MouseButtons.Right && this.tabControlMain.SelectedTab.Selected)
            {
                var muMenu = new Crownwood.Magic.Menus.MenuControl();
                var menu1  = new Crownwood.Magic.Menus.MenuCommand("保存(&S)", new EventHandler(OnSaveSelected));
                var menu2  = new Crownwood.Magic.Menus.MenuCommand("关闭(&C)", new EventHandler(OnColseSelected));
                var menu3  = new Crownwood.Magic.Menus.MenuCommand("除此之外全部关闭(&A)", new EventHandler(OnColseUnSelected));

                var pm = new Crownwood.Magic.Menus.PopupMenu();
                pm.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] { menu1, menu2, menu3 });
                pm.TrackPopup(this.tabControlMain.PointToScreen(new Point(e.X, e.Y)));
            }

            if (this.tabControlMain.TabPages.Count > 0 && e.Button == MouseButtons.Left && this.tabControlMain.SelectedTab.Selected)
            {
                tsbtnExecSql.Visible = false;
                switch (this.tabControlMain.SelectedTab.Control.Name)
                {
                case "DbQuery":
                {
                    tsbtnExecSql.Visible = true;
                }
                break;

                case "DbBrowser":
                {
                }
                break;

                case "StartPageForm":
                {
                }
                break;

                default:
                    break;
                }
            }
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.menuItem1                  = new System.Windows.Forms.MenuItem();
     this._menuMain                  = new Crownwood.Magic.Menus.MenuControl();
     this._menuFile                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileNew                = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileOpen               = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileClose              = new Crownwood.Magic.Menus.MenuCommand();
     this._sep1                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSave               = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSaveAs             = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSaveAll            = new Crownwood.Magic.Menus.MenuCommand();
     this._sep2                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileRecentProjects     = new Crownwood.Magic.Menus.MenuCommand();
     this._sep3                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileExit               = new Crownwood.Magic.Menus.MenuCommand();
     this._menuEdit                  = new Crownwood.Magic.Menus.MenuCommand();
     this._menuProject               = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRun             = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectStop            = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectOptions         = new Crownwood.Magic.Menus.MenuCommand();
     this._sep4                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunViewMessages = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunCopy         = new Crownwood.Magic.Menus.MenuCommand();
     this._menuView                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewProjectView        = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewNavBack            = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewNavForward         = new Crownwood.Magic.Menus.MenuCommand();
     this._menuHelp                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdHelpAbout              = new Crownwood.Magic.Menus.MenuCommand();
     this._tcProfilers               = new Crownwood.Magic.Controls.TabControl();
     this._sbStatusBar               = new System.Windows.Forms.StatusBar();
     this._sbpMessage                = new System.Windows.Forms.StatusBarPanel();
     this.commandBarManager1         = new Reflector.UserInterface.CommandBarManager();
     this.commandBar1                = new Reflector.UserInterface.CommandBar();
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).BeginInit();
     this.SuspendLayout();
     //
     // menuItem1
     //
     this.menuItem1.Index = -1;
     this.menuItem1.Text  = "Close Tab";
     //
     // _menuMain
     //
     this._menuMain.AnimateStyle       = Crownwood.Magic.Menus.Animation.System;
     this._menuMain.AnimateTime        = 100;
     this._menuMain.Cursor             = System.Windows.Forms.Cursors.Arrow;
     this._menuMain.Direction          = Crownwood.Magic.Common.Direction.Horizontal;
     this._menuMain.Dock               = System.Windows.Forms.DockStyle.Top;
     this._menuMain.Font               = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this._menuMain.HighlightTextColor = System.Drawing.SystemColors.MenuText;
     this._menuMain.Location           = new System.Drawing.Point(0, 0);
     this._menuMain.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._menuFile,
         this._menuEdit,
         this._menuProject,
         this._menuView,
         this._menuHelp
     });
     this._menuMain.Name     = "_menuMain";
     this._menuMain.Size     = new System.Drawing.Size(920, 25);
     this._menuMain.Style    = Crownwood.Magic.Common.VisualStyle.IDE;
     this._menuMain.TabIndex = 0;
     this._menuMain.TabStop  = false;
     this._menuMain.Text     = "menuControl1";
     //
     // _menuFile
     //
     this._menuFile.Description = "File";
     this._menuFile.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdFileNew,
         this._cmdFileOpen,
         this._cmdFileClose,
         this._sep1,
         this._cmdFileSave,
         this._cmdFileSaveAs,
         this._cmdFileSaveAll,
         this._sep2,
         this._cmdFileRecentProjects,
         this._sep3,
         this._cmdFileExit
     });
     this._menuFile.Text = "&File";
     //
     // _cmdFileNew
     //
     this._cmdFileNew.Description = "New Profiler Project";
     this._cmdFileNew.Shortcut    = System.Windows.Forms.Shortcut.CtrlN;
     this._cmdFileNew.Text        = "&New...";
     this._cmdFileNew.Click      += new System.EventHandler(this._cmdFileNew_Click);
     this._cmdFileNew.Update     += new System.EventHandler(this.UpdateMenuItems);
     //
     // _cmdFileOpen
     //
     this._cmdFileOpen.Description = "Open a profile project";
     this._cmdFileOpen.Text        = "&Open...";
     this._cmdFileOpen.Click      += new System.EventHandler(this._cmdFileOpen_Click);
     //
     // _cmdFileClose
     //
     this._cmdFileClose.Description = "Close the project";
     this._cmdFileClose.Text        = "&Close";
     this._cmdFileClose.Click      += new System.EventHandler(this._cmdFileClose_Click);
     //
     // _sep1
     //
     this._sep1.Description = "MenuItem";
     this._sep1.Text        = "-";
     //
     // _cmdFileSave
     //
     this._cmdFileSave.Description = "Save the active profiler project";
     this._cmdFileSave.Shortcut    = System.Windows.Forms.Shortcut.CtrlS;
     this._cmdFileSave.Text        = "&Save";
     this._cmdFileSave.Click      += new System.EventHandler(this._cmdFileSave_Click);
     //
     // _cmdFileSaveAs
     //
     this._cmdFileSaveAs.Description = "Save the active profiler project as a specified file name";
     this._cmdFileSaveAs.Text        = "Save &As...";
     this._cmdFileSaveAs.Click      += new System.EventHandler(this._cmdFileSaveAs_Click);
     //
     // _cmdFileSaveAll
     //
     this._cmdFileSaveAll.Description = "Save all open profiler projects";
     this._cmdFileSaveAll.Shortcut    = System.Windows.Forms.Shortcut.CtrlShiftS;
     this._cmdFileSaveAll.Text        = "Save A&ll";
     this._cmdFileSaveAll.Click      += new System.EventHandler(this._cmdFileSaveAll_Click);
     //
     // _sep2
     //
     this._sep2.Description = "MenuItem";
     this._sep2.Text        = "-";
     //
     // _cmdFileRecentProjects
     //
     this._cmdFileRecentProjects.Description = "Provides a list of the 10 most recently opened projects for easy access";
     this._cmdFileRecentProjects.Text        = "Recent Projects";
     //
     // _sep3
     //
     this._sep3.Description = "-";
     this._sep3.Text        = "-";
     //
     // _cmdFileExit
     //
     this._cmdFileExit.Description = "Exit the application";
     this._cmdFileExit.Shortcut    = System.Windows.Forms.Shortcut.AltF4;
     this._cmdFileExit.Text        = "E&xit";
     this._cmdFileExit.Click      += new System.EventHandler(this._cmdFileExit_Click);
     //
     // _menuEdit
     //
     this._menuEdit.Description = "Edit";
     this._menuEdit.Enabled     = false;
     this._menuEdit.Text        = "&Edit";
     //
     // _menuProject
     //
     this._menuProject.Description = "Project commands";
     this._menuProject.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdProjectRun,
         this._cmdProjectStop,
         this._cmdProjectOptions,
         this._sep4,
         this._cmdProjectRunViewMessages,
         this._cmdProjectRunCopy
     });
     this._menuProject.Text = "&Project";
     //
     // _cmdProjectRun
     //
     this._cmdProjectRun.Description = "Run the current project";
     this._cmdProjectRun.Shortcut    = System.Windows.Forms.Shortcut.F5;
     this._cmdProjectRun.Text        = "Start project run";
     this._cmdProjectRun.Click      += new System.EventHandler(this._cmdProjectRun_Click);
     this._cmdProjectRun.Update     += new System.EventHandler(this.UpdateMenuItems);
     //
     // _cmdProjectStop
     //
     this._cmdProjectStop.Description = "Stop the running project";
     this._cmdProjectStop.Text        = "Stop project run";
     //
     // _cmdProjectOptions
     //
     this._cmdProjectOptions.Description = "Modify the options for this project";
     this._cmdProjectOptions.Shortcut    = System.Windows.Forms.Shortcut.F2;
     this._cmdProjectOptions.Text        = "Options...";
     this._cmdProjectOptions.Click      += new System.EventHandler(this._cmdProjectOptions_Click);
     this._cmdProjectOptions.Update     += new System.EventHandler(this.UpdateMenuItems);
     //
     // _sep4
     //
     this._sep4.Description = "-";
     this._sep4.Text        = "-";
     //
     // _cmdProjectRunViewMessages
     //
     this._cmdProjectRunViewMessages.Description = "View the Messages from the current profiler run...";
     this._cmdProjectRunViewMessages.Text        = "View Run Messages...";
     this._cmdProjectRunViewMessages.Click      += new System.EventHandler(this._cmdProjectRunViewMessages_Click);
     //
     // _cmdProjectRunCopy
     //
     this._cmdProjectRunCopy.Description = "Copy the project run data to the clipboard";
     this._cmdProjectRunCopy.Text        = "Copy Project Run Data";
     //
     // _menuView
     //
     this._menuView.Description = "View";
     this._menuView.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdViewProjectView,
         this._cmdViewNavBack,
         this._cmdViewNavForward
     });
     this._menuView.Text = "&View";
     //
     // _cmdViewProjectView
     //
     this._cmdViewProjectView.Description = "Show/hide the project tab";
     this._cmdViewProjectView.Text        = "Project tab";
     this._cmdViewProjectView.Click      += new System.EventHandler(this._cmdViewProjectView_Click);
     this._cmdViewProjectView.Update     += new System.EventHandler(this._cmdViewProjectView_Update);
     //
     // _cmdViewNavBack
     //
     this._cmdViewNavBack.Description = "Navigate Back";
     this._cmdViewNavBack.Text        = "Back";
     this._cmdViewNavBack.Click      += new System.EventHandler(this._cmdViewNavBack_Click);
     //
     // _cmdViewNavForward
     //
     this._cmdViewNavForward.Description = "Navigate Forward";
     this._cmdViewNavForward.Text        = "Forward";
     this._cmdViewNavForward.Click      += new System.EventHandler(this._cmdViewNavForward_Click);
     //
     // _menuHelp
     //
     this._menuHelp.Description = "Help";
     this._menuHelp.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdHelpAbout
     });
     this._menuHelp.Text = "&Help";
     //
     // _cmdHelpAbout
     //
     this._cmdHelpAbout.Description = "About nprof";
     this._cmdHelpAbout.Text        = "About nprof...";
     this._cmdHelpAbout.Click      += new System.EventHandler(this._cmdHelpAbout_Click);
     //
     // _tcProfilers
     //
     this._tcProfilers.Dock          = System.Windows.Forms.DockStyle.Fill;
     this._tcProfilers.IDEPixelArea  = true;
     this._tcProfilers.Location      = new System.Drawing.Point(0, 26);
     this._tcProfilers.Name          = "_tcProfilers";
     this._tcProfilers.Size          = new System.Drawing.Size(920, 629);
     this._tcProfilers.TabIndex      = 2;
     this._tcProfilers.ClosePressed += new System.EventHandler(this._tcProfilers_ClosePressed);
     //
     // _sbStatusBar
     //
     this._sbStatusBar.Location = new System.Drawing.Point(0, 655);
     this._sbStatusBar.Name     = "_sbStatusBar";
     this._sbStatusBar.Panels.AddRange(new System.Windows.Forms.StatusBarPanel[] {
         this._sbpMessage
     });
     this._sbStatusBar.ShowPanels = true;
     this._sbStatusBar.Size       = new System.Drawing.Size(920, 22);
     this._sbStatusBar.TabIndex   = 3;
     //
     // _sbpMessage
     //
     this._sbpMessage.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring;
     this._sbpMessage.Text     = "Ready.";
     this._sbpMessage.Width    = 904;
     //
     // commandBarManager1
     //
     this.commandBarManager1.Dock     = System.Windows.Forms.DockStyle.Top;
     this.commandBarManager1.Location = new System.Drawing.Point(0, 25);
     this.commandBarManager1.Name     = "commandBarManager1";
     this.commandBarManager1.Size     = new System.Drawing.Size(920, 1);
     this.commandBarManager1.TabIndex = 3;
     this.commandBarManager1.TabStop  = false;
     this.commandBarManager1.Text     = "commandBarManager1";
     //
     // commandBar1
     //
     this.commandBar1.Dock     = System.Windows.Forms.DockStyle.Top;
     this.commandBar1.Font     = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this.commandBar1.Location = new System.Drawing.Point(0, 64);
     this.commandBar1.Name     = "commandBar1";
     this.commandBar1.Size     = new System.Drawing.Size(920, 64);
     this.commandBar1.Style    = Reflector.UserInterface.CommandBarStyle.ToolBar;
     this.commandBar1.TabIndex = 4;
     this.commandBar1.TabStop  = false;
     this.commandBar1.Text     = "commandBar1";
     //
     // ProfilerForm
     //
     this.AllowDrop         = true;
     this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
     this.ClientSize        = new System.Drawing.Size(920, 677);
     this.Controls.Add(this._tcProfilers);
     this.Controls.Add(this.commandBarManager1);
     this.Controls.Add(this._menuMain);
     this.Controls.Add(this._sbStatusBar);
     this.Name     = "ProfilerForm";
     this.Text     = "nprof Profiling Application - Alpha v0.6";
     this.Closing += new System.ComponentModel.CancelEventHandler(this.ProfilerForm_Closing);
     this.Load    += new System.EventHandler(this.ProfilerForm_Load);
     this.Layout  += new System.Windows.Forms.LayoutEventHandler(this.ProfilerForm_Layout);
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).EndInit();
     this.ResumeLayout(false);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.menuItem1 = new System.Windows.Forms.MenuItem();
     this._menuMain = new Crownwood.Magic.Menus.MenuControl();
     this._menuFile = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdNew = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdOpen = new Crownwood.Magic.Menus.MenuCommand();
     this._sep1 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdSave = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdSaveAll = new Crownwood.Magic.Menus.MenuCommand();
     this._sep2 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdExit = new Crownwood.Magic.Menus.MenuCommand();
     this._menuEdit = new Crownwood.Magic.Menus.MenuCommand();
     this._menuProject = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRun = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectStop = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectOptions = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand5 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunViewMessages = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunCopy = new Crownwood.Magic.Menus.MenuCommand();
     this._menuView = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectView = new Crownwood.Magic.Menus.MenuCommand();
     this._menuHelp = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdHelpAbout = new Crownwood.Magic.Menus.MenuCommand();
     this._tcProfilers = new Crownwood.Magic.Controls.TabControl();
     this._sbStatusBar = new System.Windows.Forms.StatusBar();
     this._sbpMessage = new System.Windows.Forms.StatusBarPanel();
     this.menuCommand1 = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand2 = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand3 = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand4 = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand6 = new Crownwood.Magic.Menus.MenuCommand();
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).BeginInit();
     this.SuspendLayout();
     //
     // menuItem1
     //
     this.menuItem1.Index = -1;
     this.menuItem1.Text = "Close Tab";
     //
     // _menuMain
     //
     this._menuMain.AnimateStyle = Crownwood.Magic.Menus.Animation.System;
     this._menuMain.AnimateTime = 100;
     this._menuMain.Cursor = System.Windows.Forms.Cursors.Arrow;
     this._menuMain.Direction = Crownwood.Magic.Common.Direction.Horizontal;
     this._menuMain.Dock = System.Windows.Forms.DockStyle.Top;
     this._menuMain.Font = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this._menuMain.HighlightTextColor = System.Drawing.SystemColors.MenuText;
     this._menuMain.Location = new System.Drawing.Point(0, 0);
     this._menuMain.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._menuFile,
                                                                                      this._menuEdit,
                                                                                      this._menuProject,
                                                                                      this._menuView,
                                                                                      this._menuHelp});
     this._menuMain.Name = "_menuMain";
     this._menuMain.Size = new System.Drawing.Size(920, 25);
     this._menuMain.Style = Crownwood.Magic.Common.VisualStyle.IDE;
     this._menuMain.TabIndex = 0;
     this._menuMain.TabStop = false;
     this._menuMain.Text = "menuControl1";
     //
     // _menuFile
     //
     this._menuFile.Description = "File";
     this._menuFile.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdNew,
                                                                                      this._cmdOpen,
                                                                                      this._sep1,
                                                                                      this._cmdSave,
                                                                                      this._cmdSaveAll,
                                                                                      this._sep2,
                                                                                      this._cmdExit});
     this._menuFile.Text = "&File";
     //
     // _cmdNew
     //
     this._cmdNew.Description = "New Profiler Project";
     this._cmdNew.Text = "New...";
     this._cmdNew.Click += new System.EventHandler(this._cmdNew_Click);
     //
     // _cmdOpen
     //
     this._cmdOpen.Description = "Open a profile project";
     this._cmdOpen.Enabled = false;
     this._cmdOpen.Text = "Open";
     //
     // _sep1
     //
     this._sep1.Description = "MenuItem";
     this._sep1.Text = "-";
     //
     // _cmdSave
     //
     this._cmdSave.Description = "Save the active profiler project";
     this._cmdSave.Enabled = false;
     this._cmdSave.Text = "Save";
     //
     // _cmdSaveAll
     //
     this._cmdSaveAll.Description = "Save all open profiler projects";
     this._cmdSaveAll.Enabled = false;
     this._cmdSaveAll.Text = "Save All";
     //
     // _sep2
     //
     this._sep2.Description = "MenuItem";
     this._sep2.Text = "-";
     //
     // _cmdExit
     //
     this._cmdExit.Description = "Exit the application";
     this._cmdExit.Text = "E&xit";
     this._cmdExit.Click += new System.EventHandler(this._cmdExit_Click);
     //
     // _menuEdit
     //
     this._menuEdit.Description = "Edit";
     this._menuEdit.Enabled = false;
     this._menuEdit.Text = "&Edit";
     //
     // _menuProject
     //
     this._menuProject.Description = "Project commands";
     this._menuProject.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                         this._cmdProjectRun,
                                                                                         this._cmdProjectStop,
                                                                                         this._cmdProjectOptions,
                                                                                         this.menuCommand5,
                                                                                         this._cmdProjectRunViewMessages,
                                                                                         this._cmdProjectRunCopy});
     this._menuProject.Text = "&Project";
     //
     // _cmdProjectRun
     //
     this._cmdProjectRun.Description = "Run the current project";
     this._cmdProjectRun.Text = "Start project run";
     this._cmdProjectRun.Click += new System.EventHandler(this._cmdProjectRun_Click);
     this._cmdProjectRun.Update += new System.EventHandler(this.UpdateProjectItems);
     //
     // _cmdProjectStop
     //
     this._cmdProjectStop.Description = "Stop the running project";
     this._cmdProjectStop.Text = "Stop project run";
     //
     // _cmdProjectOptions
     //
     this._cmdProjectOptions.Description = "Modify the options for this project";
     this._cmdProjectOptions.Text = "Options...";
     this._cmdProjectOptions.Click += new System.EventHandler(this._cmdProjectOptions_Click);
     this._cmdProjectOptions.Update += new System.EventHandler(this.UpdateProjectItems);
     //
     // menuCommand5
     //
     this.menuCommand5.Description = "-";
     this.menuCommand5.Text = "-";
     //
     // _cmdProjectRunViewMessages
     //
     this._cmdProjectRunViewMessages.Description = "View the Messages from the current profiler run...";
     this._cmdProjectRunViewMessages.Text = "View Run Messages...";
     this._cmdProjectRunViewMessages.Click += new System.EventHandler(this._cmdProjectRunViewMessages_Click);
     //
     // _cmdProjectRunCopy
     //
     this._cmdProjectRunCopy.Description = "Copy the project run data to the clipboard";
     this._cmdProjectRunCopy.Text = "Copy Project Run Data";
     //
     // _menuView
     //
     this._menuView.Description = "View";
     this._menuView.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdProjectView});
     this._menuView.Text = "&View";
     //
     // _cmdProjectView
     //
     this._cmdProjectView.Description = "Show/hide the project tab";
     this._cmdProjectView.Text = "Project tab";
     this._cmdProjectView.Click += new System.EventHandler(this._cmdProjectView_Click);
     this._cmdProjectView.Update += new System.EventHandler(this._cmdProjectView_Update);
     //
     // _menuHelp
     //
     this._menuHelp.Description = "Help";
     this._menuHelp.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdHelpAbout});
     this._menuHelp.Text = "&Help";
     //
     // _cmdHelpAbout
     //
     this._cmdHelpAbout.Description = "About nprof";
     this._cmdHelpAbout.Text = "About nprof...";
     this._cmdHelpAbout.Click += new System.EventHandler(this._cmdHelpAbout_Click);
     //
     // _tcProfilers
     //
     this._tcProfilers.Dock = System.Windows.Forms.DockStyle.Fill;
     this._tcProfilers.IDEPixelArea = true;
     this._tcProfilers.Location = new System.Drawing.Point(0, 25);
     this._tcProfilers.Name = "_tcProfilers";
     this._tcProfilers.Size = new System.Drawing.Size(920, 630);
     this._tcProfilers.TabIndex = 2;
     this._tcProfilers.SelectionChanged += new System.EventHandler(this._tcProfilers_SelectionChanged);
     this._tcProfilers.ClosePressed += new System.EventHandler(this._tcProfilers_ClosePressed);
     //
     // _sbStatusBar
     //
     this._sbStatusBar.Location = new System.Drawing.Point(0, 655);
     this._sbStatusBar.Name = "_sbStatusBar";
     this._sbStatusBar.Panels.AddRange(new System.Windows.Forms.StatusBarPanel[] {
                                                                                     this._sbpMessage});
     this._sbStatusBar.ShowPanels = true;
     this._sbStatusBar.Size = new System.Drawing.Size(920, 22);
     this._sbStatusBar.TabIndex = 3;
     //
     // _sbpMessage
     //
     this._sbpMessage.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring;
     this._sbpMessage.Text = "Ready.";
     this._sbpMessage.Width = 904;
     //
     // menuCommand1
     //
     this.menuCommand1.Description = "MenuItem";
     //
     // menuCommand2
     //
     this.menuCommand2.Break = true;
     this.menuCommand2.Description = "MenuItem";
     //
     // menuCommand3
     //
     this.menuCommand3.Break = true;
     this.menuCommand3.Description = "MenuItem";
     //
     // menuCommand4
     //
     this.menuCommand4.Description = "MenuItem";
     //
     // menuCommand6
     //
     this.menuCommand6.Description = "MenuItem";
     //
     // ProfilerForm
     //
     this.AllowDrop = true;
     this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
     this.ClientSize = new System.Drawing.Size(920, 677);
     this.Controls.Add(this._tcProfilers);
     this.Controls.Add(this._menuMain);
     this.Controls.Add(this._sbStatusBar);
     this.Name = "ProfilerForm";
     this.Text = "nprof Profiling Application - Alpha v0.6";
     this.Closing += new System.ComponentModel.CancelEventHandler(this.ProfilerForm_Closing);
     this.Load += new System.EventHandler(this.ProfilerForm_Load);
     this.Layout += new System.Windows.Forms.LayoutEventHandler(this.ProfilerForm_Layout);
     this.Leave += new System.EventHandler(this.ProfilerForm_Leave);
     this.Deactivate += new System.EventHandler(this.ProfilerForm_Deactivate);
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).EndInit();
     this.ResumeLayout(false);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.menuItem1 = new System.Windows.Forms.MenuItem();
     this._menuMain = new Crownwood.Magic.Menus.MenuControl();
     this._menuFile = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileNew = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileOpen = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileClose = new Crownwood.Magic.Menus.MenuCommand();
     this._sep1 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSave = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSaveAs = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileSaveAll = new Crownwood.Magic.Menus.MenuCommand();
     this._sep2 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileRecentProjects = new Crownwood.Magic.Menus.MenuCommand();
     this._sep3 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdFileExit = new Crownwood.Magic.Menus.MenuCommand();
     this._menuEdit = new Crownwood.Magic.Menus.MenuCommand();
     this._menuProject = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRun = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectStop = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectOptions = new Crownwood.Magic.Menus.MenuCommand();
     this._sep4 = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunViewMessages = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunCopy = new Crownwood.Magic.Menus.MenuCommand();
     this._menuView = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewProjectView = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewNavBack = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdViewNavForward = new Crownwood.Magic.Menus.MenuCommand();
     this._menuHelp = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdHelpAbout = new Crownwood.Magic.Menus.MenuCommand();
     this._tcProfilers = new Crownwood.Magic.Controls.TabControl();
     this._sbStatusBar = new System.Windows.Forms.StatusBar();
     this._sbpMessage = new System.Windows.Forms.StatusBarPanel();
     this.commandBarManager1 = new Reflector.UserInterface.CommandBarManager();
     this.commandBar1 = new Reflector.UserInterface.CommandBar();
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).BeginInit();
     this.SuspendLayout();
     //
     // menuItem1
     //
     this.menuItem1.Index = -1;
     this.menuItem1.Text = "Close Tab";
     //
     // _menuMain
     //
     this._menuMain.AnimateStyle = Crownwood.Magic.Menus.Animation.System;
     this._menuMain.AnimateTime = 100;
     this._menuMain.Cursor = System.Windows.Forms.Cursors.Arrow;
     this._menuMain.Direction = Crownwood.Magic.Common.Direction.Horizontal;
     this._menuMain.Dock = System.Windows.Forms.DockStyle.Top;
     this._menuMain.Font = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this._menuMain.HighlightTextColor = System.Drawing.SystemColors.MenuText;
     this._menuMain.Location = new System.Drawing.Point(0, 0);
     this._menuMain.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._menuFile,
                                                                                      this._menuEdit,
                                                                                      this._menuProject,
                                                                                      this._menuView,
                                                                                      this._menuHelp});
     this._menuMain.Name = "_menuMain";
     this._menuMain.Size = new System.Drawing.Size(920, 25);
     this._menuMain.Style = Crownwood.Magic.Common.VisualStyle.IDE;
     this._menuMain.TabIndex = 0;
     this._menuMain.TabStop = false;
     this._menuMain.Text = "menuControl1";
     //
     // _menuFile
     //
     this._menuFile.Description = "File";
     this._menuFile.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdFileNew,
                                                                                      this._cmdFileOpen,
                                                                                      this._cmdFileClose,
                                                                                      this._sep1,
                                                                                      this._cmdFileSave,
                                                                                      this._cmdFileSaveAs,
                                                                                      this._cmdFileSaveAll,
                                                                                      this._sep2,
                                                                                      this._cmdFileRecentProjects,
                                                                                      this._sep3,
                                                                                      this._cmdFileExit});
     this._menuFile.Text = "&File";
     //
     // _cmdFileNew
     //
     this._cmdFileNew.Description = "New Profiler Project";
     this._cmdFileNew.Shortcut = System.Windows.Forms.Shortcut.CtrlN;
     this._cmdFileNew.Text = "&New...";
     this._cmdFileNew.Click += new System.EventHandler(this._cmdFileNew_Click);
     this._cmdFileNew.Update += new System.EventHandler(this.UpdateMenuItems);
     //
     // _cmdFileOpen
     //
     this._cmdFileOpen.Description = "Open a profile project";
     this._cmdFileOpen.Text = "&Open...";
     this._cmdFileOpen.Click += new System.EventHandler(this._cmdFileOpen_Click);
     //
     // _cmdFileClose
     //
     this._cmdFileClose.Description = "Close the project";
     this._cmdFileClose.Text = "&Close";
     this._cmdFileClose.Click += new System.EventHandler(this._cmdFileClose_Click);
     //
     // _sep1
     //
     this._sep1.Description = "MenuItem";
     this._sep1.Text = "-";
     //
     // _cmdFileSave
     //
     this._cmdFileSave.Description = "Save the active profiler project";
     this._cmdFileSave.Shortcut = System.Windows.Forms.Shortcut.CtrlS;
     this._cmdFileSave.Text = "&Save";
     this._cmdFileSave.Click += new System.EventHandler(this._cmdFileSave_Click);
     //
     // _cmdFileSaveAs
     //
     this._cmdFileSaveAs.Description = "Save the active profiler project as a specified file name";
     this._cmdFileSaveAs.Text = "Save &As...";
     this._cmdFileSaveAs.Click += new System.EventHandler(this._cmdFileSaveAs_Click);
     //
     // _cmdFileSaveAll
     //
     this._cmdFileSaveAll.Description = "Save all open profiler projects";
     this._cmdFileSaveAll.Shortcut = System.Windows.Forms.Shortcut.CtrlShiftS;
     this._cmdFileSaveAll.Text = "Save A&ll";
     this._cmdFileSaveAll.Click += new System.EventHandler(this._cmdFileSaveAll_Click);
     //
     // _sep2
     //
     this._sep2.Description = "MenuItem";
     this._sep2.Text = "-";
     //
     // _cmdFileRecentProjects
     //
     this._cmdFileRecentProjects.Description = "Provides a list of the 10 most recently opened projects for easy access";
     this._cmdFileRecentProjects.Text = "Recent Projects";
     //
     // _sep3
     //
     this._sep3.Description = "-";
     this._sep3.Text = "-";
     //
     // _cmdFileExit
     //
     this._cmdFileExit.Description = "Exit the application";
     this._cmdFileExit.Shortcut = System.Windows.Forms.Shortcut.AltF4;
     this._cmdFileExit.Text = "E&xit";
     this._cmdFileExit.Click += new System.EventHandler(this._cmdFileExit_Click);
     //
     // _menuEdit
     //
     this._menuEdit.Description = "Edit";
     this._menuEdit.Enabled = false;
     this._menuEdit.Text = "&Edit";
     //
     // _menuProject
     //
     this._menuProject.Description = "Project commands";
     this._menuProject.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                         this._cmdProjectRun,
                                                                                         this._cmdProjectStop,
                                                                                         this._cmdProjectOptions,
                                                                                         this._sep4,
                                                                                         this._cmdProjectRunViewMessages,
                                                                                         this._cmdProjectRunCopy});
     this._menuProject.Text = "&Project";
     //
     // _cmdProjectRun
     //
     this._cmdProjectRun.Description = "Run the current project";
     this._cmdProjectRun.Shortcut = System.Windows.Forms.Shortcut.F5;
     this._cmdProjectRun.Text = "Start project run";
     this._cmdProjectRun.Click += new System.EventHandler(this._cmdProjectRun_Click);
     this._cmdProjectRun.Update += new System.EventHandler(this.UpdateMenuItems);
     //
     // _cmdProjectStop
     //
     this._cmdProjectStop.Description = "Stop the running project";
     this._cmdProjectStop.Text = "Stop project run";
     //
     // _cmdProjectOptions
     //
     this._cmdProjectOptions.Description = "Modify the options for this project";
     this._cmdProjectOptions.Shortcut = System.Windows.Forms.Shortcut.F2;
     this._cmdProjectOptions.Text = "Options...";
     this._cmdProjectOptions.Click += new System.EventHandler(this._cmdProjectOptions_Click);
     this._cmdProjectOptions.Update += new System.EventHandler(this.UpdateMenuItems);
     //
     // _sep4
     //
     this._sep4.Description = "-";
     this._sep4.Text = "-";
     //
     // _cmdProjectRunViewMessages
     //
     this._cmdProjectRunViewMessages.Description = "View the Messages from the current profiler run...";
     this._cmdProjectRunViewMessages.Text = "View Run Messages...";
     this._cmdProjectRunViewMessages.Click += new System.EventHandler(this._cmdProjectRunViewMessages_Click);
     //
     // _cmdProjectRunCopy
     //
     this._cmdProjectRunCopy.Description = "Copy the project run data to the clipboard";
     this._cmdProjectRunCopy.Text = "Copy Project Run Data";
     //
     // _menuView
     //
     this._menuView.Description = "View";
     this._menuView.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdViewProjectView,
                                                                                      this._cmdViewNavBack,
                                                                                      this._cmdViewNavForward});
     this._menuView.Text = "&View";
     //
     // _cmdViewProjectView
     //
     this._cmdViewProjectView.Description = "Show/hide the project tab";
     this._cmdViewProjectView.Text = "Project tab";
     this._cmdViewProjectView.Click += new System.EventHandler(this._cmdViewProjectView_Click);
     this._cmdViewProjectView.Update += new System.EventHandler(this._cmdViewProjectView_Update);
     //
     // _cmdViewNavBack
     //
     this._cmdViewNavBack.Description = "Navigate Back";
     this._cmdViewNavBack.Text = "Back";
     this._cmdViewNavBack.Click += new System.EventHandler(this._cmdViewNavBack_Click);
     //
     // _cmdViewNavForward
     //
     this._cmdViewNavForward.Description = "Navigate Forward";
     this._cmdViewNavForward.Text = "Forward";
     this._cmdViewNavForward.Click += new System.EventHandler(this._cmdViewNavForward_Click);
     //
     // _menuHelp
     //
     this._menuHelp.Description = "Help";
     this._menuHelp.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
                                                                                      this._cmdHelpAbout});
     this._menuHelp.Text = "&Help";
     //
     // _cmdHelpAbout
     //
     this._cmdHelpAbout.Description = "About nprof";
     this._cmdHelpAbout.Text = "About nprof...";
     this._cmdHelpAbout.Click += new System.EventHandler(this._cmdHelpAbout_Click);
     //
     // _tcProfilers
     //
     this._tcProfilers.Dock = System.Windows.Forms.DockStyle.Fill;
     this._tcProfilers.IDEPixelArea = true;
     this._tcProfilers.Location = new System.Drawing.Point(0, 26);
     this._tcProfilers.Name = "_tcProfilers";
     this._tcProfilers.Size = new System.Drawing.Size(920, 629);
     this._tcProfilers.TabIndex = 2;
     this._tcProfilers.ClosePressed += new System.EventHandler(this._tcProfilers_ClosePressed);
     //
     // _sbStatusBar
     //
     this._sbStatusBar.Location = new System.Drawing.Point(0, 655);
     this._sbStatusBar.Name = "_sbStatusBar";
     this._sbStatusBar.Panels.AddRange(new System.Windows.Forms.StatusBarPanel[] {
                                                                                     this._sbpMessage});
     this._sbStatusBar.ShowPanels = true;
     this._sbStatusBar.Size = new System.Drawing.Size(920, 22);
     this._sbStatusBar.TabIndex = 3;
     //
     // _sbpMessage
     //
     this._sbpMessage.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring;
     this._sbpMessage.Text = "Ready.";
     this._sbpMessage.Width = 904;
     //
     // commandBarManager1
     //
     this.commandBarManager1.Dock = System.Windows.Forms.DockStyle.Top;
     this.commandBarManager1.Location = new System.Drawing.Point(0, 25);
     this.commandBarManager1.Name = "commandBarManager1";
     this.commandBarManager1.Size = new System.Drawing.Size(920, 1);
     this.commandBarManager1.TabIndex = 3;
     this.commandBarManager1.TabStop = false;
     this.commandBarManager1.Text = "commandBarManager1";
     //
     // commandBar1
     //
     this.commandBar1.Dock = System.Windows.Forms.DockStyle.Top;
     this.commandBar1.Font = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this.commandBar1.Location = new System.Drawing.Point(0, 64);
     this.commandBar1.Name = "commandBar1";
     this.commandBar1.Size = new System.Drawing.Size(920, 64);
     this.commandBar1.Style = Reflector.UserInterface.CommandBarStyle.ToolBar;
     this.commandBar1.TabIndex = 4;
     this.commandBar1.TabStop = false;
     this.commandBar1.Text = "commandBar1";
     //
     // ProfilerForm
     //
     this.AllowDrop = true;
     this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
     this.ClientSize = new System.Drawing.Size(920, 677);
     this.Controls.Add(this._tcProfilers);
     this.Controls.Add(this.commandBarManager1);
     this.Controls.Add(this._menuMain);
     this.Controls.Add(this._sbStatusBar);
     this.Name = "ProfilerForm";
     this.Text = "nprof Profiling Application - Alpha v0.6";
     this.Closing += new System.ComponentModel.CancelEventHandler(this.ProfilerForm_Closing);
     this.Load += new System.EventHandler(this.ProfilerForm_Load);
     this.Layout += new System.Windows.Forms.LayoutEventHandler(this.ProfilerForm_Layout);
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).EndInit();
     this.ResumeLayout(false);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.menuItem1                  = new System.Windows.Forms.MenuItem();
     this._menuMain                  = new Crownwood.Magic.Menus.MenuControl();
     this._menuFile                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdNew                    = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdOpen                   = new Crownwood.Magic.Menus.MenuCommand();
     this._sep1                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdSave                   = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdSaveAll                = new Crownwood.Magic.Menus.MenuCommand();
     this._sep2                      = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdExit                   = new Crownwood.Magic.Menus.MenuCommand();
     this._menuEdit                  = new Crownwood.Magic.Menus.MenuCommand();
     this._menuProject               = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRun             = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectStop            = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectOptions         = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand5               = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunViewMessages = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectRunCopy         = new Crownwood.Magic.Menus.MenuCommand();
     this._menuView                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdProjectView            = new Crownwood.Magic.Menus.MenuCommand();
     this._menuHelp                  = new Crownwood.Magic.Menus.MenuCommand();
     this._cmdHelpAbout              = new Crownwood.Magic.Menus.MenuCommand();
     this._tcProfilers               = new Crownwood.Magic.Controls.TabControl();
     this._sbStatusBar               = new System.Windows.Forms.StatusBar();
     this._sbpMessage                = new System.Windows.Forms.StatusBarPanel();
     this.menuCommand1               = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand2               = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand3               = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand4               = new Crownwood.Magic.Menus.MenuCommand();
     this.menuCommand6               = new Crownwood.Magic.Menus.MenuCommand();
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).BeginInit();
     this.SuspendLayout();
     //
     // menuItem1
     //
     this.menuItem1.Index = -1;
     this.menuItem1.Text  = "Close Tab";
     //
     // _menuMain
     //
     this._menuMain.AnimateStyle       = Crownwood.Magic.Menus.Animation.System;
     this._menuMain.AnimateTime        = 100;
     this._menuMain.Cursor             = System.Windows.Forms.Cursors.Arrow;
     this._menuMain.Direction          = Crownwood.Magic.Common.Direction.Horizontal;
     this._menuMain.Dock               = System.Windows.Forms.DockStyle.Top;
     this._menuMain.Font               = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((System.Byte)(0)));
     this._menuMain.HighlightTextColor = System.Drawing.SystemColors.MenuText;
     this._menuMain.Location           = new System.Drawing.Point(0, 0);
     this._menuMain.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._menuFile,
         this._menuEdit,
         this._menuProject,
         this._menuView,
         this._menuHelp
     });
     this._menuMain.Name     = "_menuMain";
     this._menuMain.Size     = new System.Drawing.Size(920, 25);
     this._menuMain.Style    = Crownwood.Magic.Common.VisualStyle.IDE;
     this._menuMain.TabIndex = 0;
     this._menuMain.TabStop  = false;
     this._menuMain.Text     = "menuControl1";
     //
     // _menuFile
     //
     this._menuFile.Description = "File";
     this._menuFile.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdNew,
         this._cmdOpen,
         this._sep1,
         this._cmdSave,
         this._cmdSaveAll,
         this._sep2,
         this._cmdExit
     });
     this._menuFile.Text = "&File";
     //
     // _cmdNew
     //
     this._cmdNew.Description = "New Profiler Project";
     this._cmdNew.Text        = "New...";
     this._cmdNew.Click      += new System.EventHandler(this._cmdNew_Click);
     //
     // _cmdOpen
     //
     this._cmdOpen.Description = "Open a profile project";
     this._cmdOpen.Enabled     = false;
     this._cmdOpen.Text        = "Open";
     //
     // _sep1
     //
     this._sep1.Description = "MenuItem";
     this._sep1.Text        = "-";
     //
     // _cmdSave
     //
     this._cmdSave.Description = "Save the active profiler project";
     this._cmdSave.Enabled     = false;
     this._cmdSave.Text        = "Save";
     //
     // _cmdSaveAll
     //
     this._cmdSaveAll.Description = "Save all open profiler projects";
     this._cmdSaveAll.Enabled     = false;
     this._cmdSaveAll.Text        = "Save All";
     //
     // _sep2
     //
     this._sep2.Description = "MenuItem";
     this._sep2.Text        = "-";
     //
     // _cmdExit
     //
     this._cmdExit.Description = "Exit the application";
     this._cmdExit.Text        = "E&xit";
     this._cmdExit.Click      += new System.EventHandler(this._cmdExit_Click);
     //
     // _menuEdit
     //
     this._menuEdit.Description = "Edit";
     this._menuEdit.Enabled     = false;
     this._menuEdit.Text        = "&Edit";
     //
     // _menuProject
     //
     this._menuProject.Description = "Project commands";
     this._menuProject.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdProjectRun,
         this._cmdProjectStop,
         this._cmdProjectOptions,
         this.menuCommand5,
         this._cmdProjectRunViewMessages,
         this._cmdProjectRunCopy
     });
     this._menuProject.Text = "&Project";
     //
     // _cmdProjectRun
     //
     this._cmdProjectRun.Description = "Run the current project";
     this._cmdProjectRun.Text        = "Start project run";
     this._cmdProjectRun.Click      += new System.EventHandler(this._cmdProjectRun_Click);
     this._cmdProjectRun.Update     += new System.EventHandler(this.UpdateProjectItems);
     //
     // _cmdProjectStop
     //
     this._cmdProjectStop.Description = "Stop the running project";
     this._cmdProjectStop.Text        = "Stop project run";
     //
     // _cmdProjectOptions
     //
     this._cmdProjectOptions.Description = "Modify the options for this project";
     this._cmdProjectOptions.Text        = "Options...";
     this._cmdProjectOptions.Click      += new System.EventHandler(this._cmdProjectOptions_Click);
     this._cmdProjectOptions.Update     += new System.EventHandler(this.UpdateProjectItems);
     //
     // menuCommand5
     //
     this.menuCommand5.Description = "-";
     this.menuCommand5.Text        = "-";
     //
     // _cmdProjectRunViewMessages
     //
     this._cmdProjectRunViewMessages.Description = "View the Messages from the current profiler run...";
     this._cmdProjectRunViewMessages.Text        = "View Run Messages...";
     this._cmdProjectRunViewMessages.Click      += new System.EventHandler(this._cmdProjectRunViewMessages_Click);
     //
     // _cmdProjectRunCopy
     //
     this._cmdProjectRunCopy.Description = "Copy the project run data to the clipboard";
     this._cmdProjectRunCopy.Text        = "Copy Project Run Data";
     //
     // _menuView
     //
     this._menuView.Description = "View";
     this._menuView.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdProjectView
     });
     this._menuView.Text = "&View";
     //
     // _cmdProjectView
     //
     this._cmdProjectView.Description = "Show/hide the project tab";
     this._cmdProjectView.Text        = "Project tab";
     this._cmdProjectView.Click      += new System.EventHandler(this._cmdProjectView_Click);
     this._cmdProjectView.Update     += new System.EventHandler(this._cmdProjectView_Update);
     //
     // _menuHelp
     //
     this._menuHelp.Description = "Help";
     this._menuHelp.MenuCommands.AddRange(new Crownwood.Magic.Menus.MenuCommand[] {
         this._cmdHelpAbout
     });
     this._menuHelp.Text = "&Help";
     //
     // _cmdHelpAbout
     //
     this._cmdHelpAbout.Description = "About nprof";
     this._cmdHelpAbout.Text        = "About nprof...";
     this._cmdHelpAbout.Click      += new System.EventHandler(this._cmdHelpAbout_Click);
     //
     // _tcProfilers
     //
     this._tcProfilers.Dock              = System.Windows.Forms.DockStyle.Fill;
     this._tcProfilers.IDEPixelArea      = true;
     this._tcProfilers.Location          = new System.Drawing.Point(0, 25);
     this._tcProfilers.Name              = "_tcProfilers";
     this._tcProfilers.Size              = new System.Drawing.Size(920, 630);
     this._tcProfilers.TabIndex          = 2;
     this._tcProfilers.SelectionChanged += new System.EventHandler(this._tcProfilers_SelectionChanged);
     this._tcProfilers.ClosePressed     += new System.EventHandler(this._tcProfilers_ClosePressed);
     //
     // _sbStatusBar
     //
     this._sbStatusBar.Location = new System.Drawing.Point(0, 655);
     this._sbStatusBar.Name     = "_sbStatusBar";
     this._sbStatusBar.Panels.AddRange(new System.Windows.Forms.StatusBarPanel[] {
         this._sbpMessage
     });
     this._sbStatusBar.ShowPanels = true;
     this._sbStatusBar.Size       = new System.Drawing.Size(920, 22);
     this._sbStatusBar.TabIndex   = 3;
     //
     // _sbpMessage
     //
     this._sbpMessage.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring;
     this._sbpMessage.Text     = "Ready.";
     this._sbpMessage.Width    = 904;
     //
     // menuCommand1
     //
     this.menuCommand1.Description = "MenuItem";
     //
     // menuCommand2
     //
     this.menuCommand2.Break       = true;
     this.menuCommand2.Description = "MenuItem";
     //
     // menuCommand3
     //
     this.menuCommand3.Break       = true;
     this.menuCommand3.Description = "MenuItem";
     //
     // menuCommand4
     //
     this.menuCommand4.Description = "MenuItem";
     //
     // menuCommand6
     //
     this.menuCommand6.Description = "MenuItem";
     //
     // ProfilerForm
     //
     this.AllowDrop         = true;
     this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
     this.ClientSize        = new System.Drawing.Size(920, 677);
     this.Controls.Add(this._tcProfilers);
     this.Controls.Add(this._menuMain);
     this.Controls.Add(this._sbStatusBar);
     this.Name        = "ProfilerForm";
     this.Text        = "nprof Profiling Application - Alpha v0.6";
     this.Closing    += new System.ComponentModel.CancelEventHandler(this.ProfilerForm_Closing);
     this.Load       += new System.EventHandler(this.ProfilerForm_Load);
     this.Layout     += new System.Windows.Forms.LayoutEventHandler(this.ProfilerForm_Layout);
     this.Leave      += new System.EventHandler(this.ProfilerForm_Leave);
     this.Deactivate += new System.EventHandler(this.ProfilerForm_Deactivate);
     ((System.ComponentModel.ISupportInitialize)(this._sbpMessage)).EndInit();
     this.ResumeLayout(false);
 }
Ejemplo n.º 6
0
        private void SubsystemEditor_CreateGUI(PetriNetDocument pnd, Subsystem ssOwner)
        {
            this.pnd     = pnd;
            this.ssOwner = ssOwner;

            Panel pnlEditorContainer = new Panel();

            pnlEditorContainer.AutoScroll = true;
            pnlEditorContainer.Dock       = DockStyle.Fill;

            this.pneEditor                         = new PetriNetEditor(pnd, pnd.InstanceCounter);
            this.pneEditor.AutoScroll              = true;
            this.pneEditor.AutoScrollMinSize       = new Size(3000, 3000);
            this.pneEditor.Size                    = new Size(3000, 3000);
            this.pneEditor.Location                = new Point(0, 0);
            this.pneEditor.ContentsChanged        += new EventHandler(pneEditor_ContentsChanged);
            this.pneEditor.SelectedObjectsChanged += new EventHandler(pneEditor_SelectedObjectsChanged);
            this.pneEditor.PropertiesChanged      += new EventHandler(pneEditor_PropertiesChanged);

            if (this.oDeserializedZoomLevel != null)
            {
                this.pneEditor.Zoom = (float)this.oDeserializedZoomLevel;
            }

            pnlEditorContainer.Controls.Add(pneEditor);
            this.Controls.Add(pnlEditorContainer);

            // Create the object that manages the docking state
            this.dmDockingManager = new Crownwood.Magic.Docking.DockingManager(this, Crownwood.Magic.Common.VisualStyle.IDE);
            this.dmDockingManager.InnerControl = pnlEditorContainer;
            this.dmDockingManager.OuterControl = tbToolBar;

            Crownwood.Magic.Docking.Content toolbox = dmDockingManager.Contents.Add(this.tbToolBox, "Toolbox", this.ilContent, 1);
            toolbox.AutoHideSize = new Size(200, 300);
            toolbox.DisplaySize  = new Size(200, 300);
            toolbox.FloatingSize = new Size(200, 300);
            Crownwood.Magic.Docking.Content properties = dmDockingManager.Contents.Add(this.piPropertiesInspector, "Properties", this.ilContent, 0);
            properties.AutoHideSize = new Size(200, 300);
            properties.DisplaySize  = new Size(200, 300);
            properties.FloatingSize = new Size(200, 300);
            Crownwood.Magic.Docking.WindowContent wc = dmDockingManager.AddContentWithState(toolbox, Crownwood.Magic.Docking.State.DockLeft);

            //dmDockingManager.AddContentToWindowContent(notePad2, wc);
            // Add a new WindowContent to the existing Zone already created
            this.dmDockingManager.AddContentToZone(properties, wc.ParentZone, 1);

            this.tbToolBox.EnabledToolbox = true;

            // Load layout
            if (File.Exists(Application.StartupPath + "\\layoutSubsystem.config.xml"))
            {
                this.dmDockingManager.LoadConfigFromFile(Application.StartupPath + "\\layoutSubsystem.config.xml");
            }

            // Initialize piPropertiesInspector
            this.piPropertiesInspector.SelectedObjectChanged += new EventHandler(piPropertiesInspector_SelectedObjectChanged);

            #region Initialize ToolBar control
            this.tbToolBar.Dock         = DockStyle.Top;
            this.tbToolBar.ButtonSize   = new Size(24, 24);
            this.tbToolBar.ImageList    = ilToolBar;
            this.tbToolBar.ButtonClick += new ToolBarButtonClickEventHandler(tbToolBar_ButtonClick);
            this.tbToolBar.Appearance   = ToolBarAppearance.Flat;

            this.tbbReset.Enabled    = false;
            this.tbbReset.ImageIndex = 3;
            this.tbToolBar.Buttons.Add(tbbReset);

            this.tbbStart.Enabled    = false;
            this.tbbStart.ImageIndex = 4;
            this.tbToolBar.Buttons.Add(tbbStart);

            this.tbbPause.Enabled    = false;
            this.tbbPause.ImageIndex = 5;
            this.tbToolBar.Buttons.Add(tbbPause);

            this.tbbStop.Enabled    = false;
            this.tbbStop.ImageIndex = 6;
            this.tbToolBar.Buttons.Add(tbbStop);

            this.tbbStep.Enabled    = false;
            this.tbbStep.ImageIndex = 7;
            this.tbToolBar.Buttons.Add(tbbStep);

            this.tbbSeparator4.Style = ToolBarButtonStyle.Separator;
            this.tbToolBar.Buttons.Add(tbbSeparator4);

            this.tbbUndo.ImageIndex   = 13;
            this.tbbUndo.ToolTipText  = "Undo";
            this.tbbUndo.Style        = ToolBarButtonStyle.DropDownButton;
            this.tbbUndo.DropDownMenu = this.cmUndo;
            this.tbToolBar.Buttons.Add(tbbUndo);

            this.tbbRedo.ImageIndex   = 14;
            this.tbbRedo.ToolTipText  = "Redo";
            this.tbbRedo.Style        = ToolBarButtonStyle.DropDownButton;
            this.tbbRedo.DropDownMenu = this.cmRedo;
            this.tbToolBar.Buttons.Add(tbbRedo);

            this.tbbSeparator2.Style = ToolBarButtonStyle.Separator;
            this.tbToolBar.Buttons.Add(tbbSeparator2);

//			this.tbbConflicts.ImageIndex = 8;
//			this.tbbConflicts.Style = ToolBarButtonStyle.ToggleButton;
//			this.tbToolBar.Buttons.Add(tbbConflicts);
//
//			this.tbbCircularWaits.ImageIndex = 9;
//			this.tbbCircularWaits.Style = ToolBarButtonStyle.ToggleButton;
//			this.tbToolBar.Buttons.Add(tbbCircularWaits);
//
//			this.tbbFireable.ImageIndex = 10;
//			this.tbbFireable.Style = ToolBarButtonStyle.ToggleButton;
//			this.tbbFireable.Pushed = true;
//			this.tbToolBar.Buttons.Add(tbbFireable);
//
//			this.tbbFired.ImageIndex = 11;
//			this.tbbFired.Style = ToolBarButtonStyle.ToggleButton;
//			this.tbbFired.Pushed = true;
//			this.tbToolBar.Buttons.Add(tbbFired);
//
//			this.tbbSeparator3.Style = ToolBarButtonStyle.Separator;
//			this.tbToolBar.Buttons.Add(tbbSeparator3);

            this.tbbZoom.ImageIndex   = 12;
            this.tbbZoom.Style        = ToolBarButtonStyle.DropDownButton;
            this.tbbZoom.DropDownMenu = this.cmZoom;
            this.tbToolBar.Buttons.Add(tbbZoom);
            this.Controls.Add(this.tbToolBar);
            #endregion

            // Initialize MenuControl
            this.mcMenuControl      = new Crownwood.Magic.Menus.MenuControl();
            this.mcMenuControl.Dock = DockStyle.Top;
            this.Controls.Add(mcMenuControl);

            #region Initialize this.mcFile

            mcFile = new Crownwood.Magic.Menus.MenuCommand("&File");

            mcFileExport          = new Crownwood.Magic.Menus.MenuCommand("&Export...");
            mcFileExport.Shortcut = Shortcut.CtrlE;
            mcFileExport.Click   += new EventHandler(mcFileExport_Click);
            mcFile.MenuCommands.Add(mcFileExport);

            mcFileSeparator1 = new Crownwood.Magic.Menus.MenuCommand("-");
            mcFile.MenuCommands.Add(mcFileSeparator1);

            mcFileClose        = new Crownwood.Magic.Menus.MenuCommand("&Close");
            mcFileClose.Click += new EventHandler(mcFileClose_Click);
            mcFile.MenuCommands.Add(mcFileClose);

            this.mcMenuControl.MenuCommands.Add(mcFile);

            #endregion

            #region Initialize this.mcEdit

            mcEdit = new Crownwood.Magic.Menus.MenuCommand("&Edit");

            mcEditUndo            = new Crownwood.Magic.Menus.MenuCommand("&Undo");
            mcEditUndo.Click     += new EventHandler(mcEditUndo_Click);
            mcEditUndo.ImageList  = ilMenu;
            mcEditUndo.ImageIndex = 4;
            mcEditUndo.Shortcut   = Shortcut.CtrlZ;
            mcEditUndo.Enabled    = false;
            mcEdit.MenuCommands.Add(mcEditUndo);

            mcEditRedo            = new Crownwood.Magic.Menus.MenuCommand("&Redo");
            mcEditRedo.Click     += new EventHandler(mcEditRedo_Click);
            mcEditRedo.ImageList  = ilMenu;
            mcEditRedo.ImageIndex = 5;
            mcEditRedo.Shortcut   = Shortcut.CtrlY;
            mcEditRedo.Enabled    = false;
            mcEdit.MenuCommands.Add(mcEditRedo);

            mcEditSeparator1 = new Crownwood.Magic.Menus.MenuCommand("-");
            mcEdit.MenuCommands.Add(mcEditSeparator1);

            mcEditCut            = new Crownwood.Magic.Menus.MenuCommand("Cu&t");
            mcEditCut.Click     += new EventHandler(mcEditCut_Click);
            mcEditCut.ImageList  = ilMenu;
            mcEditCut.ImageIndex = 6;
            mcEditCut.Shortcut   = Shortcut.CtrlX;
            mcEdit.MenuCommands.Add(mcEditCut);

            mcEditCopy            = new Crownwood.Magic.Menus.MenuCommand("&Copy");
            mcEditCopy.Click     += new EventHandler(mcEditCopy_Click);
            mcEditCopy.ImageList  = ilMenu;
            mcEditCopy.ImageIndex = 7;
            mcEditCopy.Shortcut   = Shortcut.CtrlC;
            mcEdit.MenuCommands.Add(mcEditCopy);

            mcEditPaste            = new Crownwood.Magic.Menus.MenuCommand("&Paste");
            mcEditPaste.Click     += new EventHandler(mcEditPaste_Click);
            mcEditPaste.ImageList  = ilMenu;
            mcEditPaste.ImageIndex = 8;
            mcEditPaste.Shortcut   = Shortcut.CtrlV;
            mcEdit.MenuCommands.Add(mcEditPaste);

            mcEditDelete            = new Crownwood.Magic.Menus.MenuCommand("&Delete");
            mcEditDelete.Click     += new EventHandler(mcEditDelete_Click);
            mcEditDelete.ImageList  = ilMenu;
            mcEditDelete.ImageIndex = 9;
            mcEditDelete.Shortcut   = Shortcut.Del;
            mcEdit.MenuCommands.Add(mcEditDelete);

            mcEditSeparator2 = new Crownwood.Magic.Menus.MenuCommand("-");
            mcEdit.MenuCommands.Add(mcEditSeparator2);

            mcEditCopyModel           = new Crownwood.Magic.Menus.MenuCommand("Copy &model");
            mcEditCopyModel.Click    += new EventHandler(mcEditCopyModel_Click);
            mcEditCopyModel.ImageList = ilMenu;
            //mcEditCopyModel.ImageIndex = 9;
            //mcEditCopyModel.Shortcut = Shortcut.Del;
            mcEdit.MenuCommands.Add(mcEditCopyModel);

            mcEditSeparator3 = new Crownwood.Magic.Menus.MenuCommand("-");
            mcEdit.MenuCommands.Add(mcEditSeparator3);

            mcEditGroup           = new Crownwood.Magic.Menus.MenuCommand("&Group");
            mcEditGroup.Click    += new EventHandler(mcEditGroup_Click);
            mcEditGroup.ImageList = ilMenu;
            //mcEditGroup.ImageIndex = 8;
            mcEditGroup.Shortcut = Shortcut.CtrlG;
            mcEdit.MenuCommands.Add(mcEditGroup);

            mcEditSeparator4 = new Crownwood.Magic.Menus.MenuCommand("-");
            mcEdit.MenuCommands.Add(mcEditSeparator4);

            mcEditSelectAll           = new Crownwood.Magic.Menus.MenuCommand("Select &All");
            mcEditSelectAll.Click    += new EventHandler(mcEditSelectAll_Click);
            mcEditSelectAll.ImageList = ilMenu;
            mcEditSelectAll.Shortcut  = Shortcut.CtrlA;
            mcEdit.MenuCommands.Add(mcEditSelectAll);

            this.mcMenuControl.MenuCommands.Add(mcEdit);

            #endregion

            #region Initialize this.mcView

            mcView = new Crownwood.Magic.Menus.MenuCommand("&View");

            foreach (Crownwood.Magic.Docking.Content c in this.dmDockingManager.Contents)
            {
                Crownwood.Magic.Menus.MenuCommand mc = new Crownwood.Magic.Menus.MenuCommand(c.Title);
                mc.Image  = c.ImageList.Images[c.ImageIndex];
                mc.Click += new EventHandler(mcViewContents_Click);
                mcView.MenuCommands.Add(mc);
            }

            this.mcMenuControl.MenuCommands.Add(mcView);

            #endregion


            #region Initialize ActionList
            // Initialize ActionList
            this.alMenuActionList.ImageList = this.ilMenu;

            this.aEditUndo.Checked    = false;
            this.aEditUndo.Enabled    = false;
            this.aEditUndo.Hint       = null;
            this.aEditUndo.Shortcut   = System.Windows.Forms.Shortcut.CtrlZ;
            this.aEditUndo.Tag        = null;
            this.aEditUndo.ImageIndex = 4;
            this.aEditUndo.Text       = mcEditUndo.Text;
            this.aEditUndo.Visible    = true;
            this.aEditUndo.Update    += new System.EventHandler(this.aEditUndo_Update);
            this.alMenuActionList.Actions.Add(this.aEditUndo);
            this.alMenuActionList.SetAction(this.mcEditUndo, this.aEditUndo);

            this.aEditRedo.Checked    = false;
            this.aEditRedo.Enabled    = false;
            this.aEditRedo.Hint       = null;
            this.aEditRedo.Shortcut   = System.Windows.Forms.Shortcut.CtrlY;
            this.aEditRedo.Tag        = null;
            this.aEditRedo.ImageIndex = 5;
            this.aEditRedo.Text       = mcEditRedo.Text;
            this.aEditRedo.Visible    = true;
            this.aEditRedo.Update    += new System.EventHandler(this.aEditRedo_Update);
            this.alMenuActionList.Actions.Add(this.aEditRedo);
            this.alMenuActionList.SetAction(this.mcEditRedo, this.aEditRedo);

            this.aEditDelete.Checked    = false;
            this.aEditDelete.Enabled    = false;
            this.aEditDelete.Hint       = null;
            this.aEditDelete.Shortcut   = System.Windows.Forms.Shortcut.Del;
            this.aEditDelete.Tag        = null;
            this.aEditDelete.ImageIndex = 9;
            this.aEditDelete.Text       = mcEditDelete.Text;
            this.aEditDelete.Visible    = true;
            this.aEditDelete.Update    += new System.EventHandler(this.aEditDelete_Update);
            this.alMenuActionList.Actions.Add(this.aEditDelete);
            this.alMenuActionList.SetAction(this.mcEditDelete, this.aEditDelete);

            this.aEditCut.Checked    = false;
            this.aEditCut.Enabled    = false;
            this.aEditCut.Hint       = null;
            this.aEditCut.Shortcut   = System.Windows.Forms.Shortcut.CtrlX;
            this.aEditCut.ImageIndex = 6;
            this.aEditCut.Tag        = null;
            this.aEditCut.Text       = mcEditCut.Text;
            this.aEditCut.Visible    = true;
            this.aEditCut.Update    += new System.EventHandler(this.aEditCut_Update);
            this.alMenuActionList.Actions.Add(this.aEditCut);
            this.alMenuActionList.SetAction(this.mcEditCut, this.aEditCut);

            this.aEditCopy.Checked    = false;
            this.aEditCopy.Enabled    = false;
            this.aEditCopy.Hint       = null;
            this.aEditCopy.Shortcut   = System.Windows.Forms.Shortcut.CtrlC;
            this.aEditCopy.ImageIndex = 7;
            this.aEditCopy.Tag        = null;
            this.aEditCopy.Text       = mcEditCopy.Text;
            this.aEditCopy.Visible    = true;
            this.aEditCopy.Update    += new System.EventHandler(this.aEditCopy_Update);
            this.alMenuActionList.Actions.Add(this.aEditCopy);
            this.alMenuActionList.SetAction(this.mcEditCopy, this.aEditCopy);

            this.aEditPaste.Checked    = false;
            this.aEditPaste.Enabled    = false;
            this.aEditPaste.Hint       = null;
            this.aEditPaste.Shortcut   = System.Windows.Forms.Shortcut.CtrlV;
            this.aEditPaste.ImageIndex = 8;
            this.aEditPaste.Tag        = null;
            this.aEditPaste.Text       = mcEditPaste.Text;
            this.aEditPaste.Visible    = true;
            this.aEditPaste.Update    += new System.EventHandler(this.aEditPaste_Update);
            this.alMenuActionList.Actions.Add(this.aEditPaste);
            this.alMenuActionList.SetAction(this.mcEditPaste, this.aEditPaste);

            this.aEditGroup.Checked    = false;
            this.aEditGroup.Enabled    = false;
            this.aEditGroup.Hint       = null;
            this.aEditGroup.Shortcut   = System.Windows.Forms.Shortcut.CtrlG;
            this.aEditGroup.ImageIndex = 12;
            this.aEditGroup.Tag        = null;
            this.aEditGroup.Text       = mcEditGroup.Text;
            this.aEditGroup.Visible    = true;
            this.aEditGroup.Update    += new System.EventHandler(this.aEditGroup_Update);
            this.alMenuActionList.Actions.Add(this.aEditGroup);
            this.alMenuActionList.SetAction(this.mcEditGroup, this.aEditGroup);

            #endregion

            // Initialize Undo/Redo context menus
            this.cmUndo.Popup += new EventHandler(cmUndo_Popup);
            this.cmRedo.Popup += new EventHandler(cmRedo_Popup);
        }