Exemple #1
0
        private void FormClaimNotSent_Load(object sender, System.EventArgs e)
        {
            SetFilterControlsAndAction(() => { FillGrid(); }
                                       , odDateRangePicker, comboClinicMulti, comboBoxInsFilter
                                       );
            odDateRangePicker.SetDateTimeTo(DateTime.Now.Date);
            odDateRangePicker.SetDateTimeFrom(odDateRangePicker.GetDateTimeTo().AddDays(-7));             //default to the previous week
            _listClaimSentEditUsers = Userods.GetUsersByPermission(Permissions.ClaimSentEdit, false);
            _listOldClaimTrackings  = ClaimTrackings.RefreshForUsers(ClaimTrackingType.ClaimUser, _listClaimSentEditUsers.Select(x => x.UserNum).ToList());
            _listNewClaimTrackings  = _listOldClaimTrackings.Select(x => x.Copy()).ToList();
            //Fill the Ins Filter box
            //comboBoxInsFilter.Items.Add(Lan.g(this,"All"));//always adding an 'All' option first
            foreach (ClaimNotSentStatuses claimStat in Enum.GetValues(typeof(ClaimNotSentStatuses)))
            {
                comboBoxInsFilter.Items.Add(claimStat);
            }
            comboBoxInsFilter.SelectedIndex = 0;          //Pre-select 'All' for the user
            //Fill the right-click menu for the grid
            List <MenuItem> listMenuItems = new List <MenuItem>();

            //The first item in the list will always exists, but we toggle it's visibility to only show when 1 row is selected.
            listMenuItems.Add(new MenuItem(Lan.g(this, "Go to Account"), new EventHandler(gridMain_RightClickHelper)));
            listMenuItems[0].Tag = 0;          //Tags are used to identify what to do in gridMain_RightClickHelper.
            Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(rightClickMenu);
            menuItemCollection.AddRange(listMenuItems.ToArray());
            rightClickMenu.Popup += new EventHandler((o, ea) => {
                rightClickMenu.MenuItems[0].Visible = (gridMain.SelectedIndices.Count() == 1);            //Only show 'Go to Account' when there is exactly 1 row selected.
            });
        }
Exemple #2
0
        public static void AddControlMenuItems(Menu.MenuItemCollection pParent, AemInstance pInstance)
        {
            List <MenuItem> menuItems = new List <MenuItem>();
            MenuItem        item;

            item        = new MenuItem();
            item.Text   = "Start instance";
            item.Click += new EventHandler(ControlStartInstance);
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Stop instance";
            item.Click += new EventHandler(ControlStopInstance);
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Kill instance";
            item.Click += new EventHandler(ControlKillInstance);
            menuItems.Add(item);

            foreach (MenuItem i in menuItems)
            {
                i.Tag = pInstance;
            }

            pParent.AddRange(menuItems.ToArray());
        }
Exemple #3
0
        private void FormEtrans835Edit_Load(object sender, EventArgs e)
        {
            if (_form835 != null && !_form835.IsDisposed)
            {
                if (!MsgBox.Show(this, true, "Opening another ERA will close the current ERA you already have open.  Continue?"))
                {
                    //Form already exists and user wants to keep current instance.
                    TranSetId835   = _form835.TranSetId835;
                    EtransCur      = _form835.EtransCur;
                    MessageText835 = _form835.MessageText835;
                }
                _form835.Close();     //Always close old form and open new form, so the new copy will come to front, since BringToFront() does not always work.
            }
            _form835 = this;          //Set the static variable to this form because we're always going to show this form even if they're viewing old information.
            List <Etrans835Attach> listAttached = Etrans835Attaches.GetForEtrans(EtransCur.EtransNum);

            _x835 = new X835(EtransCur, MessageText835, TranSetId835, listAttached);
            RefreshFromDb();
            FillAll();
            Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(gridClaimDetailsMenu);
            List <MenuItem>         listMenuItems      = new List <MenuItem>();

            listMenuItems.Add(new MenuItem(Lan.g(this, "Go to Account"), new EventHandler(gridClaimDetails_RightClickHelper)));
            listMenuItems.Add(new MenuItem(Lan.g(this, "Add Tracking Status"), new EventHandler(gridClaimDetails_RightClickHelper)));          //Enabled by default
            menuItemCollection.AddRange(listMenuItems.ToArray());
            gridClaimDetails.ContextMenu          = gridClaimDetailsMenu;
            gridClaimDetails.AllowSortingByColumn = true;
        }
