BGE: Add chgid property to make its value accessible throughout user interface

BGE: Change Id support, allow modify & clear if format has ‘ChangeIds’
This commit is contained in:
Kathy Ruffing 2014-05-07 13:39:15 +00:00
parent 9efa23fffc
commit b48a813a85
3 changed files with 95 additions and 44 deletions

View File

@ -103,6 +103,12 @@ namespace Volian.Controls.Library
get { return _MyCopyStep; }
set { _MyCopyStep = value; }
}
private string _ChgId;
public string ChgId
{
get { return _ChgId; }
set { _ChgId = value; }
}
#endregion
#region Events
/// <summary>

View File

@ -43,6 +43,8 @@ namespace Volian.Controls.Library
this.superTooltipTags = new DevComponents.DotNetBar.SuperTooltip();
this.groupPanelIncludeOn = new DevComponents.DotNetBar.Controls.GroupPanel();
this.cbPlaceKeeper = new DevComponents.DotNetBar.Controls.CheckBoxX();
this.lblChgId = new System.Windows.Forms.Label();
this.tbChgID = new System.Windows.Forms.TextBox();
this.groupPanelPaginate.SuspendLayout();
this.groupPanelCheckoff.SuspendLayout();
this.groupPanelChgBar.SuspendLayout();
@ -57,10 +59,10 @@ namespace Volian.Controls.Library
this.groupPanelPaginate.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
this.groupPanelPaginate.Controls.Add(this.cbPageBreak);
this.groupPanelPaginate.Dock = System.Windows.Forms.DockStyle.Top;
this.groupPanelPaginate.Location = new System.Drawing.Point(0, 303);
this.groupPanelPaginate.Margin = new System.Windows.Forms.Padding(2);
this.groupPanelPaginate.Location = new System.Drawing.Point(0, 406);
this.groupPanelPaginate.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupPanelPaginate.Name = "groupPanelPaginate";
this.groupPanelPaginate.Size = new System.Drawing.Size(172, 58);
this.groupPanelPaginate.Size = new System.Drawing.Size(229, 71);
//
//
//
@ -99,10 +101,10 @@ namespace Volian.Controls.Library
//
//
this.cbPageBreak.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.cbPageBreak.Location = new System.Drawing.Point(3, 11);
this.cbPageBreak.Margin = new System.Windows.Forms.Padding(2);
this.cbPageBreak.Location = new System.Drawing.Point(4, 14);
this.cbPageBreak.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cbPageBreak.Name = "cbPageBreak";
this.cbPageBreak.Size = new System.Drawing.Size(122, 15);
this.cbPageBreak.Size = new System.Drawing.Size(140, 17);
this.superTooltipTags.SetSuperTooltip(this.cbPageBreak, new DevComponents.DotNetBar.SuperTooltipInfo("Manual Page Break", "", "When set, starts this step at the top of a page.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.cbPageBreak.TabIndex = 0;
this.cbPageBreak.Text = "Manual Page Break";
@ -116,10 +118,10 @@ namespace Volian.Controls.Library
//
//
this.cbCAS.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.cbCAS.Location = new System.Drawing.Point(3, 14);
this.cbCAS.Margin = new System.Windows.Forms.Padding(2);
this.cbCAS.Location = new System.Drawing.Point(4, 17);
this.cbCAS.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cbCAS.Name = "cbCAS";
this.cbCAS.Size = new System.Drawing.Size(162, 15);
this.cbCAS.Size = new System.Drawing.Size(187, 17);
this.superTooltipTags.SetSuperTooltip(this.cbCAS, new DevComponents.DotNetBar.SuperTooltipInfo("Continuous Action Summary", "", "Include this in the Continuous Action Summary section", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.cbCAS.TabIndex = 1;
this.cbCAS.Text = "Continuous Action Summary";
@ -134,10 +136,10 @@ namespace Volian.Controls.Library
this.cmbCheckoff.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cmbCheckoff.FormattingEnabled = true;
this.cmbCheckoff.ItemHeight = 17;
this.cmbCheckoff.Location = new System.Drawing.Point(3, 17);
this.cmbCheckoff.Margin = new System.Windows.Forms.Padding(2);
this.cmbCheckoff.Location = new System.Drawing.Point(4, 21);
this.cmbCheckoff.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cmbCheckoff.Name = "cmbCheckoff";
this.cmbCheckoff.Size = new System.Drawing.Size(164, 23);
this.cmbCheckoff.Size = new System.Drawing.Size(217, 23);
this.cmbCheckoff.TabIndex = 0;
this.cmbCheckoff.WatermarkFont = new System.Drawing.Font("Microsoft Sans Serif", 7.8F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.cmbCheckoff.WatermarkText = "select signoff / checkoff";
@ -149,10 +151,10 @@ namespace Volian.Controls.Library
this.groupPanelCheckoff.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
this.groupPanelCheckoff.Controls.Add(this.cmbCheckoff);
this.groupPanelCheckoff.Dock = System.Windows.Forms.DockStyle.Top;
this.groupPanelCheckoff.Location = new System.Drawing.Point(0, 145);
this.groupPanelCheckoff.Margin = new System.Windows.Forms.Padding(2);
this.groupPanelCheckoff.Location = new System.Drawing.Point(0, 178);
this.groupPanelCheckoff.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupPanelCheckoff.Name = "groupPanelCheckoff";
this.groupPanelCheckoff.Size = new System.Drawing.Size(172, 77);
this.groupPanelCheckoff.Size = new System.Drawing.Size(229, 95);
//
//
//
@ -190,13 +192,15 @@ namespace Volian.Controls.Library
this.groupPanelChgBar.BackColor = System.Drawing.Color.Transparent;
this.groupPanelChgBar.CanvasColor = System.Drawing.SystemColors.Control;
this.groupPanelChgBar.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
this.groupPanelChgBar.Controls.Add(this.tbChgID);
this.groupPanelChgBar.Controls.Add(this.lblChgId);
this.groupPanelChgBar.Controls.Add(this.rbChgBarOff);
this.groupPanelChgBar.Controls.Add(this.rbChgBarOn);
this.groupPanelChgBar.Dock = System.Windows.Forms.DockStyle.Top;
this.groupPanelChgBar.Location = new System.Drawing.Point(0, 222);
this.groupPanelChgBar.Margin = new System.Windows.Forms.Padding(2);
this.groupPanelChgBar.Location = new System.Drawing.Point(0, 273);
this.groupPanelChgBar.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupPanelChgBar.Name = "groupPanelChgBar";
this.groupPanelChgBar.Size = new System.Drawing.Size(172, 81);
this.groupPanelChgBar.Size = new System.Drawing.Size(229, 133);
//
//
//
@ -231,10 +235,10 @@ namespace Volian.Controls.Library
// rbChgBarOff
//
this.rbChgBarOff.AutoSize = true;
this.rbChgBarOff.Location = new System.Drawing.Point(3, 35);
this.rbChgBarOff.Margin = new System.Windows.Forms.Padding(2);
this.rbChgBarOff.Location = new System.Drawing.Point(0, 32);
this.rbChgBarOff.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.rbChgBarOff.Name = "rbChgBarOff";
this.rbChgBarOff.Size = new System.Drawing.Size(45, 17);
this.rbChgBarOff.Size = new System.Drawing.Size(56, 21);
this.superTooltipTags.SetSuperTooltip(this.rbChgBarOff, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar OFF", "", "Turn change bar off. Note that \'OVERRIDE\' will turn off a change bar even though" +
" text is changed.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.rbChgBarOff.TabIndex = 2;
@ -246,10 +250,10 @@ namespace Volian.Controls.Library
// rbChgBarOn
//
this.rbChgBarOn.AutoSize = true;
this.rbChgBarOn.Location = new System.Drawing.Point(3, 13);
this.rbChgBarOn.Margin = new System.Windows.Forms.Padding(2);
this.rbChgBarOn.Location = new System.Drawing.Point(0, 5);
this.rbChgBarOn.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.rbChgBarOn.Name = "rbChgBarOn";
this.rbChgBarOn.Size = new System.Drawing.Size(41, 17);
this.rbChgBarOn.Size = new System.Drawing.Size(50, 21);
this.superTooltipTags.SetSuperTooltip(this.rbChgBarOn, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar ON", "", "Add a change bar on this step", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.rbChgBarOn.TabIndex = 1;
this.rbChgBarOn.TabStop = true;
@ -267,9 +271,9 @@ namespace Volian.Controls.Library
this.groupPanelChgStepType.Controls.Add(this.listBoxStepTypes);
this.groupPanelChgStepType.Dock = System.Windows.Forms.DockStyle.Top;
this.groupPanelChgStepType.Location = new System.Drawing.Point(0, 0);
this.groupPanelChgStepType.Margin = new System.Windows.Forms.Padding(2);
this.groupPanelChgStepType.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupPanelChgStepType.Name = "groupPanelChgStepType";
this.groupPanelChgStepType.Size = new System.Drawing.Size(172, 145);
this.groupPanelChgStepType.Size = new System.Drawing.Size(229, 178);
//
//
//
@ -311,20 +315,20 @@ namespace Volian.Controls.Library
//
this.lblNoTypeChgReason.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.lblNoTypeChgReason.ForeColor = System.Drawing.Color.Red;
this.lblNoTypeChgReason.Location = new System.Drawing.Point(2, 28);
this.lblNoTypeChgReason.Margin = new System.Windows.Forms.Padding(2);
this.lblNoTypeChgReason.Location = new System.Drawing.Point(3, 34);
this.lblNoTypeChgReason.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.lblNoTypeChgReason.Name = "lblNoTypeChgReason";
this.lblNoTypeChgReason.Size = new System.Drawing.Size(164, 96);
this.lblNoTypeChgReason.Size = new System.Drawing.Size(219, 118);
this.lblNoTypeChgReason.TabIndex = 5;
//
// cbChgAll
//
this.cbChgAll.AutoSize = true;
this.cbChgAll.BackColor = System.Drawing.Color.Transparent;
this.cbChgAll.Location = new System.Drawing.Point(2, 6);
this.cbChgAll.Margin = new System.Windows.Forms.Padding(2);
this.cbChgAll.Location = new System.Drawing.Point(3, 7);
this.cbChgAll.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cbChgAll.Name = "cbChgAll";
this.cbChgAll.Size = new System.Drawing.Size(119, 17);
this.cbChgAll.Size = new System.Drawing.Size(153, 21);
this.superTooltipTags.SetSuperTooltip(this.cbChgAll, new DevComponents.DotNetBar.SuperTooltipInfo("Change Step Type - All At Level", "", "When checked, all steps at the level of current step will have their step type ch" +
"anged to the selected type in list below...", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.cbChgAll.TabIndex = 4;
@ -336,10 +340,11 @@ namespace Volian.Controls.Library
this.listBoxStepTypes.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.listBoxStepTypes.FormattingEnabled = true;
this.listBoxStepTypes.Location = new System.Drawing.Point(2, 28);
this.listBoxStepTypes.Margin = new System.Windows.Forms.Padding(2);
this.listBoxStepTypes.ItemHeight = 16;
this.listBoxStepTypes.Location = new System.Drawing.Point(3, 34);
this.listBoxStepTypes.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.listBoxStepTypes.Name = "listBoxStepTypes";
this.listBoxStepTypes.Size = new System.Drawing.Size(164, 95);
this.listBoxStepTypes.Size = new System.Drawing.Size(217, 116);
this.superTooltipTags.SetSuperTooltip(this.listBoxStepTypes, new DevComponents.DotNetBar.SuperTooltipInfo("Possible Step Types", "", "This list allows change of type showing all selections of any possible step type " +
"for the current step.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
this.listBoxStepTypes.TabIndex = 3;
@ -357,10 +362,10 @@ namespace Volian.Controls.Library
this.groupPanelIncludeOn.Controls.Add(this.cbPlaceKeeper);
this.groupPanelIncludeOn.Controls.Add(this.cbCAS);
this.groupPanelIncludeOn.Dock = System.Windows.Forms.DockStyle.Top;
this.groupPanelIncludeOn.Location = new System.Drawing.Point(0, 361);
this.groupPanelIncludeOn.Margin = new System.Windows.Forms.Padding(2);
this.groupPanelIncludeOn.Location = new System.Drawing.Point(0, 477);
this.groupPanelIncludeOn.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupPanelIncludeOn.Name = "groupPanelIncludeOn";
this.groupPanelIncludeOn.Size = new System.Drawing.Size(172, 79);
this.groupPanelIncludeOn.Size = new System.Drawing.Size(229, 97);
//
//
//
@ -400,26 +405,43 @@ namespace Volian.Controls.Library
//
//
this.cbPlaceKeeper.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.cbPlaceKeeper.Location = new System.Drawing.Point(3, 33);
this.cbPlaceKeeper.Margin = new System.Windows.Forms.Padding(2);
this.cbPlaceKeeper.Location = new System.Drawing.Point(4, 41);
this.cbPlaceKeeper.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cbPlaceKeeper.Name = "cbPlaceKeeper";
this.cbPlaceKeeper.Size = new System.Drawing.Size(84, 15);
this.cbPlaceKeeper.Size = new System.Drawing.Size(95, 17);
this.cbPlaceKeeper.TabIndex = 1;
this.cbPlaceKeeper.Text = "Placekeeper";
this.cbPlaceKeeper.CheckedChanged += new System.EventHandler(this.cbPlacekeeper_CheckedChanged);
//
// lblChgId
//
this.lblChgId.AutoSize = true;
this.lblChgId.Location = new System.Drawing.Point(0, 64);
this.lblChgId.Name = "lblChgId";
this.lblChgId.Size = new System.Drawing.Size(74, 17);
this.lblChgId.TabIndex = 3;
this.lblChgId.Text = "Change ID";
//
// tbChgID
//
this.tbChgID.Location = new System.Drawing.Point(0, 83);
this.tbChgID.Name = "tbChgID";
this.tbChgID.Size = new System.Drawing.Size(107, 22);
this.tbChgID.TabIndex = 4;
this.tbChgID.TextChanged += new System.EventHandler(this.tbChgID_TextChanged);
//
// DisplayTags
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.groupPanelIncludeOn);
this.Controls.Add(this.groupPanelPaginate);
this.Controls.Add(this.groupPanelChgBar);
this.Controls.Add(this.groupPanelCheckoff);
this.Controls.Add(this.groupPanelChgStepType);
this.Margin = new System.Windows.Forms.Padding(2);
this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.Name = "DisplayTags";
this.Size = new System.Drawing.Size(172, 512);
this.Size = new System.Drawing.Size(229, 630);
this.groupPanelPaginate.ResumeLayout(false);
this.groupPanelPaginate.PerformLayout();
this.groupPanelCheckoff.ResumeLayout(false);
@ -450,5 +472,7 @@ namespace Volian.Controls.Library
private DevComponents.DotNetBar.SuperTooltip superTooltipTags;
private DevComponents.DotNetBar.Controls.GroupPanel groupPanelIncludeOn;
private DevComponents.DotNetBar.Controls.CheckBoxX cbPlaceKeeper;
private System.Windows.Forms.TextBox tbChgID;
private System.Windows.Forms.Label lblChgId;
}
}

View File

@ -110,6 +110,9 @@ namespace Volian.Controls.Library
rbChgBarOn.Enabled = false;
listBoxStepTypes.Items.Clear();
_MyStepTypeInd.Clear();
tbChgID.Text = "";
tbChgID.Enabled = false;
lblChgId.Visible = tbChgID.Visible = false;
CurItemInfo = null;
}
private bool StepOverRide()
@ -253,6 +256,18 @@ namespace Volian.Controls.Library
rbChgBarOn.Text = "ON (Override)";
}
}
// see if the change id label & text box are visible, i.e. plant has multiple change ids.
if (CurItemInfo.ActiveFormat.PlantFormat.FormatData.ProcData.ChangeBarData.ChangeIds)
{
StepConfig sc1 = CurItemInfo.MyConfig as StepConfig;
tbChgID.Text = sc1.Step_ChangeID;
tbChgID.Enabled = true;
lblChgId.Visible = tbChgID.Visible = true;
}
else
lblChgId.Visible = tbChgID.Visible = false;
// Walk up tree until this step type's parentType is "Base". Start adding menuitems from this step type.
StepData top = fmtdata.StepDataList[formatSteptype];
//int tmpi = formatSteptype;
@ -438,5 +453,11 @@ namespace Volian.Controls.Library
//}
}
#endregion
private void tbChgID_TextChanged(object sender, EventArgs e)
{
StepConfig sc = CurItemInfo.MyConfig as StepConfig;
sc.Step_ChangeID = tbChgID.Text;
}
}
}