Exemple #4
0
        public void MenuItemCollection_AddRange_NullValueInItems_ThrowsArgumentNullException()
        {
            var menu       = new SubMenu(new MenuItem[0]);
            var collection = new Menu.MenuItemCollection(menu);

            Assert.Throws <ArgumentNullException>("item", () => collection.AddRange(new MenuItem[] { null }));
        }
Exemple #5
0
        public void MenuItemCollection_AddRange_NullItems_ThrowsArgumentNullException()
        {
            var menu       = new SubMenu(Array.Empty <MenuItem>());
            var collection = new Menu.MenuItemCollection(menu);

            Assert.Throws <ArgumentNullException>("items", () => collection.AddRange(null));
        }
        private void FormClaimNotSent_Load(object sender, System.EventArgs e)
        {
            odDateRangePicker.SetDateTimeTo(DateTime.Now.Date);
            odDateRangePicker.SetDateTimeFrom(odDateRangePicker.GetDateTimeTo().AddDays(-7));             //default to the previous week
            _listClaimSentEditUsers = Userods.GetUsersByPermission(Permissions.ClaimSentEdit, false);
            _listOldClaimTrackings  = ClaimTrackings.RefreshForUsers(ClaimTrackingType.ClaimUser, _listClaimSentEditUsers.Select(x => x.UserNum).ToList());
            _listNewClaimTrackings  = _listOldClaimTrackings.Select(x => x.Copy()).ToList();
            //Fill the clinics combobox
            if (PrefC.HasClinicsEnabled)
            {
                _listClinics = Clinics.GetForUserod(Security.CurUser);
                comboBoxClinics.Items.Add(Lan.g(this, "All"));
                int curIndex = 0;              //start at 0 since we are adding an item
                if (!Security.CurUser.ClinicIsRestricted)
                {
                    comboBoxClinics.Items.Add(Lan.g(this, "Unassigned"));
                    curIndex++;                    //increment index after adding this option
                }
                for (int i = 0; i < _listClinics.Count; i++)
                {
                    curIndex++;
                    comboBoxClinics.Items.Add(_listClinics[i].Abbr);
                    if (Clinics.ClinicNum == 0)
                    {
                        comboBoxClinics.SelectedIndices.Clear();
                        comboBoxClinics.SetSelected(0, true);
                    }
                    if (_listClinics[i].ClinicNum == Clinics.ClinicNum)
                    {
                        comboBoxClinics.SelectedIndices.Clear();
                        comboBoxClinics.SetSelected(curIndex, true);
                    }
                }
            }
            else
            {
                labelClinics.Visible    = false;
                comboBoxClinics.Visible = false;
            }
            //Fill the Ins Filter box
            //comboBoxInsFilter.Items.Add(Lan.g(this,"All"));//always adding an 'All' option first
            foreach (ClaimNotSentStatuses claimStat in Enum.GetValues(typeof(ClaimNotSentStatuses)))
            {
                comboBoxInsFilter.Items.Add(claimStat);
            }
            comboBoxInsFilter.SelectedIndex = 0;          //Pre-select 'All' for the user
            //Fill the right-click menu for the grid
            List <MenuItem> listMenuItems = new List <MenuItem>();

            //The first item in the list will always exists, but we toggle it's visibility to only show when 1 row is selected.
            listMenuItems.Add(new MenuItem(Lan.g(this, "Go to Account"), new EventHandler(gridMain_RightClickHelper)));
            listMenuItems[0].Tag = 0;          //Tags are used to identify what to do in gridMain_RightClickHelper.
            Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(rightClickMenu);
            menuItemCollection.AddRange(listMenuItems.ToArray());
            rightClickMenu.Popup += new EventHandler((o, ea) => {
                rightClickMenu.MenuItems[0].Visible = (gridMain.SelectedIndices.Count() == 1);            //Only show 'Go to Account' when there is exactly 1 row selected.
            });
        }
Exemple #7
0
        public void MenuItemCollection_AddRange_Invoke_Success(MenuItem[] items)
        {
            var menu       = new SubMenu(new MenuItem[0]);
            var collection = new Menu.MenuItemCollection(menu);

            collection.AddRange(items);
            Assert.Equal(items.Length, collection.Count);
            Assert.Equal(items, collection.Cast <MenuItem>());
        }
Exemple #8
0
 private void FormBugSubmissions_Load(object sender, EventArgs e)
 {
     dateRangePicker.SetDateTimeFrom(DateTime.Today.AddDays(-60));
     dateRangePicker.SetDateTimeTo(DateTime.Today);
     #region comboGrouping
     comboGrouping.Items.Add("None");
     comboGrouping.Items.Add("Customer");
     comboGrouping.Items.Add("StackTrace");
     //comboGrouping.Items.Add("95%");
     comboGrouping.SelectedIndex = 0;          //Default to None.
     #endregion
     #region Right Click Menu
     ContextMenu             gridSubMenu        = new ContextMenu();
     Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(gridSubMenu);
     List <MenuItem>         listMenuItems      = new List <MenuItem>();
     listMenuItems.Add(new MenuItem(Lan.g(this, "Open Submission"), new EventHandler(gridClaimDetails_RightClickHelper)));
     listMenuItems.Add(new MenuItem(Lan.g(this, "Open Bug"), new EventHandler(gridClaimDetails_RightClickHelper)));          //Enabled by default
     menuItemCollection.AddRange(listMenuItems.ToArray());
     gridSubMenu.Popup += new EventHandler((o, ea) => {
         int index             = gridSubs.GetSelectedIndex();
         bool isOpenSubEnabled = false;
         bool isOpenBugEnabled = false;
         if (index != -1 && gridSubs.SelectedIndices.Count() == 1)
         {
             BugSubmission bugSub = ((List <BugSubmission>)gridSubs.Rows[index].Tag).First();
             isOpenSubEnabled     = true;
             isOpenBugEnabled     = (bugSub.BugId != 0);
         }
         gridSubMenu.MenuItems[0].Enabled = isOpenSubEnabled;              //Open Submission
         gridSubMenu.MenuItems[1].Enabled = isOpenBugEnabled;              //Open Bug
     });
     gridSubs.ContextMenu = gridSubMenu;
     #endregion
     FillSubGrid(true);
     if (_viewMode == FormBugSubmissionMode.ViewOnly)
     {
         butAddBug.Visible         = false;
         checkShowAttached.Checked = true;
     }
     else if (_viewMode == FormBugSubmissionMode.SelectionMode)
     {
         butAddBug.Text = "OK";              //On click the selected rows are saved and this form will close.
     }
     else if (_viewMode == FormBugSubmissionMode.ValidationMode)
     {
         butAddBug.Text            = "OK";
         checkShowAttached.Checked = true;
         groupFilters.Enabled      = false;
     }
 }
Exemple #9
0
        public static void AddOpenMenuItems(Menu.MenuItemCollection pParent, AemInstance pInstance, bool pSetDefaultItem)
        {
            List <MenuItem> menuItems = new List <MenuItem>();
            MenuItem        item;

            item        = new MenuItem();
            item.Text   = "Open Author/Publish";
            item.Click += new EventHandler(OpenAuthorPublish);
            if (pSetDefaultItem)
            {
                item.DefaultItem = true;
            }
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Open CRX";
            item.Click += new EventHandler(OpenCRX);
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Open CRXDE Lite";
            item.Click += new EventHandler(OpenCRXDELite);
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Open Felix Console";
            item.Click += new EventHandler(OpenFelixConsole);
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Open Folder";
            item.Click += new EventHandler(OpenFolder);
            menuItems.Add(item);

            if (pInstance.AemInstanceType == AemInstanceType.AEM54)
            {
                item        = new MenuItem();
                item.Text   = "Open Servlet Engine Admin";
                item.Click += new EventHandler(OpenServletEngineAdmin);
                menuItems.Add(item);
            }

            foreach (MenuItem i in menuItems)
            {
                i.Tag = pInstance;
            }

            pParent.AddRange(menuItems.ToArray());
        }
Exemple #10
0
        public static void AddLogMenuItems(Menu.MenuItemCollection pParent, AemInstance pInstance)
        {
            List <MenuItem> menuItems = new List <MenuItem>();
            MenuItem        item;

            // show dynamic list of current logfiles
            item        = new MenuItem();
            item.Text   = "Open logfile...";
            item.Popup += LogFilesItem_Popup;
            item.MenuItems.Add(new MenuItem("-- No logfiles --"));
            menuItems.Add(item);

            item        = new MenuItem();
            item.Text   = "Console window";
            item.Click += new EventHandler(ShowConsoleWindow);
            menuItems.Add(item);

            foreach (MenuItem i in menuItems)
            {
                i.Tag = pInstance;
            }

            pParent.AddRange(menuItems.ToArray());
        }
        private void FormBugSubmissions_Load(object sender, EventArgs e)
        {
            SetFilterControlsAndAction(() => FillSubGrid(),
                                       textDevNoteFilter, textPatNums, textStackFilter, textMsgText, textCategoryFilters, listShowHideOptions);
            switch (_viewMode)
            {
            case FormBugSubmissionMode.AddBug:
                dateRangePicker.SetDateTimeFrom(DateTime.Today.AddDays(-60));
                dateRangePicker.SetDateTimeTo(DateTime.Today);
                break;

            case FormBugSubmissionMode.ViewOnly:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1));                        //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Visible = false;
                listShowHideOptions.SetSelected(1, true);
                break;

            case FormBugSubmissionMode.SelectionMode:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1)); //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Text = "OK";                                        //On click the selected rows are saved and this form will close.
                break;

            case FormBugSubmissionMode.ValidationMode:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1));                        //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Text = "OK";
                listShowHideOptions.SetSelected(1, true);
                groupFilters.Enabled = false;
                break;
            }
            bugSubmissionControl.TextDevNoteLeave            += textDevNote_PostLeave;
            bugSubmissionControl.OnGridCustomerSubsCellClick += customerSubsGridClick;
            #region comboGrouping
            comboGrouping.Items.Add("None");
            comboGrouping.Items.Add("RegKey/Ver/Stack");
            comboGrouping.Items.Add("StackTrace");
            comboGrouping.Items.Add("95%");
            comboGrouping.Items.Add("StackSig");
            comboGrouping.Items.Add("StackSimple");
            comboGrouping.Items.Add("Hash");
            switch (_viewMode)
            {
            case FormBugSubmissionMode.AddBug:
                comboGrouping.SelectedIndex = 2;                      //Default to StackTrace.
                break;

            case FormBugSubmissionMode.SelectionMode:
            case FormBugSubmissionMode.ValidationMode:
            case FormBugSubmissionMode.ViewOnly:
                comboGrouping.SelectedIndex = 0;                      //Default to None.
                break;
            }
            #endregion
            #region comboSortBy
            comboSortBy.Items.Add("Vers./Count");
            comboSortBy.SelectedIndex = 0;          //Default to Vers./Count
            #endregion
            #region Right Click Menu
            ContextMenu             gridSubMenu        = new ContextMenu();
            Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(gridSubMenu);
            List <MenuItem>         listMenuItems      = new List <MenuItem>();
            listMenuItems.Add(new MenuItem(Lan.g(this, "Open Submission"), new EventHandler(gridSubs_RightClickHelper)));
            listMenuItems.Add(new MenuItem(Lan.g(this, "Open Bug"), new EventHandler(gridSubs_RightClickHelper)));          //Enabled by default
            listMenuItems.Add(new MenuItem(Lan.g(this, "Hide"), new EventHandler(gridSubs_RightClickHelper)));
            listMenuItems.Add(new MenuItem(Lan.g(this, "Link Bug"), new EventHandler(gridSubs_RightClickHelper)));
            menuItemCollection.AddRange(listMenuItems.ToArray());
            gridSubMenu.Popup += new EventHandler((o, ea) => {
                int index             = gridSubs.GetSelectedIndex();
                bool isSingleSubRow   = false;
                bool isOpenBugEnabled = false;
                if (index != -1 && gridSubs.SelectedIndices.Count() == 1)
                {
                    BugSubmission bugSub          = ((List <BugSubmission>)gridSubs.ListGridRows[index].Tag).First();
                    isSingleSubRow                = true;
                    isOpenBugEnabled              = (bugSub.BugId != 0);
                    gridSubMenu.MenuItems[2].Text = (bugSub.IsHidden?"Unhide":"Hide");
                    gridSubMenu.MenuItems[3].Text = (isOpenBugEnabled?"UnLink Bug":"Link Bug");
                }
                gridSubMenu.MenuItems[0].Enabled = isSingleSubRow;    //Open Submission
                gridSubMenu.MenuItems[1].Enabled = isOpenBugEnabled;  //Open Bug
                gridSubMenu.MenuItems[2].Enabled = true;              //Hide or Unhide Submissions always an option, even with multiple rows.
                gridSubMenu.MenuItems[3].Enabled = true;              //Link or Unlink bug always an option, even with multiple rows.
            });
            gridSubs.ContextMenu = gridSubMenu;
            #endregion
            FillVersionsFilter();
            FillSubGrid(true);
        }
        private void InitializeComponent()
        {
            this.MainMenu1          = new MainMenu();
            this.MenuItem1          = new MenuItem();
            this.MenuDragonPath     = new MenuItem();
            this.MenuDragonFile     = new MenuItem();
            this.MenuItem2          = new MenuItem();
            this.MenuUOLPath        = new MenuItem();
            this.MenuUOLProjectName = new MenuItem();
            this.MenuConv           = new MenuItem();
            this.Label1             = new Label();
            this.DragonPath         = new TextBox();
            this.Label2             = new Label();
            this.DragonImage        = new TextBox();
            this.GroupBox1          = new GroupBox();
            this.Label3             = new Label();
            this.ComboBox1          = new ComboBox();
            this.GroupBox2          = new GroupBox();
            this.Label4             = new Label();
            this.ProjectPath        = new TextBox();
            this.Label5             = new Label();
            this.ProjectName        = new TextBox();
            this.Label7             = new Label();
            this.TerrainFile        = new TextBox();
            this.Label6             = new Label();
            this.AltitudeFile       = new TextBox();
            this.ProgressBar1       = new ProgressBar();
            this.GroupBox1.SuspendLayout();
            this.GroupBox2.SuspendLayout();
            this.SuspendLayout();
            Menu.MenuItemCollection menuItems = this.MainMenu1.get_MenuItems();
            MenuItem[] menuItem1 = new MenuItem[] { this.MenuItem1, this.MenuItem2, this.MenuConv };
            menuItems.AddRange(menuItem1);
            this.MenuItem1.set_Index(0);
            Menu.MenuItemCollection menuItemCollection = this.MenuItem1.get_MenuItems();
            menuItem1 = new MenuItem[] { this.MenuDragonPath, this.MenuDragonFile };
            menuItemCollection.AddRange(menuItem1);
            this.MenuItem1.set_Text("Dragon");
            this.MenuDragonPath.set_Index(0);
            this.MenuDragonPath.set_Text("Select Path");
            this.MenuDragonFile.set_Index(1);
            this.MenuDragonFile.set_Text("Select Map File");
            this.MenuItem2.set_Index(1);
            Menu.MenuItemCollection menuItems1 = this.MenuItem2.get_MenuItems();
            menuItem1 = new MenuItem[] { this.MenuUOLPath, this.MenuUOLProjectName };
            menuItems1.AddRange(menuItem1);
            this.MenuItem2.set_Text("UO Landscaper");
            this.MenuUOLPath.set_Index(0);
            this.MenuUOLPath.set_Text("Select Path");
            this.MenuUOLProjectName.set_Index(1);
            this.MenuUOLProjectName.set_Text("Select Project Name");
            this.MenuConv.set_Index(2);
            this.MenuConv.set_Text("Convert");
            this.Label1.set_AutoSize(true);
            Label label1 = this.Label1;
            Point point  = new Point(8, 16);

            label1.set_Location(point);
            this.Label1.set_Name("Label1");
            Label label = this.Label1;
            Size  size  = new Size(27, 16);

            label.set_Size(size);
            this.Label1.set_TabIndex(0);
            this.Label1.set_Text("Path");
            TextBox dragonPath = this.DragonPath;

            point = new Point(24, 32);
            dragonPath.set_Location(point);
            this.DragonPath.set_Name("DragonPath");
            TextBox textBox = this.DragonPath;

            size = new Size(240, 20);
            textBox.set_Size(size);
            this.DragonPath.set_TabIndex(1);
            this.DragonPath.set_Text("");
            this.Label2.set_AutoSize(true);
            Label label2 = this.Label2;

            point = new Point(8, 56);
            label2.set_Location(point);
            this.Label2.set_Name("Label2");
            Label label21 = this.Label2;

            size = new Size(61, 16);
            label21.set_Size(size);
            this.Label2.set_TabIndex(2);
            this.Label2.set_Text("Map Image");
            TextBox dragonImage = this.DragonImage;

            point = new Point(24, 72);
            dragonImage.set_Location(point);
            this.DragonImage.set_Name("DragonImage");
            TextBox dragonImage1 = this.DragonImage;

            size = new Size(104, 20);
            dragonImage1.set_Size(size);
            this.DragonImage.set_TabIndex(3);
            this.DragonImage.set_Text("");
            this.GroupBox1.get_Controls().Add(this.Label3);
            this.GroupBox1.get_Controls().Add(this.Label1);
            this.GroupBox1.get_Controls().Add(this.DragonPath);
            this.GroupBox1.get_Controls().Add(this.DragonImage);
            this.GroupBox1.get_Controls().Add(this.Label2);
            this.GroupBox1.get_Controls().Add(this.ComboBox1);
            GroupBox groupBox1 = this.GroupBox1;

            point = new Point(8, 8);
            groupBox1.set_Location(point);
            this.GroupBox1.set_Name("GroupBox1");
            GroupBox groupBox = this.GroupBox1;

            size = new Size(272, 144);
            groupBox.set_Size(size);
            this.GroupBox1.set_TabIndex(4);
            this.GroupBox1.set_TabStop(false);
            this.GroupBox1.set_Text("Dragon Image Info");
            this.Label3.set_AutoSize(true);
            Label label3 = this.Label3;

            point = new Point(8, 96);
            label3.set_Location(point);
            this.Label3.set_Name("Label3");
            Label label31 = this.Label3;

            size = new Size(93, 16);
            label31.set_Size(size);
            this.Label3.set_TabIndex(4);
            this.Label3.set_Text("Select MOD Type");
            ComboBox comboBox1 = this.ComboBox1;

            point = new Point(24, 112);
            comboBox1.set_Location(point);
            this.ComboBox1.set_Name("ComboBox1");
            ComboBox comboBox = this.ComboBox1;

            size = new Size(136, 21);
            comboBox.set_Size(size);
            this.ComboBox1.set_TabIndex(7);
            this.GroupBox2.get_Controls().Add(this.Label4);
            this.GroupBox2.get_Controls().Add(this.ProjectPath);
            this.GroupBox2.get_Controls().Add(this.Label5);
            this.GroupBox2.get_Controls().Add(this.ProjectName);
            this.GroupBox2.get_Controls().Add(this.Label7);
            this.GroupBox2.get_Controls().Add(this.TerrainFile);
            this.GroupBox2.get_Controls().Add(this.Label6);
            this.GroupBox2.get_Controls().Add(this.AltitudeFile);
            GroupBox groupBox2 = this.GroupBox2;

            point = new Point(8, 160);
            groupBox2.set_Location(point);
            this.GroupBox2.set_Name("GroupBox2");
            GroupBox groupBox21 = this.GroupBox2;

            size = new Size(272, 184);
            groupBox21.set_Size(size);
            this.GroupBox2.set_TabIndex(5);
            this.GroupBox2.set_TabStop(false);
            this.GroupBox2.set_Text("UO Landscaper Info");
            this.Label4.set_AutoSize(true);
            Label label4 = this.Label4;

            point = new Point(8, 16);
            label4.set_Location(point);
            this.Label4.set_Name("Label4");
            Label label41 = this.Label4;

            size = new Size(31, 16);
            label41.set_Size(size);
            this.Label4.set_TabIndex(35);
            this.Label4.set_Text("Path:");
            TextBox projectPath = this.ProjectPath;

            point = new Point(24, 32);
            projectPath.set_Location(point);
            this.ProjectPath.set_Name("ProjectPath");
            TextBox projectPath1 = this.ProjectPath;

            size = new Size(240, 20);
            projectPath1.set_Size(size);
            this.ProjectPath.set_TabIndex(34);
            this.ProjectPath.set_Text("");
            this.Label5.set_AutoSize(true);
            Label label5 = this.Label5;

            point = new Point(8, 56);
            label5.set_Location(point);
            this.Label5.set_Name("Label5");
            Label label51 = this.Label5;

            size = new Size(73, 16);
            label51.set_Size(size);
            this.Label5.set_TabIndex(51);
            this.Label5.set_Text("Project Name");
            TextBox projectName = this.ProjectName;

            point = new Point(24, 72);
            projectName.set_Location(point);
            this.ProjectName.set_Name("ProjectName");
            TextBox projectName1 = this.ProjectName;

            size = new Size(136, 20);
            projectName1.set_Size(size);
            this.ProjectName.set_TabIndex(52);
            this.ProjectName.set_Text("");
            this.Label7.set_AutoSize(true);
            Label label7 = this.Label7;

            point = new Point(8, 96);
            label7.set_Location(point);
            this.Label7.set_Name("Label7");
            this.Label7.set_TabIndex(57);
            this.Label7.set_Text("Terrain Image Map");
            TextBox terrainFile = this.TerrainFile;

            point = new Point(24, 112);
            terrainFile.set_Location(point);
            this.TerrainFile.set_Name("TerrainFile");
            TextBox terrainFile1 = this.TerrainFile;

            size = new Size(104, 20);
            terrainFile1.set_Size(size);
            this.TerrainFile.set_TabIndex(54);
            this.TerrainFile.set_Text("Terrain.bmp");
            this.Label6.set_AutoSize(true);
            Label label6 = this.Label6;

            point = new Point(8, 136);
            label6.set_Location(point);
            this.Label6.set_Name("Label6");
            Label label61 = this.Label6;

            size = new Size(102, 16);
            label61.set_Size(size);
            this.Label6.set_TabIndex(58);
            this.Label6.set_Text("Altitude Image Map");
            TextBox altitudeFile = this.AltitudeFile;

            point = new Point(24, 152);
            altitudeFile.set_Location(point);
            this.AltitudeFile.set_Name("AltitudeFile");
            TextBox altitudeFile1 = this.AltitudeFile;

            size = new Size(104, 20);
            altitudeFile1.set_Size(size);
            this.AltitudeFile.set_TabIndex(56);
            this.AltitudeFile.set_Text("Altitude.bmp");
            this.ProgressBar1.set_Dock(2);
            ProgressBar progressBar1 = this.ProgressBar1;

            point = new Point(0, 351);
            progressBar1.set_Location(point);
            this.ProgressBar1.set_Name("ProgressBar1");
            ProgressBar progressBar = this.ProgressBar1;

            size = new Size(286, 16);
            progressBar.set_Size(size);
            this.ProgressBar1.set_TabIndex(6);
            size = new Size(5, 13);
            this.set_AutoScaleBaseSize(size);
            this.set_BackColor(Color.FromArgb(224, 224, 224));
            size = new Size(286, 367);
            this.set_ClientSize(size);
            this.get_Controls().Add(this.ProgressBar1);
            this.get_Controls().Add(this.GroupBox2);
            this.get_Controls().Add(this.GroupBox1);
            this.set_FormBorderStyle(2);
            this.set_Menu(this.MainMenu1);
            this.set_Name("DragonConv");
            this.set_Text("Dragon to UO Landscaper Image Convertor");
            this.GroupBox1.ResumeLayout(false);
            this.GroupBox2.ResumeLayout(false);
            this.ResumeLayout(false);
        }
        private void FormBugSubmissions_Load(object sender, EventArgs e)
        {
            switch (_viewMode)
            {
            case FormBugSubmissionMode.AddBug:
                dateRangePicker.SetDateTimeFrom(DateTime.Today.AddDays(-60));
                dateRangePicker.SetDateTimeTo(DateTime.Today);
                break;

            case FormBugSubmissionMode.ViewOnly:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1));                        //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Visible         = false;
                checkShowAttached.Checked = true;
                break;

            case FormBugSubmissionMode.SelectionMode:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1)); //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Text = "OK";                                        //On click the selected rows are saved and this form will close.
                break;

            case FormBugSubmissionMode.ValidationMode:
                dateRangePicker.SetDateTimeFrom(DateTime.MinValue);
                dateRangePicker.SetDateTimeTo(DateTime.MaxValue.AddDays(-1));                        //Subtract a day for DbHelper.DateTConditionColumn(...)
                butAddJob.Text            = "OK";
                checkShowAttached.Checked = true;
                groupFilters.Enabled      = false;
                break;
            }
            bugSubmissionControl.TextDevNoteLeave += textDevNote_PostLeave;
            #region comboGrouping
            comboGrouping.Items.Add("None");
            comboGrouping.Items.Add("RegKey/Ver/Stack");
            comboGrouping.Items.Add("StackTrace");
            comboGrouping.Items.Add("95%");
            switch (_viewMode)
            {
            case FormBugSubmissionMode.AddBug:
                comboGrouping.SelectedIndex = 2;                      //Default to StackTrace.
                break;

            case FormBugSubmissionMode.SelectionMode:
            case FormBugSubmissionMode.ValidationMode:
            case FormBugSubmissionMode.ViewOnly:
                comboGrouping.SelectedIndex = 0;                      //Default to None.
                break;
            }
            #endregion
            #region comboSortBy
            comboSortBy.Items.Add("Vers./Count");
            comboSortBy.SelectedIndex = 0;          //Default to Vers./Count
            #endregion
            #region Right Click Menu
            ContextMenu             gridSubMenu        = new ContextMenu();
            Menu.MenuItemCollection menuItemCollection = new Menu.MenuItemCollection(gridSubMenu);
            List <MenuItem>         listMenuItems      = new List <MenuItem>();
            listMenuItems.Add(new MenuItem(Lan.g(this, "Open Submission"), new EventHandler(gridClaimDetails_RightClickHelper)));
            listMenuItems.Add(new MenuItem(Lan.g(this, "Open Bug"), new EventHandler(gridClaimDetails_RightClickHelper)));          //Enabled by default
            menuItemCollection.AddRange(listMenuItems.ToArray());
            gridSubMenu.Popup += new EventHandler((o, ea) => {
                int index             = gridSubs.GetSelectedIndex();
                bool isOpenSubEnabled = false;
                bool isOpenBugEnabled = false;
                if (index != -1 && gridSubs.SelectedIndices.Count() == 1)
                {
                    BugSubmission bugSub = ((List <BugSubmission>)gridSubs.Rows[index].Tag).First();
                    isOpenSubEnabled     = true;
                    isOpenBugEnabled     = (bugSub.BugId != 0);
                }
                gridSubMenu.MenuItems[0].Enabled = isOpenSubEnabled;              //Open Submission
                gridSubMenu.MenuItems[1].Enabled = isOpenBugEnabled;              //Open Bug
            });
            gridSubs.ContextMenu = gridSubMenu;
            #endregion
            FillSubGrid(true);
        }